JSON Web Token: Payload

JSON Web Tokens (JWT)Exploitation

From PayloadsAllTheThings by Swissky and contributors, under the MIT licence. Shown as written; the title and classification are ours. Licences. Its authors can have this tip removed by writing to abuse@bugbountytips.org.

json
{
    "sub":"1234567890",
    "name":"Amazing Haxx0r",
    "exp":"1466270722",
    "admin":true
}

Claims are the predefined keys and their values:

  • iss: issuer of the token

  • exp: the expiration timestamp (reject tokens which have expired). Note: as defined in the spec, this must be in seconds.

  • iat: The time the JWT was issued. Can be used to determine the age of the JWT

  • nbf: "not before" is a future time when the token will become active.

  • jti: unique identifier for the JWT. Used to prevent the JWT from being re-used or replayed.

  • sub: subject of the token (rarely used)

  • aud: audience of the token (also rarely used)

Inject payload claims with ticarpi/jwt_tool: python3 jwt_tool.py JWT_HERE -I -pc payload1 -pv testval3

Comments

No comments yet.