Replaced the legacy session-cookie authentication with a JWT-based token flow across the auth service layer. The existing SessionStore dependency was removed in favor of a new AuthMiddleware class that validates bearer tokens using RS256 signatures. The migration touches the core request pipeline, so downstream controllers that previously relied on req.session now receive a decoded token payload. Integration tests were updated to use a test JWT issuer.
Prepare the auth layer for multi-service token sharing ahead of the microservice split. Session cookies don't survive cross-origin API calls from the new mobile client.
UserController and AdminController must be updated to read from the token payload instead of req.session. The logout endpoint now needs a token revocation list or short-lived expiry strategy.