4.0 KiB
4.0 KiB
Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
[1.0.2] - 2026-11-06
Fixed
is_allowed()with a NULL user id failed with a NOT NULL violation onauth_cacheinstead of answering.is_allowed()andis_allowed_nocache()now return FALSE for a NULL user, the answerrls_check()already gave. Decisions for real users are unchanged.
1.0.1 - 2026-10-14
Fixed
is_allowed_nocache()(and so every uncachedis_allowed()) resolved the user's roles once per row of the wholerulestable, callingget_comprehensive_roles()andorg_in_scope()for every rule of every tenant: about 240 ms per decision with 2376 rules across 27 orgs. Roles are now resolved once per org where the user can hold one and that has a rule for the requested activity and view, and matching rules are read through those (org, role) pairs;org_in_scope()runs once per (org, scope) pair. Cost no longer grows with other tenants' rules. Decisions are unchanged, checked against the 1.0.0 implementation on a randomized fixture (tests/17_is_allowed_equivalence.sql).tools/bump_version.shno longer rewrites the PGXNmeta-specversion inMETA.json.
1.0.0 - 2026-07-25
Added
- First stable release of the Multi-OrBAC PostgreSQL extension
- Complete Multi-OrBAC implementation based on CNRS research paper
- Core features:
- Organization-centric access control
- Role-based abstraction with organizational scope
- Activity and view abstractions
- Context-based rule evaluation
- Four deontic modalities (permission, prohibition, obligation, recommendation)
- Prohibition precedence over permissions
- Multi-organization support
- Advanced features:
- Organization, role, activity, and view hierarchies with transitive closure
- Temporal delegation with time bounds
- Temporal constraints on rules with validity periods (valid_from, valid_until)
- Negative role assignments
- Separation of Duty (SoD) constraints
- Role cardinality constraints (min/max users)
- Derived roles (computed via functions)
- Cross-organizational rules with temporal support
- Administration rules (meta-policies)
- Audit logging for security-critical operations
- Audit logging system:
- Generic audit trigger for tracking INSERT/UPDATE/DELETE operations
- Comprehensive audit log with JSONB support for before/after states
- Helper functions:
enable_audit(),disable_audit() - Field-level change tracking
- Client connection metadata capture (IP, application name, session user)
- Policy DSL with idempotent compiler
- RLS helper functions for PostgREST integration
- Comprehensive test suite with 20 test scenarios
- Complete documentation
- Build and installation automation (Makefile, install.sh)
- Unattributed (no-org) object support:
- Org target vocabulary shared by every rule kind: a specific organization,
unattributed(objects with no org), orall(every org, unattributed included) rules.scopevaluesunattributedandalluser_rules.org_idaccepts NULL to target unattributed objectsorg_in_scope()partitions the two object classes:unattributedmatches only a NULL target, tree scopes never match onemorbac.has_permission(user, activity, view)capability probe for UI gatingmorbac.current_org_filter()parsesmorbac.org_idsonce into org UUIDs plus the unattributed-bucket flag (a JSONnullelement requests it)rls_check()split by arity so NULL never carries two meanings:rls_check(activity, view)for tables with no org column,rls_check(activity, view, row_org_id[, row_user_id])for row-scoped tables where a NULLrow_org_idmeans the record is unattributed
- Org target vocabulary shared by every rule kind: a specific organization,