Scan Databases using PIICatcher

Database Options

OptionDefaultDescription
hostNoneHostname of the database [required]
portNonePort of database.
userNoneUsername to connect database
passwordNonePassword of the user
databaseNoneName of the database
connection-typemysqlOne of mysql,postgres,redshift,oracle,sqlserver
scan-typeshallowOne of deep, shallow. Deep scan checks sample data. Shallow scan checks column names using regular expression
list-allFalseList all columns. By default only columns with PII information is listed
schemaNoneScan only schemas matching the pattern. Refer to Include/Exclude Lists.
exclude-schemaNoneDo not scan any schemas matching the pattern. Refer to Include/Exclude Lists.
tableNoneScan only tables matching the pattern. Refer to Include/Exclude Lists.
exclude-tableNoneDo not scan any tables matching the pattern. Refer to Include/Exclude Lists.

Command Line Options

piicatcher db --help
Usage: piicatcher db [OPTIONS]
Options:
-s, --host TEXT Hostname of the database [required]
-R, --port TEXT Port of database.
-u, --user TEXT Username to connect database
-p, --password TEXT Password of the user
-d, --database TEXT Name of the database
-t, --connection-type [mysql|postgres|redshift|oracle|sqlserver]
Type of database
-c, --scan-type [deep|shallow] Choose deep(scan data) or shallow(scan
column names only)
--list-all List all columns. By default only columns
with PII information is listed
-n, --schema TEXT Scan only schemas matching schema.
-N, --exclude-schema TEXT Do not scan any schemas matching the schema
pattern.
-t, --table TEXT Dump only tables matching table.
-T, --exclude-table TEXT Do not dump any tables matching the table
pattern.
--help Show this message and exit.

Configuration File

[db]
host="..."
port="..."
user="..."
password="..."
database="..."
connection_type="[mysql|postgres|redshift|oracle|sqlserver]"
scan_type="[deep|shallow]"
list_all=True|False
schema=("<schema>",["<schema2>", ...])
exclude_schema=("<schema>",["<schema2>", ...])
table=("<schema>",["<schema2>", ...])
exclude_table=("<schema>",["<schema2>", ...])