AgentShield Proxy provides a streamlined solution for safely handling personally identifiable information (PII) on AWS. Redact sensitive data like emails and SSNs in requests while maintaining flexible database connectivity options. Built on the Serverless Framework, it offers a secure and efficient way to protect user data in modern applications.
AgentShield Proxy is a lightweight and secure PII-safe proxy designed for use with AWS infrastructure, leveraging API Gateway and Lambda, facilitated by the Serverless Framework. The primary purpose of AgentShield is to safeguard personally identifiable information (PII), specifically by redacting sensitive data such as emails and social security numbers (SSNs) within request bodies. Additionally, the tool offers an optional feature for validating connectivity to a PostgreSQL database.
[REDACTED_EMAIL][REDACTED_SSN]psycopg2 when the PG_DSN environment variable is configured.A sample request to the proxy can be made using cURL:
curl -X POST "https://your-api.execute-api.us-east-2.amazonaws.com/dev/proxy/test" \
-H "Content-Type: application/json" \
-H "X-Agent-ID: test-agent" \
-H "x-api-key: YOUR_API_KEY" \
-d '{"email": "user@example.com", "ssn": "123-45-6789", "name": "John Doe"}'
An expected response will show the processed data:
{
"status": "processed",
"agent_id": "test-agent",
"redacted": true,
"body": {
"email": "[REDACTED_EMAIL]",
"ssn": "[REDACTED_SSN]",
"name": "John Doe"
}
}
The architecture comprises:
AgentShield requires specific environment variables and has defined API endpoints:
PG_DSN: PostgreSQL connection string (secured via AWS SSM)Available API endpoints include:
POST /proxy/test: The primary proxy endpoint with an optional database check.DELETE /proxy/admin/drop: A blocked endpoint for security demonstration.Contributions are welcomed. Steps include: forking the repository, creating a feature branch, committing changes, pushing to the branch, and submitting a Pull Request.
Feedback is encouraged through issues or discussions on GitHub. Users are also invited to share their experiences on social media with the tag #AgentShield.
No comments yet.
Sign in to be the first to comment.