JWT is a scam and your app doesn't need it
The article critiques the use of JSON Web Tokens (JWT) in application development, arguing that they create more problems than they solve. It highlights the inability to invalidate JWTs before expiration, leading to security vulnerabilities. The author suggests that simpler, stateful alternatives are more effective for authentication.
- ▪JWTs are often seen as a solution for stateless authentication, but they come with significant drawbacks.
- ▪The inability to invalidate a JWT means that compromised tokens can remain valid until they expire.
- ▪Using short-lived access tokens with refresh tokens complicates the authentication process without addressing the core issues.
Opening excerpt (first ~120 words) tap to expand
try { if(localStorage) { let currentUser = localStorage.getItem('current_user'); if (currentUser) { currentUser = JSON.parse(currentUser); if (currentUser.id === 205284) { document.getElementById('article-show-container').classList.add('current-user-is-article-author'); } } } } catch (e) { console.error(e); } Dusan Malusev Posted on May 23 • Originally published at dusanmalusev.dev JWT is a scam and your app doesn't need it #auth #security #architecture #jwt I am tired of pretending JWT is fine. It isn't. It's a cargo cult.
…
Excerpt limited to ~120 words for fair-use compliance. The full article is at DEV.to (Top).