What is this about
- This ready-to-deploy PL/SQL utility bundle reduces the burden of writing lengthy code for utilization of secure Encryption and Decryption utilities provided by Oracle.
- It encapsulates the best practices to safeguard against many pitfalls or loopholes that can actually expose the encryption key thereby resulting in failure of the objective of Obfuscation altogether.
- It has been tested on Oracle 9i, 10g and 11g DB versions.
- It can be used as a central decryption/encryption component that different semantic applications can leverage to securely store data per business need.
- It comes packaged with it's own, flexible centralized error logging module that can be leveraged further for the entire application suite if so desired.
Installation process
-
Please place all the source code files provided in one single location ( preferably a single directory). Check if you need the 11g source code or the base 10g code. Keep only one set to avoid confusion.
- error_log.ddl
- ex_crypto_pkg.ddl
- ex_crypto_pkg_body.ddl
- run_before_install.sql
Execute the file : run_before_install.sql to verify that there is no conflict with an existing object in your database. If there are any objects in the list generated by script then you may wish to manually inspect the DB object(s) before executing the next steps to avoid any data / object loss.
-
Compile the script : error_log.ddl The script expects tablespace named 'ext_data_ts' to be present and accessible. Please replace the same with appropriate tablespace name OR remove the tablespace clause as applicable.
E.g. : from unix prompt - after logging into oracle , fire the command
@error_log.ddl -
Compile the script : ex_crypto_pkg.ddl
E.g. : from unix prompt - after logging into oracle, fire the command
@ex_crypto_pkg.ddl -
Execute wrap utility for hiding the source text in database reference tables :
E.g : In a unix box , which has oracle connectivity defined (i.e. $ORACLE, $TNS_HOME etc. are defined) execute this command
wrap iname=ex_crypto_pkg_body.ddlThis will generate a file named : ex_crypto_pkg_body.plb
Compile this file as usual : E.g : from unix prompt - after logging into oracle , fire the command
@ ex_crypto_pkg_body.plb -
Verify that the encryption package is working properly by using the sample below:
SELECT ex_crypto.f_decrypt(ex_crypto.f_encrypt('Exilant Technologies Pvt. Ltd.')) FROM DUAL;This command will validate both encryption and decryption functions. For detailed function list , please refer to Usage Instructions.
-
Delete the source file(s) by removing them manually (so as to not to expose the logic to even DBA) :
- ex_crypto_pkg.ddl
- ex_crypto_pkg_body.ddl
- ex_crypto_pkg_body.plb
Uninstall process:
Please ensure that the error log table and logging procedure don't have any other dependency or are getting used anywhere. Also, it is suggested to take a backup of error log table , in case the error logging module is to be used separately.
Compile the script :
@uninstall_encryption.sql
This will systematically remove all components installed as part of the crypto module.