Skip to content

Commit

Permalink
use jti for createSession tokens
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidBuchanan314 committed Dec 29, 2024
1 parent b826d21 commit 054059f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/millipds/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ async def server_create_session(request: web.Request):
"sub": did,
"iat": unix_seconds_now,
"exp": unix_seconds_now + 60 * 60 * 24, # 24h
"jti": str(uuid.uuid4()),
},
db.config["jwt_access_secret"],
"HS256",
Expand All @@ -249,6 +250,7 @@ async def server_create_session(request: web.Request):
"sub": did,
"iat": unix_seconds_now,
"exp": unix_seconds_now + 60 * 60 * 24 * 90, # 90 days!
"jti": str(uuid.uuid4()),
},
db.config["jwt_access_secret"],
"HS256",
Expand Down

0 comments on commit 054059f

Please sign in to comment.