csrf token handling, two jwt tokens
This commit is contained in:
@@ -38,8 +38,8 @@ const authenticateSocket = async (socket, next) => {
|
||||
return next(new Error("Authentication required"));
|
||||
}
|
||||
|
||||
// Verify JWT
|
||||
const decoded = jwt.verify(token, process.env.JWT_SECRET);
|
||||
// Verify JWT (access tokens only)
|
||||
const decoded = jwt.verify(token, process.env.JWT_ACCESS_SECRET);
|
||||
const userId = decoded.id;
|
||||
|
||||
if (!userId) {
|
||||
|
||||
Reference in New Issue
Block a user