Implement audit logging
Record every sensitive operation — who did what, when, and from where — in an append-only store the application cannot modify. Includes a retention policy.
Preview
Copy prompt
Implement immutable audit logging for sensitive user actions in a [Language] application — for example, login, privilege change, data export, and admin operations. Each audit record must capture: the authenticated actor's identity, the action performed, the affected resource and its identifier, the timestamp in UTC, the source IP address, and the outcome. Store audit logs in an append-only store that the application process cannot modify or delete. Define a data retention policy and describe how logs should be archived and protected from tampering.
More
Security
Prompts
