mirror of
https://github.com/edumeet/edumeet.git
synced 2026-01-23 10:36:11 +00:00
Add session/url param state check in auth/callback
This commit is contained in:
parent
419a24f9e8
commit
7095d6b98e
1 changed files with 7 additions and 0 deletions
|
|
@ -512,6 +512,13 @@ async function setupAuth()
|
|||
if (req.method === 'POST')
|
||||
state = JSON.parse(base64.decode(req.body.state));
|
||||
}
|
||||
|
||||
if (!state || !state.peerId || !state.RoomId)
|
||||
{
|
||||
res.redirect('/auth/login');
|
||||
logger.debug('Empty state or state.peerId or state.RoomId in auth/callback');
|
||||
}
|
||||
|
||||
const { peerId, roomId } = state;
|
||||
|
||||
req.session.peerId = peerId;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue