rn-forge-auth
rn-forge-auth holds authentication and authorization primitives, built on
rn-forge-web: the identity, account-resolution and authorization-context
contracts, Principal and Requirement, the Authenticator and Authorizer
contracts, session, transaction and replay stores, the login flow and its OIDC,
OAuth 2.0, password and development providers, and the OIDC token profiles.
The base install gives the core, rn_forge.auth. The oidc extra adds
pyjwt[crypto], authlib, joserfc and requests for the adapter,
rn_forge.auth.oidc, and for the fake provider in rn_forge.auth.testing; the
redis extra adds redis for rn_forge.auth.redis. The core imports none of
them.
Install
Drop the extras you do not use. Start from the
minimum example. An
authenticator raises AuthenticationFailed (401) and ScopeAuthorizer raises
PermissionDenied (403); see
Authenticators and authorizers.
Where to start
- Authentication and authorization shows how the pieces fit and covers installing the core and its extras.
- Contracts, Login providers, Token profiles, Stores and Testing cover each subsystem.
- The API reference is generated from the docstrings.