mirror of
https://github.com/PucelaBits/websegura.git
synced 2024-07-13 08:12:42 +02:00
feat: add dmarc workflow
This commit is contained in:
parent
4df4e65387
commit
80c1de6045
38
.github/workflows/analyze-dmarc.yml
vendored
Normal file
38
.github/workflows/analyze-dmarc.yml
vendored
Normal file
@ -0,0 +1,38 @@
|
||||
name: analyze
|
||||
|
||||
on:
|
||||
# Run it weekly because this workflow is time-consuming and we'd run out of credits.
|
||||
# Run on push is disabled for the same reason.
|
||||
schedule:
|
||||
- cron: "0 1 * * SUN"
|
||||
|
||||
# Allows you to run this workflow manually from the Actions tab
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-20.04
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: "3.9"
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install checkdmarc==4.4.1
|
||||
|
||||
# Use the standalone checkdmarc tool.
|
||||
# Using the API would be more flexible, but this is easier to implement for now.
|
||||
- name: Check DMARC information about public sites
|
||||
run: |
|
||||
checkdmarc --skip-tls --timeout 1 -o _data/results/dmarc/summary.json $(find {_data/general.json,_data/{comunidades,provincias}/*.json} | xargs cat | jq -r .webs[].url)
|
||||
|
||||
# The resulting commit will not trigger another GitHub Actions Workflow run.
|
||||
# This is due to limitations set by GitHub.
|
||||
- uses: stefanzweifel/git-auto-commit-action@v4
|
||||
with:
|
||||
commit_message: Update DMARC information about public sites
|
2
.github/workflows/results_and_build.yml
vendored
2
.github/workflows/results_and_build.yml
vendored
@ -2,7 +2,7 @@ name: results_and_build
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0 2 * * *" # must run after analyze.yml
|
||||
- cron: "0 3 * * *" # must run after analyze.yml & analyze-dmarc.yml
|
||||
|
||||
push:
|
||||
branches:
|
||||
|
1
_data/results/dmarc/summary.json
Normal file
1
_data/results/dmarc/summary.json
Normal file
@ -0,0 +1 @@
|
||||
[]
|
Loading…
Reference in New Issue
Block a user