Liking cljdoc? Tell your friends :D
Clojure only.

jose.ring

Ring middleware for verifying Bearer JWT credentials.

wrap-bearer adds verified claims to the request under :claims by default. It accepts either a verification JWK/key for jose.jwt/verify or a jose.jwks source for jose.jwt/verify-with-jwks.

Ring middleware for verifying Bearer JWT credentials.

`wrap-bearer` adds verified claims to the request under `:claims` by
default. It accepts either a verification JWK/key for `jose.jwt/verify` or
a `jose.jwks` source for `jose.jwt/verify-with-jwks`.
raw docstring

wrap-bearerclj

(wrap-bearer handler verification-key)
(wrap-bearer handler verification-key opts)

Wraps a Ring handler with Bearer JWT authentication.

On valid credentials, verified claims are associated under :claims (or the keyword supplied as :claims-key) before the handler is called. The :verify-opts map is passed to jose.jwt/verify or jose.jwt/verify-with-jwks; it should include an algorithm allow-list. Missing or invalid credentials return :unauthorized-response, or call :unauthorized-handler with the request when supplied.

Wraps a Ring handler with Bearer JWT authentication.

On valid credentials, verified claims are associated under `:claims` (or
the keyword supplied as `:claims-key`) before the handler is called. The
`:verify-opts` map is passed to `jose.jwt/verify` or
`jose.jwt/verify-with-jwks`; it should include an algorithm allow-list.
Missing or invalid credentials return `:unauthorized-response`, or call
`:unauthorized-handler` with the request when supplied.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close