Skip to the content.

ParseDMARC-go

A Go implementation of the DMARC report parser, based on the original Python parsedmarc project.

📋 Conversion & Enhancements

The conversion to Go was done with Claude AI, adding significant improvements:

Core enhancements:

Not converted (due to lack of testing capability):

🌟 Core Features

📊 Report Parsing - Industry leading format support

🌐 Data Enhancement

📡 Multiple Input Methods

💾 Flexible Output & Storage

📈 Production Monitoring

Quick Start

# Download and install
curl -L -o parsedmarc-go https://github.com/ZenProjects/parsedmarc-go/releases/latest/download/parsedmarc-go-linux-amd64
chmod +x parsedmarc-go

# Parse a report
./parsedmarc-go -input report.xml

# Run as daemon
./parsedmarc-go -daemon -config config.yaml

For detailed usage instructions, see the 📖 Documentation below.

🗄️ ClickHouse Database Schema

The program automatically creates optimized production-ready tables with proper indexing, partitioning, and performance optimizations:

📋 dmarc_aggregate_reports

Main aggregate report metadata table

📊 dmarc_aggregate_records

Individual aggregate report records

🔍 dmarc_forensic_reports

Forensic/failure report details

🔐 dmarc_smtp_tls_reports

SMTP TLS report metadata

⚠️ dmarc_smtp_tls_failures

Detailed SMTP TLS failure analysis

🚀 Performance Features

🔧 Advanced Email Format Support

parsedmarc-go features industry-leading email format compatibility, automatically handling complex report formats from major email service providers:

🎯 Forensic Reports (RUF) - Universal Compatibility

Plain Text Format

Simple feedback reports embedded directly in email body text

MIME Multipart Email Formats

Automatically parsed with full provider compatibility:

Provider Format Encoding Content-Type
LinkedIn multipart/report Plain text message/feedback-report
Domain.de multipart/report Plain text message/feedback-report; name=report
Netease multipart/mixed Base64 message/feedback-report; name="ATT00001"
Others Auto-detected Base64/Plain Various MIME types

🚀 Advanced Processing Pipeline:

  1. Multi-line header parsing - Handles wrapped Content-Type headers
  2. MIME boundary extraction - Robust parsing of complex boundaries
  3. Base64 decoding - Automatic detection and decoding
  4. Content-type detection - Intelligent format recognition
  5. Fallback mechanisms - Plain text parsing if MIME fails

📧 SMTP TLS Reports - Next-Generation Support

Direct JSON Format

Standard RFC 8460 JSON reports processed natively

Email-Based Reports

Advanced multi-stage processing pipeline:

Provider Format Pipeline Content-Type
Google multipart/report Base64 → GZIP → JSON application/tlsrpt+gzip
Others Auto-detected Base64 → Compression → JSON application/tlsrpt+*

🔄 Processing Pipeline:

Email Input → MIME Parse → Base64 Decode → GZIP Decompress → JSON Parse → Structured Data

📋 Supported Standards

parsedmarc-go implements the following email authentication and reporting standards with industry-leading compatibility:

📚 Documentation

📖 Table of Contents

🚀 Getting Started

🗄️ Database and Visualization

🔌 API and Integrations

📖 Technical References

💡 Tip: Start with the complete documentation for an overview, then check the installation guide to get started quickly.

License

This project is licensed under the Apache 2.0 License - see the LICENSE file for details.

🙏 Acknowledgments


📞 Issues