DEV Community

Jan Tlapak
Jan Tlapak

Posted on

Building a Free DMARC Monitoring and Reporting Tool with AWS Lambda: The Story of DmarcEye

In the ever-evolving world of cybersecurity, the importance of email authentication cannot be overstated. Domain-based Message Authentication, Reporting, and Conformance (DMARC) has become a crucial tool in the fight against phishing and email spoofing. However, many organizations, especially small businesses and startups, struggle with the cost and complexity of DMARC implementation and monitoring. Enter DmarcEye—a free DMARC monitoring and reporting tool built on AWS Lambda with PHP Bref. This article will take you through the journey of building DmarcEye, leveraging our experience with serverless applications, and explaining how we can offer this service for free.

The Genesis of DmarcEye
The idea for DmarcEye was born out of necessity. As cybersecurity professionals, we recognized the critical need for DMARC but also saw the barriers to adoption. Many existing DMARC monitoring solutions are either too expensive or too complex for small organizations. Our goal was to create an accessible, cost-effective solution that could help any organization implement and monitor DMARC effortlessly.

Why Serverless?
Serverless architecture has revolutionized the way we build and deploy applications. With AWS Lambda and PHP Bref, we saw an opportunity to create a scalable, resilient, and cost-efficient DMARC monitoring service. Here's why serverless was the perfect fit for DmarcEye:

Cost Efficiency: AWS Lambda charges based on the number of requests and the duration of execution. This pay-as-you-go model means that we can keep our costs incredibly low, especially when dealing with sporadic workloads like DMARC report processing.

Scalability: Serverless architectures automatically scale with the workload. As more users adopt DmarcEye, AWS Lambda can handle the increased demand without the need for manual intervention or additional infrastructure costs.

Maintenance-Free: With serverless, there's no need to manage servers, patch operating systems, or worry about scaling infrastructure. AWS handles all of this, allowing our team to focus on developing features and improving the service.

Building DmarcEye
The architecture of DmarcEye leverages AWS Lambda with PHP Bref and Amazon DynamoDB for storage. Here’s a breakdown of how we built our free DMARC monitoring and reporting tool:

Data Ingestion: DMARC reports are sent via email. We use Amazon Simple Email Service (SES) to receive these emails and trigger an AWS Lambda function that extracts the DMARC reports using PHP Bref.

Data Processing: The extracted DMARC reports, often in XML or CSV format, are parsed and processed by another set of Lambda functions running PHP Bref. These functions validate the reports, extract relevant data, and store it in Amazon DynamoDB for further analysis.

Data Storage and Analysis: DynamoDB serves as our primary data store, providing low-latency access to DMARC report data. We optimized our Lambda functions to handle data efficiently, reducing execution time and costs.

Alerting and Reporting: Users can set up custom alerts based on DMARC report findings. We use AWS Lambda with PHP Bref to generate these alerts and Amazon SNS to send notifications. Additionally, we create visual dashboards and reports that users can access through our web interface.

Web Interface: The DmarcEye web interface provides users with a comprehensive view of their DMARC reports, alerts, and compliance status. It is designed to be intuitive and user-friendly, making it easy for anyone to navigate and understand their DMARC data.

Leveraging Experience with Serverless Apps
Our previous experience with serverless applications played a crucial role in the development of DmarcEye. Here are some key lessons we applied:

Modular Design: We designed DmarcEye as a collection of small, independent Lambda functions using PHP Bref. This modular approach makes the system easier to manage, test, and deploy.

Efficient Data Handling: By using DynamoDB, we ensured that our data storage is both cost-effective and scalable. We optimized our Lambda functions to handle data efficiently, reducing execution time and costs.

Security Best Practices: Security is paramount in any application, especially one dealing with email security. We implemented strict access controls using AWS IAM, encrypted data at rest and in transit, and regularly audited our security posture.

Offering DmarcEye for Free
The combination of serverless architecture and AWS's generous free tier allows us to offer DmarcEye as a free DMARC monitoring and reporting tool. Here’s how we keep our costs low:

AWS Free Tier: AWS Lambda, DynamoDB, and other services offer a free tier that covers a significant portion of our usage. For example, AWS Lambda provides 1 million free requests and 400,000 GB-seconds of compute time per month.

Optimized Resource Usage: By carefully optimizing our Lambda functions and choosing the right instance sizes for DynamoDB, we minimize our operational costs.

Community Support: We’ve built a community around DmarcEye, where users can contribute, share knowledge, and help each other. This community-driven approach reduces our support costs and fosters a collaborative environment.

Conclusion
DmarcEye is a testament to the power of serverless architecture and the potential for creating cost-effective, scalable solutions. By leveraging AWS Lambda with PHP Bref and our experience with serverless applications, we’ve built a free DMARC monitoring and reporting tool that breaks down the barriers to DMARC adoption. Whether you’re a small business, a startup, or an individual looking to secure your domain, DmarcEye is here to help.

Try DmarcEye today and experience the ease of DMARC monitoring without the hefty price tag. Together, we can make the internet a safer place, one email at a time.

Top comments (0)