Resolve JWT 401 Timing Bug

Resolve JWT 401 Timing Bug

Resolve JWT 401 Timing Bug

工作概述

位置
全球
工作类型
Freelancer.com
薪水
$234 - $1,950 项目报价
发布日期
1 天 前

额外细节

工作编号
65395
工作视图
22

职位描述

I need help chasing down a stubborn timing issue in my FastAPI application. We use JWT for authentication and, although the login endpoint now works, a handful of users still see a 401 (“Signature has expired”) immediately after a successful login. A second attempt succeeds, and the problem shows up more on the staging server than locally.

Your task is to pinpoint the root cause and patch the existing codebase without touching the overall login flow, users, or database schema. While you are in there, make sure the issued tokens rely strictly on UTC for both iat and exp, introduce a roughly 10-second leeway when validating them, and add a regression test so we never see this again.

Deliverables
• Code patch that eliminates the intermittent 401
• Updated JWT creation/verification logic with UTC timestamps and 10-second tolerance
• One automated test reproducing the old failure and confirming the fix (e.g., with pytest)
• A concise note explaining why it happened and how it was resolved

Acceptance criteria: 50 consecutive logins on the staging environment must complete without a single 401. Protected endpoints must keep functioning exactly as before.

---
來源:Freelancer.com | 出價次數:0 | 剩餘時間:6 日 | 專案類型:固定預算

常見問題 FAQ

點樣申請呢份工?

請點擊頁面上嘅「立即申請」按鈕,或者按照聯絡資料聯絡僱主。

申請後幾耐有回覆?

回覆時間視乎僱主,一般 1-2 星期內會有面試邀請。

呢份工係唔係真實㗎?

EZJobs 上嘅所有職位都經過審核,確保真實有效。

位置

类似职位

Freelancer.com
Freelancer.com
Freelancer.com
Freelancer.com

饼干

本网站使用cookie来确保您在我们的网站上获得最佳体验。

接受