Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update jwt.py #434

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions okta/jwt.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class JWT():
OAUTH_ENDPOINT = "/oauth2/v1/token"
HASH_ALGORITHM = "RS256"
PEM_FORMAT = "PKCS1"
ONE_HOUR = 1 * 60 * 60
EXPIRATION = 1 * 60 * 59
JWT_OPTIONS = {
'verify_signature': True,
'verify_aud': True,
Expand Down Expand Up @@ -116,7 +116,7 @@ def create_token(org_url, client_id, private_key, kid=None):
my_pem, _ = JWT.get_PEM_JWK(private_key)
# Get current time and expiry time for token
issued_time = int(time.time())
expiry_time = issued_time + JWT.ONE_HOUR
expiry_time = issued_time + JWT.EXPIRATION
# generate unique JWT ID
generated_JWT_ID = str(uuid.uuid4())

Expand Down