Database Anonymizer

by
Odoo

107.33

v 14.0 Third Party 2
Lines of code 951
Technical Name nova_anonymizer
LicenseOPL-1
Websitehttps://www.novacode.nl
Also available in version v 12.0 v 13.0
You bought this module and need support? Click here!
Lines of code 951
Technical Name nova_anonymizer
LicenseOPL-1
Websitehttps://www.novacode.nl
Also available in version v 12.0 v 13.0

Database Anonymization

Configurable and really fast

WARNING: Anonymization is irreversible, cannot be undone !

Use wisely ! Don't use on a production environment !

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
Really fast anonymization Especially useful for very large databases.
Uses the PostgreSQL COPY command by psycopg2.
Anonymization technology (tool) Anonymization is done by the excellent (Python) PostgreSQL Anonymizer tool.
(i) https://python-postgresql-anonymizer.readthedocs.io/en/latest/index.html
Load/update and configure Model Fields A wizard to select models, which loads/updates all its fields into an administration model.
Configure per field, whether to anonymize and the anonymization method.
Field anonymization methods Alter data with plentiful of Provider tools
(i) https://python-postgresql-anonymizer.readthedocs.io/en/latest/schema.html

Possibilities:
  • clear: set database field to NULL.
  • choice: define a list of possible values for a database field and will randomly make a choice from this list.
  • fake: use providers from the Python library Faker
    (i) https://faker.readthedocs.io/en/master/providers.html
  • md5: hash the given field value with the MD5 algorithm.
  • mask: replace each character with a static (configured) sign.
  • set: replace with configured value.
  • append: append a value at the end of the altered value.
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.
Currently this only applies to the (PostgreSQL) database.
We shall consider to develop a configurable attachments cleanup feature.
Installation requirement #1: Model Fields configuration
  • pip3 install pyyaml
Installation requirement #2: Database Anonymization
  • pip3 install pganonymize
  • pip3 install Faker

Screenshots

Load / Update Models

Model Fields configuration - editable list

Model Field configuration - form

Execute database anonymization

Export "pganonymize" schema YAML

License

One License is permitted per customer project.

Releases

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

  • The author can leave a single reply to each comment.
  • This section is meant to ask simple questions or leave a rating. Every report of a problem experienced while using the module should be addressed to the author directly (refer to the following point).
  • If you want to start a discussion with the author or have a question related to your purchase, please use the support page.