Skip to content

GLOBAL-FINTECH/mailcard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

17 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

# MAIL-CARD

> A programmable, cloud-native email infrastructure platform written in Rust.

**Powered by IZUREX AGI LAB** โ€“ experimental cognitive intelligence layer.


Platform Architecture

MAIL-CARD Core Engine
โ”œโ”€ SMTP Engine (async Rust)
โ”œโ”€ IMAP Engine (async Rust)  
โ”œโ”€ POP3 Engine (async Rust)
โ”œโ”€ Mail Queue (RocksDB)
โ”œโ”€ Storage Layer
โ””โ”€ Control Plane (REST API)

IZUREX AGI LAB Intelligence Layer
โ”œโ”€ Fraud Detection (ML)
โ”œโ”€ Spam Detection (ML)
โ”œโ”€ Behavioral Analysis
โ””โ”€ Adaptive Routing

Developed by IZUREX AGI LAB

CI License Release Rust Docker Donate](https://paypal.me/Izurex)


What is MAIL-CARD

MAIL-CARD is a modern, high-performance email server built in Rust, designed for both private internal messaging networks and public internet email hosting.

๏ฟฝ๏ธ Security Features

MAIL-CARD includes enterprise-grade security with AI-enhanced threat detection:

  • ๐Ÿ” Transport Security: STARTTLS, TLS 1.3, Perfect Forward Secrecy
  • ๐Ÿ›ก๏ธ Authentication: Multi-factor authentication, OAuth 2.0, SAML
  • ๐Ÿ” SPF Verification: Sender Policy Framework validation
  • โœ๏ธ DKIM Signing: DomainKeys Identified Mail authentication
  • ๐Ÿ“‹ DMARC Validation: Domain-based Message Authentication
  • ๐Ÿšซ Rate Limiting: Advanced abuse protection
  • ๐Ÿค– AI Threat Detection: Machine learning-based security analysis
  • ๐Ÿ“Š Behavioral Analysis: Anomaly detection and pattern recognition

๏ฟฝ๏ฟฝ Key Features

  • Unified Architecture: Supports both private and public email hosting
  • Modern Protocols: SMTP, IMAP, POP3 with full TLS support
  • High Performance: Built on Rust with RocksDB storage
  • Security First: DKIM signing, SPF validation, DMARC support
  • API-Driven: RESTful HTTP API for management and monitoring
  • Observability: Built-in metrics, logging, and health monitoring
  • Scalable: Designed for single-node to distributed deployments

๐Ÿ“‹ Quick Start

Installation

# Clone repository
git clone https://github.com/YOUR_REPO/mail-card.git
cd mail-card

# Build release
cargo build --release

# Run with default config
./target/release/mail-card serve --config config.example.toml

Docker Deployment

# Pull latest image
docker pull mailcard/mail-card:latest

# Run with custom config
docker run -p 25:25 -p 80:80 -p 443:443 \
  -v /path/to/config:/config \
  mailcard/mail-card:latest

๐Ÿ—๏ธ Architecture

View Interactive Architecture

System Components

  • Protocol Servers: SMTP, IMAP, POP3, HTTP API
  • Security Layer: TLS/SSL, DKIM, SPF, DMARC
  • Core Engine: Message queue, routing, storage
  • Storage Layer: RocksDB, object storage, search
  • Observability: Metrics, logging, health monitoring

View Interactive Architecture

๐ŸŽฏ Platform Vision

To build the first programmable, cloud-native email infrastructure with integrated cognitive intelligence.

MAIL-CARD combines modern Rust infrastructure with adaptive machine-learning systems to create an intelligent mail platform capable of learning, adapting, and securing communication systems.

๐ŸŒŸ Killer Feature: Intelligent Email Infrastructure

MAIL-CARD's breakthrough capability is cognitive intelligence integration that provides:

  • ๐Ÿ” Automatic Phishing Detection - ML-powered financial fraud identification
  • ๐Ÿ›ก๏ธ Fraud Pattern Recognition - Real-time scam and threat analysis
  • ๐Ÿ“Š Behavioral Anomaly Detection - User pattern learning and alerting
  • โšก Adaptive Spam Filtering - Self-improving spam classification
  • ๐Ÿš€ Smart Delivery Optimization - AI-enhanced routing and performance

This positions MAIL-CARD uniquely at the intersection of fintech security, compliance, and modern infrastructure.

๏ฟฝ Developer Ecosystem

MAIL-CARD provides comprehensive developer tools for building custom email solutions.

REST API

# Send email
POST /api/v1/mail/send
{
  "to": "user@example.com",
  "from": "sender@example.com",
  "subject": "Hello",
  "body": "Message content"
}

# Analyze message with AI
POST /api/v1/mail/analyze
{
  "message": "Full email content...",
  "analysis_type": ["spam", "fraud", "security"]
}

# Get real-time metrics
GET /api/v1/metrics
{
  "smtp_connections": 1250,
  "messages_sent": 8432,
  "queue_depth": 127,
  "ai_accuracy": 0.94
}

SDK Libraries

// Rust SDK
use mail_card_sdk::{MailCardClient, Message};

let client = MailCardClient::new("http://localhost:8080");
let message = Message::builder()
    .to("user@example.com")
    .from("sender@example.com")
    .subject("Hello")
    .body("World")
    .build();

let result = client.send(message).await?;
// Node.js SDK
const { MailCardClient } = require('@mail-card/sdk');

const client = new MailCardClient('http://localhost:8080');
await client.send({
  to: 'user@example.com',
  from: 'sender@example.com',
  subject: 'Hello',
  body: 'World'
});

Webhooks

# Configure webhooks
POST /api/v1/webhooks
{
  "url": "https://your-app.com/webhook",
  "events": ["message.received", "message.delivered", "threat.detected"],
  "secret": "webhook-secret"
}

๏ฟฝ๐Ÿ“š Documentation

Architecture

Configuration

Development

๐Ÿ”ง Configuration

Basic Setup

server_name = "mail.example.com"

[smtp]
bind = "0.0.0.0:25"
tls_bind = "0.0.0.0:465"

[imap]
bind = "0.0.0.0:143"
tls_bind = "0.0.0.0:993"

[pop3]
bind = "0.0.0.0:110"
tls_bind = "0.0.0.0:995"

Production Template

See sibaq-us-production-fixed.toml for a comprehensive production configuration.

๐ŸŒ DNS Configuration

Required Records

# MX Record
example.com MX 10 mail.example.com

# SPF Record
example.com TXT "v=spf1 mx ip4:SERVER_IP -all"

# DKIM Record
mail._domainkey.example.com TXT "v=DKIM1; k=rsa; p=PUBLIC_KEY"

# DMARC Record
_dmarc.example.com TXT "v=DMARC1; p=none; rua=mailto:admin@example.com"

๐Ÿ“Š Performance

MAIL-CARD is optimized for high-throughput email processing:

  • Messages/Second: 10,000+ (depending on hardware)
  • Concurrent Connections: 5,000+
  • Storage Efficiency: Compressed message storage
  • Memory Usage: < 100MB for 10,000 messages
  • Startup Time: < 2 seconds

๐Ÿ”’ Security Features

  • TLS Encryption: End-to-end encrypted connections
  • DKIM Signing: Cryptographic message authentication
  • SPF Validation: Sender verification
  • DMARC Processing: Domain-based authentication
  • Rate Limiting: Protection against abuse
  • Audit Logging: Comprehensive activity tracking

๐Ÿš€ Deployment Options

Single Node

  • Small organizations (< 1000 users)
  • Development environments
  • Quick deployments

High Availability

  • Medium organizations (1000-10000 users)
  • Production workloads
  • 99.9% uptime

Distributed

  • Large enterprises (> 10000 users)
  • Multi-region deployment
  • 99.99% uptime

๐Ÿ“ˆ Monitoring

MAIL-CARD provides comprehensive observability:

Health Endpoints

  • GET /health - Service health status
  • GET /ready - Readiness check
  • GET /metrics - Prometheus metrics

Key Metrics

  • SMTP connections and delivery rates
  • Message queue depth
  • Storage utilization
  • Authentication success/failure rates
  • Response times and throughput

๐Ÿงช Testing

# Run unit tests
cargo test

# Run integration tests
cargo test --test integration

# Run benchmarks
cargo bench

# Security audit
cargo audit

๐Ÿค Contributing

We welcome contributions! Please see our Contributing Guidelines for details.

Development Setup

# Install Rust toolchain
rustup install stable
rustup component add rustfmt clippy

# Install development dependencies
cargo install cargo-audit cargo-deny

# Run pre-commit checks
cargo fmt
cargo clippy
cargo test

๐Ÿ“„ License

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

๐Ÿ™ Support & Donations

MAIL-CARD is maintained by IZUREX AGI LAB.

Support the project:

PayPal

https://paypal.me/Izurex

Contact:

silwimbaizukanji@gmail.com

๐ŸŒŸ Ways to Support

You can support MAIL-CARD by:

  • โญ Star the repository - Help others discover MAIL-CARD!
  • ๐Ÿ› Reporting bugs and issues
  • ๐Ÿ’ก Contributing improvements
  • ๐Ÿ“– Improving documentation
  • ๐Ÿ”„ Sharing the project
  • ๐Ÿ’ฐ Sponsoring development

๐Ÿ”ฎ Roadmap

Version 0.2.0

  • Distributed clustering
  • Advanced spam filtering
  • Web administration interface
  • Mailbox migration tools

Version 0.3.0

  • AI-powered email classification
  • Advanced search capabilities
  • Multi-tenant support
  • Plugin system

Version 1.0.0

  • Production-ready stability
  • Comprehensive documentation
  • Enterprise features
  • Long-term support

MAIL-CARD - Modern Email Server for the Future ๐Ÿš€

About

MAIL-CARD is a unified email server platform that enables both private communication networks and public internet email hosting in a single architecture. It provides a complete modern mail stack including SMTP, IMAP, POP3, TLS encryption, DKIM authentication, queue management, and high-performance storage.

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages