JOSE Guide¶
This part of the documentation contains information on the JOSE implementation. It includes:
JSON Web Signature (JWS)
JSON Web Encryption (JWE)
JSON Web Key (JWK)
JSON Web Algorithm (JWA)
JSON Web Token (JWT)
Important
We are splitting the jose
module into a separated package. You may be
interested in joserfc.
Usage¶
A simple example on how to use JWT with Authlib:
from authlib.jose import jwt
with open('private.pem', 'rb') as f:
key = f.read()
payload = {'iss': 'Authlib', 'sub': '123', ...}
header = {'alg': 'RS256'}
s = jwt.encode(header, payload, key)
Guide¶
Follow the documentation below to find out more in detail.