Lines of code | 1166 |
Technical Name |
nova_anonymizer |
License | OPL-1 |
Website | https://www.novacode.nl |
Also available in version | v 13.0 v 14.0 v 12.0 |
Lines of code | 1166 |
Technical Name |
nova_anonymizer |
License | OPL-1 |
Website | https://www.novacode.nl |
Also available in version | v 13.0 v 14.0 v 12.0 |
Database Anonymization
Configurable and super fast
WARNINGS
Don't use on a production (live) environment, use on a copy eg. test environment
Anonymizes the database in-place
Anonymization is irreversible, cannot be undone
About
A database which contains sensitive data, like personal- and userdata, should be anonymized when:
- Sending and/or sharing a database with external parties (eg development agencies, freelancers).
- On a test environment accessible to external (or untrusted) parties, or when it doesn't have the high security level like a production environment.
Database anonymization is the required action to prepare such database.
So you don't risk to infringe GDPR (dutch: AVG), privacy and other concerns about sensitive data.
To anonymize a PostgreSQL database, some nice tools and libraries are available. Convenience, configuration and advanced features are key here!
With this Odoo module/app you're able to prepare (configure) the database and execute the anonymization.
Features
Subject | Description |
---|---|
Super fast anonymization |
Handles very large databases. Uses the PostgreSQL COPY command by psycopg2 .
|
Anonymization technology (tool) |
Anonymization is done by the excellent (Python) pganonymize tool/library. (i) https://github.com/rheinwerk-verlag/pganonymize/ (i) https://python-postgresql-anonymizer.readthedocs.io/en/latest/index.html
|
Update Models and Fields |
A wizard to select models, which loads (and updates) the models and all its fields into configuration models. |
Configure Fields | Configure per field, whether to anonymize and the anonymization method. |
Configure Models |
Configure per model, which records to anonymize or to exclude, by a search domain filter (or SQL WHERE). If empty search domain filter, all records will be anonymized. |
Field anonymization methods |
Alter data with plentiful of Provider tools (i) https://python-postgresql-anonymizer.readthedocs.io/en/latest/schema.html Possibilities:
|
CSV export/import template for model and fields configuration |
CSV export/import template is included, for models and fields configurations. This eases preparation, re-use and repeatability of the anonymizer configuration, also across databases. See an example in the screenshots below (CSV export template, CSV import). |
Enable anonymization setting (extra safety) |
Initially the database anonymization is disabled and only configuration (model fields) is possible. Database anonymization can be enabled in the Configuration Settings. |
Database transaction and error reporting | The anonymization runs in a database transaction. If an error occurs eg due to misconfiguration, the transaction is rolled back and the error is displayed to the user. |
Non feature notice: filestore (attachments) |
The filestore (attachments) ain't anonymized, altered or whatsoever. So the anonymization only applies to the (PostgreSQL) database. |
Installation requirement #1: Model Fields configuration |
|
Installation requirement #2: Database Anonymization |
|
Screenshots
Update Models and Fields

Model Fields configuration - editable list

Model Field configuration - form

Execute database anonymization

CSV export template - model fields configuration

CSV import - model fields configuration

Export "pganonymize" schema YAML

License
One License is permitted per customer project.
Releases
1.5
-
Improvements for CSV export/import for "Config State" field:
- Remove readonly setting from "Config State" field in model. It's readonly in views.
This ensures the Config State can be imported.
- Add "Config State" field to CSV export template.
1.4
-
CSV export/import template: Add external ID (
nova.anonymizer.model
record).
1.3
- Fix table determination (computed field). Bug introduced in version 1.1.
-
Move Contact
res.partner
configuration to demo data (xml).
1.2
- CSV export template (models and fields configurations).
- Change some fields options (ondelete, required) to improve CSV import.
1.1
-
Add (import) template CSV file, to ease the setup to import models and fields configurations.
File in module directory:data/example_import_template_nova.anonymizer.model.csv
- Remove table field, don't store anymore (of course implicit on the model).
1.0
- Improvements and documentation in the anonymize wizard view.
0.8
- Fix Anonymizer Field config: when Provider (field) is cleared, update Config State (field) to "Check", instead of empty (NULL).
0.7
- Fix: SQL literals (eg. strings) encoding of search domain (introduced in 0.5).
- New feature: Configure whether to exclude (is new) or include (introduced in 0.5) records to be anonymized, by domain or SQL WHERE-clause.
- Improvements: renaming of menu's, windows, buttons.
0.6
-
Improvement: search domain (introduced in 0.5), to also query inactive records (
with_context(active_test=False
).
0.5
-
New feature: Configure per model a
search domain
orSQL WHERE
, which generates the schema to filter records to anonymize.
This change required to add thenova.anonymizer.model
(model), where the search (domain, WHERE) can be setup.
0.4
-
Improvement: Cleanup of Model Fields Configuration (
nova.anonymizer.model.field
) upon updating (write).
0.3
-
Use
--host
and--port
options if set in the Odoo config.
0.2
-
Path determination of the
pganonymize
tool.
0.1
- Initial version
Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module