分析dmarc聚合报表的工具
dmarc-import的Python项目详细描述
DMARC导入:邮政喇叭::邮箱:
dmarc-import
是一个分析dmarc聚合报告的工具。这个
这些聚合报告的预期格式在
RFC 7489。
python包的安装
来自Pypi
pip install dmarc-import
从您的本地结账
使用git
克隆存储库后,可以安装
dmarc-import
使用pip
:
pip install /path/to/dmarc-import
来自github
或者,如果您愿意,可以直接从 the GitHub repository:
pip install git+https://github.com/cisagov/dmarc-import.git
构建Docker图像
作为安装python包的替代方法,您可以 选择生成Docker图像:
docker-compose build
用法
Usage: dmarc-import --schema=SCHEMA --s3-bucket=BUCKET [--s3-keys=KEYS][--domains=FILE][--reports=DIRECTORY][--elasticsearch=URL][--es-region=REGION][--log-level=LEVEL][--dmarcian-token=FILE][--delete] dmarc-import (-h | --help) Options: -h --help Show this message. --log-level=LEVEL If specified, then the log level will be set to the specified value. Valid values are "debug", "info", "warn", and "error". --schema=SCHEMA The XSD file against which the DMARC aggregate reports are to be be verified. --s3-bucket=BUCKET The AWS S3 bucket containing the DMARC aggregate reports. --s3-keys=KEYS A comma-separated list of DMARC aggregate report keys. If specified, only the specified DMARC aggregate reports will be processed. Otherwise all reports in the AWS S3 bucket will be processed. --domains=FILE A file to which to save a list of all domains for which DMARC aggregate reports were received. If not specified then no such file will be created. --reports=DIRECTORY A directory to which to write files containing DMARC aggregate report contents. If not specified then no such files will be created. --elasticsearch=URL A URL corresponding to an AWS Elasticsearch instance, including the index where the DMARC aggregate reports should be written. --es-region=REGION The AWS region where the Elasticsearch instance is located. --dmarcian-token=FILE A simple text file whose only contents are the Dmarcian API token. If specified then the Dmarcian API will be queried to determine what commercial mail-sending organization (if any) is associated with the IP in the aggregate report. --delete If present then the reports will be deleted after processing.
设置Docker机密
在尝试通过docker-compose
运行此项目之前,必须
创建一个secrets
目录和其中包含
Docker容器要使用的凭据。这些文件是:
secrets/aws/config
-an ini format file containing the AWS configurationsecrets/aws/credentials
-an ini format file containing the AWS credentialssecrets/dmarcian/token
-包含Dmarcian API token 的文本文件
许可证
这个项目在世界范围内。
该项目在美国属于公共领域,并且 通过以下方式放弃世界范围内作品的版权和相关权利: 这是CC0 1.0 Universal public domain dedication。
所有对该项目的贡献将在CC0下发布 奉献精神。提交请求即表示您同意遵守 放弃版权权益。