Download the PHP package ekino/data-protection-bundle without Composer
On this page you can find all versions of the php package ekino/data-protection-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download ekino/data-protection-bundle
More information about ekino/data-protection-bundle
Files in ekino/data-protection-bundle
Package data-protection-bundle
Short Description Data protection bundle
License MIT
Homepage https://github.com/ekino/EkinoDataProtectionBundle
Informations about the package data-protection-bundle
EkinoDataProtectionBundle
This is a work in progress, so if you'd like something implemented please feel free to ask for it or contribute to help us!
Purpose
This bundle protects the data of your project through encryption.
Installation
Step 1: add dependency
Step 2: register the bundle
Symfony 2 or 3:
Symfony 4:
Step 3: configure the bundle
The method
is one of openssl_get_cipher_methods().
Usage
Encrypt the logs
This bundle provides a processor for Monolog to encrypt your logs in order
to not be human-readable. To use it, just add the prefix private_
on the
context key for each data you want to encrypt, for instance:
Then the data can be decrypted in a secure area using the encryptor.
If you don't want it, you can disable it in the config:
Decrypt the logs
This bundle provides a Sonata Admin panel to decrypt your logs that would have been encrypted by the above processor. To use it, enable it in configuration:
`
Then, you will be able to add the following route admin_app_logs_decrypt_encrypt
into
your menu for example. This route provides a form with only one field in which you
can fill in only the encrypted part of the log or a full text containing several logs.
In case of several encrypted logs, each decrypted result will be displayed in a
dedicated tab.
Decrypt your secrets at runtime
This bundle provides a processor using the configured encryptor to decrypt a secret at runtime. This allows you to not reveal your secrets and easy rotate them without flushing the cache.
To use it, just use the prefix ekino_encrypted
as this example shows:
Encrypt texts using the CLI
To encrypt a text, run the following command:
bin/console ekino-data-protection:encrypt myText
, optionally with --secret mySecret
and/or --method myCipher
All versions of data-protection-bundle with dependencies
ext-json Version *
ext-openssl Version *
monolog/monolog Version ^3.6.0
symfony/config Version ^5.4 || ^6.4 || ^7.0
symfony/console Version ^5.4 || ^6.4 || ^7.0
symfony/dependency-injection Version ^5.4 || ^6.4 || ^7.0
symfony/form Version ^5.4 || ^6.4 || ^7.0
symfony/http-kernel Version ^5.4 || ^6.4 || ^7.0
symfony/options-resolver Version ^5.4 || ^6.4 || ^7.0
symfony/translation Version ^5.4 || ^6.4 || ^7.0
symfony/validator Version ^5.4 || ^6.4 || ^7.0