Skip to content

Kerberos.jsAuthorization that runs inside your app

Cerbos-style RBAC + ABAC policies, Zanzibar-inspired ReBAC relations and Cerbos-compatible query plans — zero dependencies, no server to deploy, ~38 KB min+gzip.

Kerberos.js

Benchmarks ​

A Kerberos.js decision is a function call inside your process and takes about a microsecond. A policy server answers over the network instead. The chart runs the same checks in Kerberos.js, five JavaScript authorization libraries, OPA and Cerbos, all on one machine. Every library is first checked to reach the same allow and deny decisions.

Ownership condition
A USER may view a document they own: one role-gated rule with an attribute condition. ops/s, log scale — higher is better.
In-process
CASLability built once per user
14.9M
@rbac/rbaccan(role, operation, params)
3.76M
CASLability built per request
1.87M
AccessControltryCan(…).do(…)
955k
Kerberos.jsisAllowed · checkResources
810k
easy-rbaccan(roles, operation, params)
693k
OPARego compiled to WebAssembly, in-process
428k
casbinenforce · batchEnforce
297k
Sidecar — a network round-trip per call
OPA serverREST Data API, sidecar on localhost
2,159
Cerbos PDPgRPC SDK, sidecar on localhost
1,399
Apple M3 Max · 16 cores · Node v24.14.1 · Docker 27.4.0 · median of 5 × 1 s samples, each library in a fresh process · 2026-10-03

Method, cold start, bundle size and the raw numbers →

Used by ​

HirevelNexaFlow

Using Kerberos.js in production? Open a PR to add your logo.

Released under the MIT License.