feat(rbac)!: promote to v1.0.0 — MaxPermission constant, audit logging policy

Add MaxPermission constant (62) to make the valid bit range explicit in the API.
Document in PermissionProvider that audit logging belongs in the application layer.
API committed as stable: Identity, PermissionMask, context helpers, and
PermissionProvider interface are unchanged from v0.9.0.
This commit is contained in:
2026-05-07 22:46:44 -06:00
parent 0864f031a1
commit 18fcd2bee3
5 changed files with 51 additions and 0 deletions

View File

@@ -11,6 +11,10 @@ import "context"
// The resource string identifies what is being accessed (e.g. "orders",
// "invoices"). Its meaning is defined by the application.
//
// Audit logging of permission checks is out of scope for this package.
// Log denials and grants inside your PermissionProvider implementation or in
// the middleware layer that calls it.
//
// Example in-memory implementation for tests:
//
// type staticProvider struct {