POC: Create and sign a JWT with iRule

Code is community submitted, community supported, and recognized as ‘Use At Your Own Risk’.

Short Description

This snippet creates and signes a JWT. Signing algorithm is RS256.

Problem solved by this Code Snippet

This is a simple way to create a valid JWT for testing purposes.

How to use this Code Snippet

  • Add a private key
  • Assign it to a VS and request "/jwt" to get a signed token

Code Snippet Meta Information

  1. Version: POC
  2. Coding Language: TCL

Full Code Snippet

https://github.com/JuergenMang/f5-irules-jwt/blob/main/jwt-sign

Updated Jan 19, 2024
Version 3.0

Was this article helpful?

No CommentsBe the first to comment