eu-audit-mcp
Tamper-evident audit trail MCP server for EU AI Act and GDPR compliance. Designed to be integrated into a local desktop application via stdio transport.
Features
- Tamper-evident logging — HMAC-SHA256 hash chain over all events
- PII scanning — Automatic detection and redaction via Microsoft Presidio (EU patterns)
- GDPR erasure — Article 17 right-to-erasure support with audit trail
- Compliance checks — Technical checklist against EU AI Act Articles 12/19 and GDPR Article 30
- Local-first — All data stays on your machine in a single SQLite file
Regulatory context
This server implements technical measures for the following EU regulations:
| Regulation | Articles | What it requires |
|---|---|---|
| EU AI Act (2024/1689) | Art. 12 | Automatic recording of events (logs) for high-risk AI systems |
| Art. 19 | Retention of automatically generated logs for at least 6 months | |
| GDPR (2016/679) | Art. 17 | Right to erasure of personal data ("right to be forgotten") |
| Art. 30 | Records of processing activities, including purposes and data categories |
The EU AI Act high-risk obligations enter into force on 2 August 2026.
See LEGAL_REFERENCES.md for the full article texts and a detailed mapping of how each tool addresses each requirement.
Disclaimer: This tool provides a technical checklist, not legal advice. Consult qualified legal counsel for compliance decisions.
Quick start
pip install -e ".[dev]"
Run the server (stdio)
python -m eu_audit_mcp.server
MCP client configuration
{
"mcpServers": {
"eu-audit": {
"command": "python",
"args": ["-m", "eu_audit_mcp.server"],
"env": {
"AUDIT_CONFIG": "./audit_config.yaml"
}
}
}
}
Run tests
pytest tests/
MCP Tools
| Tool | Description |
|---|---|
log_event |
Record an audit event with automatic PII scanning |
log_inference |
Log an LLM inference call (model, tokens, cost) |
log_data_access |
Log a document/data access event |
query_log |
Search events by time range, type, session |
get_session_trace |
Full ordered trace of a session |
get_stats |
Summary statistics over a time period |
compliance_check |
Check against EU AI Act Art. 12/19 and GDPR Art. 30 |
execute_erasure |
GDPR Article 17 right-to-erasure |
get_pii_summary |
Summary of detected PII types (counts only) |
verify_chain |
Verify hash chain integrity |
Configuration
Copy the example config and customize:
cp audit_config.example.yaml audit_config.yaml
Set the AUDIT_CONFIG environment variable to point to your config file. Do not commit audit_config.yaml if it contains a chain_secret — it is in .gitignore by default.
Security
See SECURITY.md for the threat model, security measures, and vulnerability reporting.
License
Apache-2.0
Metadata
Release files for eu-audit-mcp 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| eu_audit_mcp-0.1.1.tar.gz | 25.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| eu_audit_mcp-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 43.5 kB
Release files / eu_audit_mcp-0.1.1.tar.gz
| Download URL | eu_audit_mcp-0.1.1.tar.gz |
|---|---|
| Size | 25.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
60ecbc0f4c82026d02a1d3490406e3811fb233643e6c24158e75ecd3af113442
|
|
BLAKE2b-256 checksum How to use checksums |
a4a3eca9d4dcf32208bfe767fd9fc9c73f359d034ebbd9020f6bfe14c79bd31f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 27, 2026.
Transparency logRelease files / eu_audit_mcp-0.1.1-py3-none-any.whl
| Download URL | eu_audit_mcp-0.1.1-py3-none-any.whl |
|---|---|
| Size | 18.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ec538990a8f2aa8ae65ac3236e71328d4da289ae878f8454761884aa337a709b
|
|
BLAKE2b-256 checksum How to use checksums |
e612418fe4363b7018ec4ad9ae8a93b42609f9c29d9c69ce2f80bc25c44af20b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 27, 2026.
Transparency log