Liking cljdoc? Tell your friends :D

org.bdinetwork.ishare.jwt

Create, sign and unsign (validate) iSHARE JWTs.

See also: https://dev.ishare.eu/reference/ishare-jwt

Create, sign and unsign (validate) iSHARE JWTs.

See also: https://dev.ishare.eu/reference/ishare-jwt
raw docstring

decode-headerclj

(decode-header token)

Return header info from a signed JWT. Does not validate.

Return header info from a signed JWT. Does not validate.
sourceraw docstring

make-client-assertionclj

(make-client-assertion {:ishare/keys [client-id server-id x5c private-key]})

Create a signed client assertion for requesting an access token.

See https://dev.ishare.eu/reference/ishare-jwt

Create a signed client assertion for requesting an access token.

See https://dev.ishare.eu/reference/ishare-jwt
sourceraw docstring

make-jwtclj

(make-jwt
  {:keys [iat iss sub aud] :or {iat (seconds-since-unix-epoch)} :as claims}
  private-key
  x5c)

Generate JWT with provided claims, signed with private-key.

The JWT header is set with :alg as RS256, :typ "JWT" and :x5c from x5c (a vector of certificate strings). The first certificate in x5c should correspond to private-key.

A few claims are generated if not provided:

  • :iat -- the current time
  • :exp -- iat + 30 seconds
  • :jti -- a random UUID
  • :nbf -- iat

https://dev.ishare.eu/reference/ishare-jwt

Generate JWT with provided `claims`, signed with `private-key`.

The JWT header is set with :alg as RS256, :typ "JWT" and `:x5c`
from `x5c` (a vector of certificate strings). The first certificate
in `x5c` should correspond to `private-key`.

A few claims are generated if not provided:

- `:iat` -- the current time
- `:exp` -- iat + 30 seconds
- `:jti` -- a random UUID
- `:nbf` -- iat

https://dev.ishare.eu/reference/ishare-jwt
sourceraw docstring

unsign-client-assertionclj

(unsign-client-assertion client-assertion)

Parse a signed client assertion. Returns parsed data or raises exception.

Raises an exception when client-assertion is not valid for any reason including expiration.

Does not check revocation status of certificates.

Parse a signed client assertion. Returns parsed data or raises exception.

Raises an exception when client-assertion is not valid for any
reason including expiration.

Does not check revocation status of certificates.
sourceraw docstring

unsign-tokenclj

(unsign-token token)

Parse a signed token. Returns parsed data or raises exception.

Raises an exception when token is not a valid iSHARE JWT for any reason, including expiration.

Does not check revocation status of certificates.

Parse a signed token. Returns parsed data or raises exception.

Raises an exception when token is not a valid iSHARE JWT for any
reason, including expiration.

Does not check revocation status of certificates.
sourceraw docstring

x5c->first-public-keyclj

(x5c->first-public-key x5c)

Extract first public-key from x5c header.

Extract first public-key from x5c header.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close