Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

dpdpkit-pii

Personal-data discovery for dpdpkit. It will find personal data in your databases and files and compare it with your dpdpkit registry, reporting counts only.

Disclaimer. dpdpkit is software that helps you implement obligations under India's Digital Personal Data Protection Act, 2023 and the DPDP Rules, 2025. It does not provide legal advice and does not guarantee compliance. Decisions about notices, purposes, retention and incident reporting must be made by you or your counsel.

Status

Alpha. Version 0.1.0a2 is the first working pre-release (pip install --pre dpdpkit-pii). APIs can still change between pre-releases.

Presidio recognizers for India: Aadhaar (with Verhoeff check), PAN, GSTIN, IFSC, UPI, mobile, voter ID, passport, vehicle registration, ABHA.

from presidio_analyzer import AnalyzerEngine, RecognizerRegistry
from dpdpkit.pii import india_recognizers

registry = RecognizerRegistry()
for recognizer in india_recognizers():
    registry.add_recognizer(recognizer)
results = AnalyzerEngine(registry=registry).analyze(text="PAN ABCPE1234F", language="en")

Column-name heuristics for English and Hinglish names (a hint from the name only, with a confidence):

from dpdpkit.pii import classify_column

classify_column("aadhaar_no")  # category "aadhaar", entity "IN_AADHAAR"
classify_column("janm_tithi")  # category "dob"

Read-only database scanner. It refuses a connection that can write unless force=True, samples at most sample values per column, and reports columns and counts, never values:

from dpdpkit.pii import scan_database

scan = scan_database("postgresql://readonly@host/db", sample=500)
for f in scan.confident:
    print(f.qualified_name, f.entities, f.confidence)  # e.g. customers.pan {'IN_PAN': 212} 0.95

File scanner for CSV, JSON, Excel and text files in a folder or under an S3 prefix (Excel needs dpdpkit-pii[excel], S3 needs dpdpkit-pii[s3]). It only reads, does not follow symlinks, and reports files, fields and counts, never values:

from dpdpkit.pii import scan_files

scan = scan_files("s3://my-bucket/exports/", sample=500, exclude=["*.log"])
for f in scan.confident:
    print(f.qualified_name, f.entities, f.confidence)  # e.g. s3://my-bucket/exports/kyc.csv:pan {'IN_PAN': 212} 0.95

Registry diff and reports. Pass the names you have registered (table.column, schema.table.column or file:field, with * wildcards); unregistered findings are the gaps and are listed first. Reports hold names, entity types and counts only:

from dpdpkit.pii import build_report

report = build_report(scan, registry=["customers.pan", "customers.phone", "orders.*"])
print(report.to_markdown())  # or report.to_json(), report.to_html(), report.render("md")

Command line (adds dpdpkit scan to the dpdpkit command) and container image:

dpdpkit scan postgresql://readonly@host/db --sample 500 --registry registry.txt --out report.html
dpdpkit scan ./exports --format json --fail-on-gaps   # exit 2 if unregistered personal data is found
docker run --read-only --tmpfs /tmp ghcr.io/dpdpkit-dev/scanner postgresql://readonly@host/db

The target is a database URL, a file, a folder or an s3:// prefix. The registry file is a JSON array or one name per line. The format comes from --format, else the --out suffix, else Markdown.

Documentation: https://dpdpkit-dev.github.io/dpdpkit-docs/dev/

License

Apache-2.0. See LICENSE. Contributions need a DCO sign-off; see CONTRIBUTING.md.

Metadata

Release files for dpdpkit-pii 0.1.0a2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dpdpkit-pii 0.1.0a2
File Size Uploaded Provenance Actions
dpdpkit_pii-0.1.0a2.tar.gz 32.5 kB With provenance Details for dpdpkit_pii-0.1.0a2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for dpdpkit-pii 0.1.0a2
File Interpreter ABI Platform Actions
dpdpkit_pii-0.1.0a2-py3-none-any.whl Python 3 none any Details for dpdpkit_pii-0.1.0a2-py3-none-any.whl

Total release size: 61.9 kB

Release files / dpdpkit_pii-0.1.0a2.tar.gz

Download URL dpdpkit_pii-0.1.0a2.tar.gz
Size 32.5 kB
Tags Source
SHA-256 checksum
How to use checksums
998d621002a650f6722b4e21136d520b4b0c26d3796b7f91dcf594717056825c
BLAKE2b-256 checksum
How to use checksums
19f5ef1f386b84302220b5f060a1cc9212e059279ee457338615950609c86ea3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 2, 2026.

Transparency log

Release files / dpdpkit_pii-0.1.0a2-py3-none-any.whl

Download URL dpdpkit_pii-0.1.0a2-py3-none-any.whl
Size 29.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f867de22fb4e87cf44532d211f563d433d457ebb1b001cbb77e4a9de101372b9
BLAKE2b-256 checksum
How to use checksums
f2944dbea2d9fe2fad318de6ba26a235d0845cd343dcb1e458ee8aa0c0eceb68
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 2, 2026.

Transparency log

Security for dpdpkit-pii 0.1.0a2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for dpdpkit_pii-0.1.0a2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 2, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page