← Blog

· Hive AI

Knolo KIP-0008: Deny Wins and the Policy Root Is Committed

Knolo KIP-0008 defines read-only policy evaluation for V5 query results: deny overrides allow, the policy root is committed in the image, and both runtimes agree.

Knolo is the open-source, local-first Knowledge Image runtime and format (Apache-2.0, @knolo/core on npm). An open format needs open rules for who may read what. In Knolo the first of those rules is KIP-0008, Policy Authorization V1, in the specification folder of the Knolo GitHub repo.

A note on status: the Knolo KIP index on knolo.org currently shows labeled example records, not accepted standards. KIP-0008 in the repo is marked "foundation implementation". It describes what the runtimes do today and has not been through a public acceptance process.

What Knolo KIP-0008 is, and is not

KIP-0008 adds deterministic, read-only policy evaluation for V5 query results. The spec is careful about scope: it is a policy filter and receipt primitive, not a signature, not delegation and not an identity provider. Signatures, delegation, group expansion, network identity and policy mutation are listed as later work.

The Knolo policy shape

A policy has a version, a default of allow or deny, and a list of rules. Each rule has an effect (allow or deny), an action (query or read), and may narrow itself to a principal or an object kind. Rules are normalized and sorted before hashing, so two people who write the same rules in a different order get the same policy root:

knolo:policy:v1\0 || canonical_cbor({"default": ..., "rules": [...]})

An empty rule list keeps the original V5 { "default": "deny" } root, so older images stay compatible.

Knolo commits the policy into the image

The committed image policyRoot must equal the evaluated policy root. This closes an obvious gap: a caller cannot evaluate a query under a friendlier policy than the one the image committed. The policy travels with the Knowledge Image and is pinned with it, the same way the content is.

Deny wins in Knolo evaluation

For each query hit, matching rules are the ones with the requested action that also match the principal and kind constraints, if present. A matching deny overrides every matching allow. A hit with no matching rule falls back to the policy default. The result is allow, partial or deny, plus the allowed and denied object IDs. Existing default-deny images remain readable and return denied results unless a matching policy was committed.

A Knolo authorization root anyone can recheck

Every decision produces an authorization root over the action, principal, decision, allowed and denied object IDs, and the plan, policy and state roots, with the knolo:authorization:v1 domain separator and canonical CBOR (the encoding covered in our Knolo KIP-0003 post). The TypeScript and Rust runtimes must produce identical policy and authorization roots for the same image, query result, policy, principal and action. That is what makes a second implementation's compatibility claim testable instead of a promise.

Verification proves integrity, not truth. An authorization root proves which policy filtered which objects; it does not say the objects are correct.

Read more

knolo · kip · specification · policy · knowledge-image · open-source