Security Risks in Stateless JWT Authentication in MERN Apps
DOI:
https://doi.org/10.70849/IJSCIKeywords:
JWT, MERN Stack, Stateless Authentication, Token Security, Redis Blacklisting, Token Rotation, Web Security, Node.js, React.jsAbstract
Modern web apps frequently employ JSON Web Tokens (JWT) for permission and authentication, particularly when developing with the MERN stack (MongoDB, Express, React, and Node.js). Lightweight and stateless, JWTs enable servers to authenticate users without storing session information. But even while this increases scalability and performance, there are a number of significant security issues involved. These hazards are unavoidable in today's web-driven world, particularly in light of the escalating dangers of token replay attacks, token hijacking, insecure storage, and inadequate secret management.The security issues surrounding the use of stateless JWTs in MERN applications are the main topic of this work. Many developers utilize JWT without fully comprehending its flaws, which include improper validation, exposed sensitive payload data, and lengthy token lifespans without revocation procedures. The suggested strategy investigates remedies such as token rotation, short-lived tokens with refresh methods, token blacklisting utilizing Redis, and safe secret management procedures in order to lessen these problems.Case studies and real-time simulations show how these enhancements lessen the attack surfaces in authentication flows. Adopting JWT and appropriately securing it are crucial as apps grow. Today's web applications require more robust and intelligent authentication to safeguard users and data, much like traffic in contemporary cities requires better regulations. This study emphasizes how crucial it is to update our procedures in order to create effective apps and ensure their security in a world where dangers are constantly changing.
Downloads
Published
Issue
Section
License

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.








