{"id":42775063,"url":"https://github.com/easybill/spf-check","last_synced_at":"2026-01-29T22:05:25.864Z","repository":{"id":281005357,"uuid":"924617425","full_name":"easybill/spf-check","owner":"easybill","description":"Fast web service to validate SPF record chains and check domain inclusions in DNS SPF records.","archived":false,"fork":false,"pushed_at":"2025-07-07T06:55:07.000Z","size":73,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-07-07T07:29:16.709Z","etag":null,"topics":["microservice","rust","spf","tokio-rs"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/easybill.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-01-30T10:48:39.000Z","updated_at":"2025-07-07T06:54:13.000Z","dependencies_parsed_at":"2025-07-07T07:23:57.483Z","dependency_job_id":"5bce83f1-c7de-47ab-8468-84b551198603","html_url":"https://github.com/easybill/spf-check","commit_stats":null,"previous_names":["easybill/spf-check"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/easybill/spf-check","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easybill%2Fspf-check","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easybill%2Fspf-check/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easybill%2Fspf-check/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easybill%2Fspf-check/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/easybill","download_url":"https://codeload.github.com/easybill/spf-check/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easybill%2Fspf-check/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28886885,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-29T21:06:44.224Z","status":"ssl_error","status_checked_at":"2026-01-29T21:06:42.160Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["microservice","rust","spf","tokio-rs"],"created_at":"2026-01-29T22:05:25.116Z","updated_at":"2026-01-29T22:05:25.856Z","avatar_url":"https://github.com/easybill.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SPF Check\n\n\u003c!--DESC:Service checks if a domain is within another's SPF record chain.:DESC--\u003e\nA high-performance web service that checks if a target domain is included (directly or indirectly) in another domain's SPF (Sender Policy Framework) record chain.\n\n\n## Features\n\n- 🚀 Fast asynchronous DNS lookups\n- 🔄 Recursive checking of SPF include chains\n- 📋 Returns complete SPF record and include chain information\n- 💓 Health check endpoint\n- 🔒 Secure and efficient with Rust\n- 🌐 Easy to use HTML UI\n\n## API\n\n### Check SPF Record\n\nChecks if a target domain is included in another domain's SPF record chain.\n\n```http\nGET /api/v1/check-spf?domain={domain}\u0026target={target}\n```\n\n#### Parameters\n\n- `domain`: The domain to check the SPF record for (e.g., `example.com`)\n- `target`: The domain to look for in the SPF include chain (e.g., `_spf.example.com`)\n\n#### Success Response\n\n```json\n{\n    \"found\": true,\n    \"checked_domains\": 3,\n    \"domain\": \"example.com\",\n    \"target\": \"spf.protection.outlook.com\",\n    \"elapsed_ms\": 42,\n    \"has_spf_record\": true,\n    \"spf_record\": \"v=spf1 include:spf.protection.outlook.com -all\",\n    \"included_domains\": [\"spf.protection.outlook.com\"],\n    \"fallback_check\": false\n}\n```\n\n- `found`: Boolean indicating if the target was found in the SPF chain\n- `checked_domains`: Number of domains checked in the process\n- `domain`: The original domain that was checked\n- `target`: The domain that was searched for\n- `elapsed_ms`: Time taken for the check in milliseconds\n- `has_spf_record`: Boolean indicating if the domain has an SPF record\n- `spf_record`: The complete SPF record of the main domain (if exists, otherwise `null`)\n- `included_domains`: List of domains included in the main SPF record (if exists, otherwise `null`)\n- `fallback_check`: Boolean indicating if a fallback check was performed (if the target was not found in the SPF record)\n\n#### Error Response\n\n```json\n{\n    \"error\": \"DNS_LOOKUP_FAILED\"\n}\n```\n\nCommon error codes:\n- `DNS_LOOKUP_FAILED`: Unable to perform DNS lookup or `TXT` record does not exist\n- `SPF_PARSE_FAILED`: Invalid SPF record format\n\n### Health Check\n\n```http\nGET /health\n```\n\nReturns `200 OK` if the service is running.\n\n### HTML UI\n\n```url\nhttp://localhost:8080/ui\n```\nReturns a simple HTML UI for checking SPF records.\n\n## Example Usage\n\nCheck if outlook.com's SPF is included in example.com's SPF chain:\n\n```bash\ncurl \"http://localhost:8080/api/v1/check-spf?domain=example.com\u0026target=spf.protection.outlook.com\"\n```\n\n## Installation\n\n1. Ensure you have Rust installed\n2. Clone the repository\n3. Build and run:\n\n```bash\ncargo build --release\n./target/release/spf-check\n```\n\nThe service will listen on `0.0.0.0:8080` by default.\n\n## Performance\n\n- Asynchronous processing allows handling multiple requests simultaneously\n- Each request maintains its own state, preventing cross-request interference\n- Efficient DNS caching through the trust-dns-resolver\n\n## Dependencies\n\n- axum: Web framework\n- tokio: Async runtime\n- trust-dns-resolver: DNS resolution\n- decon-spf: SPF record parsing\n- serde: Serialization/Deserialization\n- chrono: Timestamp formatting\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feasybill%2Fspf-check","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feasybill%2Fspf-check","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feasybill%2Fspf-check/lists"}