Directories
¶
| Path | Synopsis |
|---|---|
|
Package admin0 exposes the mock's control-plane endpoints under /admin0/*.
|
Package admin0 exposes the mock's control-plane endpoints under /admin0/*. |
|
Package authapi mounts hand-coded Auth0 Authentication API endpoints onto chi.
|
Package authapi mounts hand-coded Auth0 Authentication API endpoints onto chi. |
|
Package authorizeerr keeps the in-memory rules that make /authorize fail on purpose: a rule with an optional match on the /authorize query returns an OAuth error to the redirect_uri instead of logging the user in.
|
Package authorizeerr keeps the in-memory rules that make /authorize fail on purpose: a rule with an optional match on the /authorize query returns an OAuth error to the redirect_uri instead of logging the user in. |
|
Package bearer provides middleware that validates an Authorization: Bearer JWT against a jwks.KeySet and attaches the claims to the request context.
|
Package bearer provides middleware that validates an Authorization: Bearer JWT against a jwks.KeySet and attaches the claims to the request context. |
|
Package claims owns a per-process map of custom JWT claims that get merged into every access token minted by the authapi package.
|
Package claims owns a per-process map of custom JWT claims that get merged into every access token minted by the authapi package. |
|
Package clock provides a pluggable Now() time source so the mock's protocol-time outputs (JWT iat/exp, code/OTP TTLs, bearer validation) can be frozen or skewed at runtime via /admin0/clock for deterministic tests.
|
Package clock provides a pluggable Now() time source so the mock's protocol-time outputs (JWT iat/exp, code/OTP TTLs, bearer validation) can be frozen or skewed at runtime via /admin0/clock for deterministic tests. |
|
Package config loads runtime settings from environment variables.
|
Package config loads runtime settings from environment variables. |
|
Package events owns the in-process Server-Sent Events hub for the mock's GET /events endpoint.
|
Package events owns the in-process Server-Sent Events hub for the mock's GET /events endpoint. |
|
Package httperr writes JSON error responses in either Auth0 Management API shape or Auth0 Authentication API shape.
|
Package httperr writes JSON error responses in either Auth0 Management API shape or Auth0 Authentication API shape. |
|
Package journal records Management API calls in a bounded in-memory ring so tests can assert on what the application under test actually sent.
|
Package journal records Management API calls in a bounded in-memory ring so tests can assert on what the application under test actually sent. |
|
Package jwks owns the in-process RS256 signing key, JWT minting, JWT verification, and JWKS publication.
|
Package jwks owns the in-process RS256 signing key, JWT minting, JWT verification, and JWKS publication. |
|
Package logger constructs the project's zerolog.Logger.
|
Package logger constructs the project's zerolog.Logger. |
|
Package matches owns the in-memory store of registered mock expectations.
|
Package matches owns the in-memory store of registered mock expectations. |
|
Package mfa implements the in-memory state for Auth0's MFA challenge dance.
|
Package mfa implements the in-memory state for Auth0's MFA challenge dance. |
|
Package mgmtapi mounts the spec-driven Management API surface onto chi: one generic, bearer-protected handler per Auth0 Management API operation.
|
Package mgmtapi mounts the spec-driven Management API surface onto chi: one generic, bearer-protected handler per Auth0 Management API operation. |
|
Package middleware contains shared net/http middleware.
|
Package middleware contains shared net/http middleware. |
|
Package permissions owns a per-audience map of permission strings.
|
Package permissions owns a per-audience map of permission strings. |
|
Package pkce implements the in-memory store of per-code authorization state that links a /authorize redirect to its later /oauth/token exchange.
|
Package pkce implements the in-memory store of per-code authorization state that links a /authorize redirect to its later /oauth/token exchange. |
|
Package router builds the http.Handler that fronts the mock service.
|
Package router builds the http.Handler that fronts the mock service. |
|
Package seed loads a YAML or JSON seed file into the mock's in-memory stores: expectations, claims, claim mappings, permissions and the MFA flag.
|
Package seed loads a YAML or JSON seed file into the mock's in-memory stores: expectations, claims, claim mappings, permissions and the MFA flag. |
|
Package server hosts the HTTP and (later) HTTPS listeners.
|
Package server hosts the HTTP and (later) HTTPS listeners. |
|
Package session keeps the in-memory state that ties a logged-in user to the tokens the mock has issued, so later requests (/userinfo) can see the same user the id_token described.
|
Package session keeps the in-memory state that ties a logged-in user to the tokens the mock has issued, so later requests (/userinfo) can see the same user the id_token described. |
|
Package spec wraps the embedded Auth0 Management API skeleton.
|
Package spec wraps the embedded Auth0 Management API skeleton. |
|
Package tlscert produces a *tls.Config from either user-supplied cert/key files or an auto-generated self-signed cert covering configured hostnames.
|
Package tlscert produces a *tls.Config from either user-supplied cert/key files or an auto-generated self-signed cert covering configured hostnames. |
|
Package tmpl parses and renders response templates: JSON bodies and header values that hold {{uuid}}, {{now}}, {{path.NAME}} and {{body.PATH}} placeholders.
|
Package tmpl parses and renders response templates: JSON bodies and header values that hold {{uuid}}, {{now}}, {{path.NAME}} and {{body.PATH}} placeholders. |
|
Package version exposes build-time metadata baked into the binary at link time via `-ldflags="-X ..."`.
|
Package version exposes build-time metadata baked into the binary at link time via `-ldflags="-X ..."`. |
Click to show internal directories.
Click to hide internal directories.