Skip to main content

cprima-pdh

Practical Digital Housekeeping. Keep your digital life in order, starting with your password database. Keep it tidy. Keep it trustworthy.

pdh is the companion tool of the methodology: it checks a KeePass vault (.kdbx) against a written taxonomy of record types and field names, and changes the vault only on request, as a dry run first. Website: https://pdh.cprima.net

uvx --from "cprima-pdh[kdbx]" pdh doctor --db vault.kdbx

Always use --from: plain uvx pdh runs an unrelated tool of the same command name. The [kdbx] extra installs pykeepass; the method commands (pdh method ...) work without it.

Commands

Group Commands
pdh doctor overview in three sections: setup, file (format and key derivation from the header, lock files, sync conflicts, size drivers) and method (owners, areas, record types, vocabulary, conformance, hygiene, relations)
pdh session unlock, lock, status: cache the master password for a while (Windows DPAPI)
pdh inspect inventory, tree, entries (--expired, --expiring DAYS), tags, totp, find (--in-fields), show, read, links, unclassified, fields, history, attachments, otp (the current code, never the secret)
pdh check conform (the default), validate: findings with levels ERROR / WARN / INFO and, per issue, an action; known-passwords and breaches (online, only with --online)
pdh edit set, link, rename-field (one entry or --all), vocabulary, new-entry, new-group, move, delete (to the recycle bin), restore, purge (only from the bin), clone, tags, expiry, icon, color, override-url, autotype, history-restore, history-prune, attach, detach, rename-group, move-group, delete-group, group-notes, group-icon: dry run unless --apply; every edit keeps the previous state in the entry's history
pdh db create, password, keyfile, settings, kdf, empty-bin: the database itself (dry run unless --apply; new passwords from an environment variable or a hidden prompt)
pdh io import-csv, import-kdbx, merge (by UUID and modification time, nothing deleted), export-csv, export-kdbx, export-attachment: the exports are the only writes outside the vault, only to --out, never over an existing file
pdh generate a password or passphrase from the system's secure random source; printed, never stored
pdh method show, schemas: the taxonomy, no vault needed
pdh backends installed backends

Planned, present in --help as (planned) and exiting with code 3 until built: pdh serve (a local, token-protected, read-only HTTP API for one-time-password codes and secret-free entry data; loopback only).

Every vault function a GUI client offers is a command; what pdh does not do is auto-type, browser integration and the graphical UI itself. KDBX 3 to 4 conversion is not offered (pykeepass cannot convert).

Online checks never run without --online. check known-passwords sends only the first 5 characters of each SHA-1 (k-anonymity); check breaches downloads the public breach catalogue and compares it with your URLs locally; --accounts (an API key in HIBP_API_KEY) is the one option that sends e-mail addresses. Level and advice of each finding come from the profile (known-password, breach:*); --fail-on LEVEL sets the exit code like check validate.

What only a human with the real clients can verify is listed in docs/testing/manual-e2e.md.

Use -f json for machine-readable output.

Which vault

--db PATH, else --vault NAME (or PDH_VAULT), else KDBX_FILE, else the default vault of the config, else the vault of the unlocked session. Config files, later ones overriding earlier ones: ~/.config/cprima-pdh/config.toml, ./pdh.toml, $PDH_CONFIG:

default = "<name>"
[vaults.<name>]
path = "relative/or/absolute.kdbx"

Safety

Read-only by default; every write is a dry run unless --apply, and is verified by reopening the saved file. pdh never copies or backs up the vault (backups are your job) and never prints a secret value.

Licence: Apache-2.0.

Metadata

Release files for cprima-pdh 0.0.4

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

Source distribution (sdist)

Source distribution for cprima-pdh 0.0.4
File Size Uploaded Provenance Actions
cprima_pdh-0.0.4.tar.gz 166.8 kB With provenance Details for cprima_pdh-0.0.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for cprima-pdh 0.0.4
File Interpreter ABI Platform Actions
cprima_pdh-0.0.4-py3-none-any.whl Python 3 none any Details for cprima_pdh-0.0.4-py3-none-any.whl

Total release size: 291.2 kB

Release files / cprima_pdh-0.0.4.tar.gz

Download URL cprima_pdh-0.0.4.tar.gz
Size 166.8 kB
Tags Source
SHA-256 checksum
How to use checksums
acbc5e2d7ade7f51a6b9dd01dd41d226f40eb9ef1df60a3f1bda911a013510d4
BLAKE2b-256 checksum
How to use checksums
a1350fe2c94560829f11b32b6df3c7a04483e512f452b1458ed03f6441adb95d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Oct 3, 2026.

Transparency log

Release files / cprima_pdh-0.0.4-py3-none-any.whl

Download URL cprima_pdh-0.0.4-py3-none-any.whl
Size 124.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
475f9836043b429219c13cf8332e0dc8a852eaa65a4cf4202c77f16db6c2596e
BLAKE2b-256 checksum
How to use checksums
489d392c543de99b42f6cc7bf22c15199d73f898e5e6bf6b55595bd88c662199
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Oct 3, 2026.

Transparency log

Security for cprima-pdh 0.0.4

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

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for cprima_pdh-0.0.4.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 Oct 3, 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