PushizoDocs
Operations

DMARC and TLS-RPT monitoring

Receiving DMARC aggregate reports and TLS-RPT reports for the platform domain (Postal HTTP endpoint or IMAP), parsing, unauthorized source alerts, policy recommendations and one-click p= changes with Cloudflare.

Pushizo collects the incoming DMARC aggregate reports (XML) and TLS-RPT reports (JSON) for your own sender domain and interprets them in the admin panel: which sources (IPs/providers) send email on behalf of your domain, what the SPF/DKIM pass rate is, whether there are unauthorized sources, and when it is safe to tighten the policy (p=none → quarantine → reject). This feature is for the platform (the SaaS operator); for sender domain verification of customer apps, see email deliverability.

DNS records

_dmarc.pushizo.com      TXT  "v=DMARC1; p=none; rua=mailto:dmarc@pushizo.com; fo=1"
_smtp._tls.pushizo.com  TXT  "v=TLSRPTv1; rua=mailto:dmarc@pushizo.com"

Reports sent to the dmarc@ address are received in one of two ways (or both).

A) Postal HTTP endpoint (recommended)

  1. Generate a token: openssl rand -hex 24; set DMARC_INBOUND_TOKEN=<token> in .env.prod; restart the API and worker.
  2. Postal → the relevant mail server → Routing → HTTP Endpoints → Add: URL https://api.pushizo.com/hooks/dmarc/<token>, Encoding Body as JSON, Format Raw message, Strip replies off.
  3. Routing → Routes → Add route: Name dmarc, Domain pushizo.com, Endpoint = the one above, Mode Endpoint. No separate mailbox is needed.
  4. Keep Postal's spam checking on; messages that aren't reports are accepted by Pushizo with 200 and discarded (Postal does not retry). Limits: 25 MB body, 120 requests per minute per IP; a missing or wrong token returns 404.
  5. Verification: curl -s -o /dev/null -w '%{http_code}' -X POST https://api.pushizo.com/hooks/dmarc/yanlis -H 'content-type: application/json' -d '{}' → 404. The first reports arrive within 24–48 hours.

B) IMAP mailbox

  1. Create the dmarc@<domain> mailbox.
  2. In .env.prod, set DMARC_IMAP_URL=imaps://dmarc%40pushizo.com:<URL-encoded password>@<imap-server>:993 (use encodeURIComponent if the password contains @ : / ? # %). Restart the worker.
  3. The worker's dmarc-fetch maintenance job scans the mailbox every 15 minutes (single run enforced by a Redis lock): reports are moved to the Processed folder and non-report messages to the trash. Trigger it immediately with Scan now in the panel.

Parsing and storage

  • DMARC XML (DOCTYPE/ENTITY rejected), TLS-RPT JSON, gzip/zip (budgeted decompression), MIME attachments; idempotent on (org_name, report_id).
  • Only reports for the DMARC_DOMAIN domain are stored (other domains are rejected).
  • Tables: dmarc_reports, dmarc_report_records, tls_reports, dmarc_policy_changes (platform tables).

Alerts and recommendations

  • New unauthorized source (≥ 5 messages / 24 hours) and drop in authorized pass rate are sent to platform admins by email in tr/en (once per day per source/alert).
  • The Email security panel (/admin/email-security): live DNS policy, 7/30-day pass rate, sources (authorized/unauthorized), recent reports, TLS failures and the policy recommendation. After 14 days with a 98% pass rate, tightening by one step is recommended.
  • Admin endpoints: GET /admin/v1/deliverability/dmarc, POST …/fetch, …/policy, …/rollback; audit log admin.dmarc.*.

One-click policy with Cloudflare (optional)

Cloudflare → API Tokens → Create Token → the "Edit zone DNS" template, scoped to the relevant zone only. In .env.prod, set CLOUDFLARE_API_TOKEN and CLOUDFLARE_ZONE_ID; restart the API. In the panel, Apply with Cloudflare changes only the p= tag (rua and fo are preserved), the action is written to the audit log, and Undo restores the previous value. If Cloudflare isn't configured, the panel shows the full TXT value to enter.

Environment variables

VariableRequiredDescription
DMARC_DOMAINNoMonitored domain (defaults to the system email domain)
DMARC_INBOUND_TOKENPath APostal HTTP endpoint token
DMARC_IMAP_URLPath BIMAP connection (secret)
CLOUDFLARE_API_TOKEN, CLOUDFLARE_ZONE_IDNoOne-click policy

All are optional; the feature is disabled while they are undefined. The Compose and Helm secret key lists include these variables.

On this page