symfony audit logs

Auditor is a PHP library that aims to provide an easy and standardized way to collect Symfony audit logs. The library is architected around two components : Auditing services responsible for collecting audit events, and Storage services responsible for persisting audit traces Those two kind of services are offered by Providers.

DoctrineProvider is the default provider included with this library offering both auditing services and storage services. It creates audit logs for all Doctrine ORM database related changes:

Symfony Audit
  • inserts and updates including their diffs and relation field diffs.
  • many to many relation changes, association and dissociation actions.
  • if available, the user responsible for these changes and his IP address are recorded.
  • audit entries are inserted within the same transaction during flush event so that even if something fails the global state remains clean.

DoctrineProvider supports the RDBMS : MySQL, MariaDB, PostgreSQL, and SQLite. Any other RDBMS supported by doctrine should be working also, however only the ones that have been tested are listed here.

Collect Symfony Audit Logs

You can use composer to add Auditor to your Symfony project :

$ composer require damienharper/auditor

Auditor is free to use and is licensed under the MIT license. More information at https://github.com/DamienHarper/auditor

LEAVE A REPLY

Please enter your comment!
Please enter your name here