PHPackages                             samuel4x4/auditor - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. samuel4x4/auditor

ActiveLibrary[Database &amp; ORM](/categories/database)

samuel4x4/auditor
=================

The missing audit log library.

9.0.6(10mo ago)05.2k1MITPHPPHP &gt;=7.4

Since Dec 6Pushed 10mo agoCompare

[ Source](https://github.com/samuel4x4/auditor)[ Packagist](https://packagist.org/packages/samuel4x4/auditor)[ RSS](/packages/samuel4x4-auditor/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (7)Dependencies (11)Versions (25)Used By (1)

auditor [![Tweet](https://camo.githubusercontent.com/cb820a0ecc9645168e33b03925d7f14691262ddbaeaf66a0a91697803d0cba2d/68747470733a2f2f696d672e736869656c64732e696f2f747769747465722f75726c2f687474702f736869656c64732e696f2e7376673f7374796c653d736f6369616c)](https://twitter.com/intent/tweet?text=auditor,%20the%20missing%20audit%20log%20library.&url=https://github.com/DamienHarper/auditor&hashtags=auditor)
====================================================================================================================================================================================================================================================================================================================================================================================================================

[](#auditor-)

[![Latest Stable Version](https://camo.githubusercontent.com/40f3c4f2153873306a1eb643e0aa3350c396b0a9e39176e6db821b9146507251/68747470733a2f2f706f7365722e707567782e6f72672f64616d69656e6861727065722f61756469746f722f762f737461626c65)](https://packagist.org/packages/damienharper/auditor)[![Latest Unstable Version](https://camo.githubusercontent.com/7aef1b3f427de0708fa7ab33d9d4783daabfde3b65a9d36b180fe7ab34feb4fa/68747470733a2f2f706f7365722e707567782e6f72672f64616d69656e6861727065722f61756469746f722f762f756e737461626c65)](https://packagist.org/packages/damienharper/auditor)[![auditor 2.x CI](https://github.com/DamienHarper/auditor/actions/workflows/ci-2.x.yml/badge.svg)](https://github.com/DamienHarper/auditor/actions/workflows/ci-2.x.yml)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/bc84837855c3fccfbef2ef81e67f286c44c1aa4841c9cf315a6bd8227e3737e6/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f44616d69656e4861727065722f61756469746f722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/DamienHarper/auditor/?branch=master)[![codecov](https://camo.githubusercontent.com/08758ea03c7856753d13f2a8852f85d30a6cbf0100153ba2cb89e43bf5a8c850/68747470733a2f2f636f6465636f762e696f2f67682f44616d69656e4861727065722f61756469746f722f6272616e63682f6d61737465722f67726170682f62616467652e737667)](https://app.codecov.io/gh/DamienHarper/auditor/branch/master)[![License](https://camo.githubusercontent.com/888556dd07c1f2252436d65b379d10b3e39f2db8619b9bd98fca4c48065d177b/68747470733a2f2f706f7365722e707567782e6f72672f64616d69656e6861727065722f61756469746f722f6c6963656e7365)](https://packagist.org/packages/damienharper/auditor)[![Total Downloads](https://camo.githubusercontent.com/fc939f071060d68a9e81dbab5404b5db16e93b2e798564b4c34356d1f4a300c9/68747470733a2f2f706f7365722e707567782e6f72672f64616d69656e6861727065722f61756469746f722f646f776e6c6f616473)](https://packagist.org/packages/damienharper/auditor)[![Monthly Downloads](https://camo.githubusercontent.com/8f5f47a1a3307859fc2fe0ee8f4bb5cd8802d13cbc11587889a72d4be351c57e/68747470733a2f2f706f7365722e707567782e6f72672f64616d69656e6861727065722f61756469746f722f642f6d6f6e74686c79)](https://packagist.org/packages/damienharper/auditor)[![Daily Downloads](https://camo.githubusercontent.com/9393a0b58203d4560a7d975ea7baec5fa30729f1422a7010d1c5cd8c92073e38/68747470733a2f2f706f7365722e707567782e6f72672f64616d69656e6861727065722f61756469746f722f642f6461696c79)](https://packagist.org/packages/damienharper/auditor)

The purpose of `auditor` is to provide an easy and standardized way to collect audit logs.

Architecture
------------

[](#architecture)

This library is architected around two concepts:

- Auditing services responsible for collecting audit events
- Storage services responsible for persisting audit traces

Those two kind of services are offered by Providers.

Default provider
----------------

[](#default-provider)

A default provider is included with this library: the `DoctrineProvider`

`DoctrineProvider` offers both auditing services and sorage services. It creates audit logs for all `Doctrine ORM` database related changes:

- 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 following RDBMS

- MySQL
- MariaDB
- PostgreSQL
- SQLite

`DoctrineProvider` should work with **any other** database supported by `Doctrine`. Though, we can only really support the ones we can test with [GitHub Actions](https://github.com/features/actions).

Basically you can track any change of any entity from audit logs.

**NOTE:** `DoctrineProvider` cannot track DQL or direct SQL statements executions.

Official Documentation
----------------------

[](#official-documentation)

`auditor` official documentation can be found [here](https://damienharper.github.io/auditor-docs/).

Version Information
-------------------

[](#version-information)

VersionStatusRequirementsBadges2.xActive development 🚀PHP &gt;= 7.4, Symfony &gt;= 4.4[![auditor 2.x CI](https://github.com/DamienHarper/auditor/actions/workflows/ci-2.x.yml/badge.svg)](https://github.com/DamienHarper/auditor/actions/workflows/ci-2.x.yml)
[![Scrutinizer Code Quality](https://camo.githubusercontent.com/bc84837855c3fccfbef2ef81e67f286c44c1aa4841c9cf315a6bd8227e3737e6/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f44616d69656e4861727065722f61756469746f722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/DamienHarper/auditor/?branch=master)
[![codecov](https://camo.githubusercontent.com/08758ea03c7856753d13f2a8852f85d30a6cbf0100153ba2cb89e43bf5a8c850/68747470733a2f2f636f6465636f762e696f2f67682f44616d69656e4861727065722f61756469746f722f6272616e63682f6d61737465722f67726170682f62616467652e737667)](https://app.codecov.io/gh/DamienHarper/auditor/branch/master)1.xActive supportPHP &gt;= 7.2, Symfony &gt;= 3.4[![auditor 1.x CI](https://github.com/DamienHarper/auditor/actions/workflows/ci-1.x.yml/badge.svg)](https://github.com/DamienHarper/auditor/actions/workflows/ci-1.x.yml)
[![Scrutinizer Code Quality](https://camo.githubusercontent.com/2d4bc8d715426da26b777adfd2f0e78f12fba557b24734f997b185a6f7351f8f/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f44616d69656e4861727065722f61756469746f722f6261646765732f7175616c6974792d73636f72652e706e673f623d312e78)](https://scrutinizer-ci.com/g/DamienHarper/auditor/?branch=1.x)
[![codecov](https://camo.githubusercontent.com/aa8966b4cb52e2210aeda8ce331d27c58cf8f43cb0b2af89e871fd77082a1b3e/68747470733a2f2f636f6465636f762e696f2f67682f44616d69656e4861727065722f61756469746f722f6272616e63682f312e782f67726170682f62616467652e737667)](https://app.codecov.io/gh/DamienHarper/auditor/branch/1.x)Changelog is available [here](https://damienharper.github.io/auditor-docs/docs/auditor/release-notes.html)

Contributing
------------

[](#contributing)

`auditor` is an open source project. Contributions made by the community are welcome. Send us your ideas, code reviews, pull requests and feature requests to help us improve this project.

Do not forget to provide unit tests when contributing to this project. To do so, follow instructions in this dedicated [README](tests/README.md)

Credits
-------

[](#credits)

- Thanks to [all contributors](https://github.com/DamienHarper/auditor/graphs/contributors)
- This library initially took some inspiration from [data-dog/audit-bundle](https://github.com/DATA-DOG/DataDogAuditBundle.git) and [simplethings/entity-audit-bundle](https://github.com/simplethings/EntityAuditBundle.git)
- Special thanks to [JetBrains](https://www.jetbrains.com/?from=auditor) for their *Licenses for Open Source Development*

License
-------

[](#license)

`auditor` is free to use and is licensed under the [MIT license](http://www.opensource.org/licenses/mit-license.php)

###  Health Score

40

—

FairBetter than 88% of packages

Maintenance53

Moderate activity, may be stable

Popularity17

Limited adoption so far

Community17

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 84% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~72 days

Recently: every ~241 days

Total

24

Last Release

329d ago

Major Versions

1.x-dev → 2.0.02022-03-05

2.1.1 → 9.0.02022-11-03

PHP version history (2 changes)1.0.0PHP &gt;=7.2

2.0.0PHP &gt;=7.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/9eb39ec7050814cc24a6657a65e805b676abe8cfed7330f10f7c921093173215?d=identicon)[samuel4x4](/maintainers/samuel4x4)

---

Top Contributors

[![DamienHarper](https://avatars.githubusercontent.com/u/2448660?v=4)](https://github.com/DamienHarper "DamienHarper (142 commits)")[![samuel4x4](https://avatars.githubusercontent.com/u/3427855?v=4)](https://github.com/samuel4x4 "samuel4x4 (12 commits)")[![dmitryuk](https://avatars.githubusercontent.com/u/661654?v=4)](https://github.com/dmitryuk "dmitryuk (4 commits)")[![janklan](https://avatars.githubusercontent.com/u/5463371?v=4)](https://github.com/janklan "janklan (2 commits)")[![yivi](https://avatars.githubusercontent.com/u/1815039?v=4)](https://github.com/yivi "yivi (2 commits)")[![SanderVerkuil](https://avatars.githubusercontent.com/u/7080527?v=4)](https://github.com/SanderVerkuil "SanderVerkuil (1 commits)")[![vindert](https://avatars.githubusercontent.com/u/17656771?v=4)](https://github.com/vindert "vindert (1 commits)")[![Metabor](https://avatars.githubusercontent.com/u/2135064?v=4)](https://github.com/Metabor "Metabor (1 commits)")[![djpremier](https://avatars.githubusercontent.com/u/17091381?v=4)](https://github.com/djpremier "djpremier (1 commits)")[![Marmelatze](https://avatars.githubusercontent.com/u/199681?v=4)](https://github.com/Marmelatze "Marmelatze (1 commits)")[![andrew-demb](https://avatars.githubusercontent.com/u/12499813?v=4)](https://github.com/andrew-demb "andrew-demb (1 commits)")[![robier](https://avatars.githubusercontent.com/u/3607521?v=4)](https://github.com/robier "robier (1 commits)")

---

Tags

doctrineAuditaudit-trailaudit-log

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/samuel4x4-auditor/health.svg)

```
[![Health](https://phpackages.com/badges/samuel4x4-auditor/health.svg)](https://phpackages.com/packages/samuel4x4-auditor)
```

###  Alternatives

[damienharper/auditor-bundle

Integrate auditor library in your Symfony projects.

4542.8M](/packages/damienharper-auditor-bundle)[damienharper/auditor

The missing audit log library.

1922.8M8](/packages/damienharper-auditor)[prestashop/prestashop

PrestaShop is an Open Source e-commerce platform, committed to providing the best shopping cart experience for both merchants and customers.

9.0k15.4k](/packages/prestashop-prestashop)[ec-cube/ec-cube

EC-CUBE EC open platform.

78527.0k1](/packages/ec-cube-ec-cube)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[laravel-doctrine/orm

An integration library for Laravel and Doctrine ORM

8425.3M87](/packages/laravel-doctrine-orm)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
