Fine-grained access control for the open Lakehouse stack — Cedar policy enforcement wired into Apache DataFusion.
A breakwater is the barrier that decides what reaches the harbor. These crates are that barrier for a DataFusion query engine: they answer can this principal take this action on this resource, in this context? and, when allowed, govern what they may see (row filters + column masks). They are a self-contained, reusable pair — the reference host that composes them into a query session is hydrofoil.
While we incubate ahead of community consensus, the published crates.io names
carry an olai- prefix (open lakehouse and ai). Add them under the short name so
your use paths stay idiomatic, e.g.
datafusion-policy-cedar = { package = "olai-datafusion-policy-cedar", version = "0.0.1" }.
| Crate | crates.io | Description |
|---|---|---|
datafusion-policy-cedar |
olai-datafusion-policy-cedar |
Cedar policy enforcement for DataFusion sessions: a coarse access gate plus optional row/column governance, attached to a SessionState as a query-planner extension. |
datafusion-policy |
olai-datafusion-policy |
The engine-neutral policy core datafusion-policy-cedar builds on: the decide contract, session seam, and (behind fgac) the row-filter/column-mask rewrite — engine-agnostic, no Cedar dependency. |
cedar-oci |
olai-cedar-oci |
A Cedar policy provider backed by OCI-distributed policy bundles, with the generated hydrofoil.policy gRPC types. |
pdp |
olai-pdp |
A Cedar policy decision point service: olai-auth's PDP wire API over Postgres-held grants, as a pdp binary, the ghcr.io/open-lakehouse/pdp image, or an embeddable router (docs/pdp.md). |
datafusion-policy-cedar depends on datafusion-policy and cedar-oci. pdp
stands alone: it decides requests for other services rather than queries.
datafusion-policy-cedar exposes a session-extension seam symmetric with other
DataFusion cross-cutting concerns: PolicyExtension::builder()…instrument(state)
wraps the session's QueryPlanner with a PolicyQueryPlanner that, per query,
resolves the principal, gathers facts, runs the Cedar decision, and — when the
fgac feature is on — rewrites the plan with row filters and column masks
before it executes. Per-request context flows through typed SessionConfig
extensions, so the host stays unaware of the internals.
See docs/policy-fact-gathering.md and the
runnable fact_gathering_walkthrough
example.
See CONTRIBUTING.md. In short:
cargo build --workspace --all-features
cargo test --workspace --all-featuresReleases are automated with release-plz; crate versions and changelogs are derived from conventional-commit history.