Skip to content

Instantly share code, notes, and snippets.

@pgebert
Created December 6, 2021 21:22
Show Gist options
  • Save pgebert/627be9d356a0cd9888ca35b21b4f3c32 to your computer and use it in GitHub Desktop.
Save pgebert/627be9d356a0cd9888ca35b21b4f3c32 to your computer and use it in GitHub Desktop.
Decryption of an example jwt token with python.
import base64
import json
/**
* Created by pgebert on 06/12/21.
*
* Decryption of an example jwt token with python.
*/
token = 'eyJuYW1lIjogInVzZXJfbmFtZSJ9'
decoded = base64.b64decode(token)
data = json.loads(decoded)
print(data) # Output: {'name': 'user_name'}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment