Skip to main content

PostgreSQL RBAC object hooks for DBWarden.

Project description

dbwarden-pgsql-rbac

PostgreSQL roles and access control for DBWarden.

dbwarden-pgsql-rbac is an official DBWarden plugin. It is discovered automatically through its dbwarden.plugins entry point and loaded without a consent prompt once installed.

What It Provides

Object handlers that bring PostgreSQL role-based access control into DBWarden's schema diff pipeline:

  • role: database roles.
  • grants: privilege grants.
  • policies: row-level security policies.
  • default_privileges: default privilege configuration.

Each handler participates in extract, canonicalize, diff, and emit, and orders itself with public anchors so grants and policies are emitted after the objects they depend on.

Install

dbwarden plugin add dbwarden-pgsql-rbac

plugin add verifies the package provenance (a PyPI PEP 740 attestation from the official repository) before installing. You can also install it directly:

uv add dbwarden-pgsql-rbac
# or
pip install dbwarden-pgsql-rbac

PostgreSQL only.

Use

Declare roles, grants, and policies in your DBWarden configuration. With the plugin loaded, dbwarden make-migrations diffs them against the live database and emits the appropriate DDL in dependency order. Confirm the plugin is loaded:

dbwarden plugin list

Development

pip install -e . pytest
pytest -q

See the object-plugin docs.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dbwarden_pgsql_rbac-0.1.0.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dbwarden_pgsql_rbac-0.1.0-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file dbwarden_pgsql_rbac-0.1.0.tar.gz.

File metadata

  • Download URL: dbwarden_pgsql_rbac-0.1.0.tar.gz
  • Upload date:
  • Size: 3.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for dbwarden_pgsql_rbac-0.1.0.tar.gz
Algorithm Hash digest
SHA256 c18a425f2136538818036ba41b116184f663c573a160a7289f93296df5ed3777
MD5 ae55dfd10f782e05ed81d51262081d82
BLAKE2b-256 cac66fa6de20fb926d092142ba91f35b2c708b662cbf981e2208fac6c0e56b30

See more details on using hashes here.

File details

Details for the file dbwarden_pgsql_rbac-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for dbwarden_pgsql_rbac-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b9e437709cb72eb16fe30c56b05b2e8c89aeadf86db6f477fe2f85a255a39fda
MD5 f47de0bb756ccea166cef787c4c4be9d
BLAKE2b-256 8ecf6170a7eec1d3e036fad2a505c0ca8c11010720914c66a5c1d0da9ae986a1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page