Skip to content

Instantly share code, notes, and snippets.

@sfmohassel
Last active July 18, 2023 17:43
Show Gist options
  • Select an option

  • Save sfmohassel/572c3f3c80e0835ee6740c41f28c57df to your computer and use it in GitHub Desktop.

Select an option

Save sfmohassel/572c3f3c80e0835ee6740c41f28c57df to your computer and use it in GitHub Desktop.
Generate RSA Key-Value Pair for JWK
ssh-keygen -t rsa -b 4096 -m PEM -f jwtRS256.key
# enter no password!
# copy fingerprint and store it. You can use it as Key ID
openssl rsa -in jwtRS256.key -pubout -outform PEM -out jwtRS256.key.pub
cat jwtRS256.key | tr -d '\n'
cat jwtRS256.key.pub | tr -d '\n'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment