fathom.verify_token¶
fathom.verify_token(token, public_key, *, typ=EVALUATION_TOKEN_TYPE)
¶
Verify a JWT token and return the decoded payload.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
token
|
str
|
Compact JWS. |
required |
public_key
|
Ed25519PublicKey
|
Ed25519 public key. |
required |
typ
|
str | None
|
The token kind the caller expects: |
EVALUATION_TOKEN_TYPE
|
Raises AttestationError if verification fails, including for a key that is not an Ed25519 public key.