PIICatcher: free, archived scanner for SQL columns in two store kinds
PIICatcher is an open-source command-line scanner that documents 2 of the 8 kinds of data store, databases and warehouses, and tags PII columns by matching column names and sampled values[1]. It is licensed Apache-2.0, and its GitHub repository is archived[2].
Last reviewed ยท Markdown version
At a glance
- The GitHub repository is archived and has 347 stars; the last push was January 5, 2024[2].
- The latest release is v0.21.2, published July 6, 2023, and the last default-branch commit is dated October 12, 2023[3] [4].
- PyPI limits piicatcher 0.21.2 to Python 3.8 through 3.10.8, so pip will not install it on Python 3.10.9 or later, including 3.11, 3.12 and 3.13[5].
- PyPI metadata gives the license as Apache 2.0, but its classifier reads Other/Proprietary License[5].
Where PIICatcher can look
The README says PIICatcher finds PII in databases and file systems, but its supported-source list names only databases and warehouses, and no file system[1]. Version floors are given for SQLite (3.24.0 or later), MySQL (5.6 or later) and PostgreSQL (9.4 or later)[1].
| Kind of store | Named in the documentation | Source |
|---|---|---|
| Object storage | None found in the pages cited | [1] |
| Databases | SQLite, MySQL, PostgreSQL | [1] |
| Warehouses | AWS Redshift, AWS Athena, Snowflake, BigQuery | [1] |
| SaaS apps | None found in the pages cited | [1] |
| File shares | None found in the pages cited | [1] |
| Endpoints | None found in the pages cited | [1] |
| Code repos | None found in the pages cited | [1] |
| Logs | None found in the pages cited | [1] |
How it detects sensitive data
PIICatcher uses two techniques: regular expressions against column names, and regular expressions plus NLP libraries against sample data in columns[1]. A spaCy plugin, piicatcher_spacy, adds NLP detection of PII in column data[1]. Users add custom detectors by subclassing MetadataDetector or DatumDetector[1]. The built-in column-name detector covers 13 PII types and the built-in value detector covers 7 using the commonregex-improved 1.0.2 package; the repository gives no precision or recall figure[6] [1].
What a scan costs
The README states no price and no throughput figure[1]. The value scan reads only text columns, runs a row count on each table, and reads every row of tables with 100 rows or fewer[7]. On larger tables the query depends on the store, as the table shows[8]. Incremental scans read only new or not-yet-scanned columns, and schema and table include and exclude options limit what is read[1].
| Store | Query | Rows read |
|---|---|---|
| SQLite | none, full select kept | Every row |
| MySQL | LIMIT | First 100 rows |
| PostgreSQL | TABLESAMPLE BERNOULLI (10) with LIMIT | About 10% of rows, 100 kept |
| Snowflake | TABLESAMPLE BERNOULLI with a row count | 100 sampled rows |
| Redshift | ORDER BY RANDOM() with LIMIT | Whole table sorted, 100 kept |
| Athena | ORDER BY RAND() with LIMIT | Whole table sorted, 100 kept |
| BigQuery | ORDER BY RAND() with LIMIT | Whole table sorted, 100 kept |
Queries as written in dbinfo.py[8].
Finding data stores nobody listed
Sources are registered by hand with commands such as catalog add-sqlite, and the README describes no automatic discovery of data stores[1].
Deployment and where the data goes
PIICatcher runs as a Docker image or a pip-installed command-line application on the user's own machine, and the README describes no hosted service[1]. The tool collects usage statistics through cookies unless it is run with --disable-stats[1].
Output: exports, APIs and integrations
The command line prints a table of schema, table, column and has_pii, and a Python API returns a list of PII-typed columns[1]. Ingestion functions tag columns and tables in DataHub and Amundsen with PII and PII type[1]. The README describes no DSAR, SIEM or ticketing integration[1].
Related pages: Scan Price File, Presidio record.