|
|
|
@ -66,6 +66,7 @@ io.configure(function(){ |
|
|
|
|
console.log('Cookie vroomsession not found, access unauthorized'); |
|
|
|
|
accept('vroomsession cookie not found', false); |
|
|
|
|
} |
|
|
|
|
else{ |
|
|
|
|
// vroomsession is base64(user:room:token) so let's decode this !
|
|
|
|
|
session = new Buffer(session, encoding='base64'); |
|
|
|
|
var tab = session.toString().split(':'); |
|
|
|
@ -77,6 +78,7 @@ io.configure(function(){ |
|
|
|
|
console.log('Forbidden chars found in either participant session, room name or token, sorry, cannot allow this'); |
|
|
|
|
accept('Forbidden characters found', false); |
|
|
|
|
} |
|
|
|
|
else{ |
|
|
|
|
// Ok, now check if this user has joined the room (with the correct token) through vroom frontend
|
|
|
|
|
checkRoom(room,token,user, function(res){ |
|
|
|
|
if (res){ |
|
|
|
@ -88,6 +90,8 @@ io.configure(function(){ |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
else{ |
|
|
|
|
accept('No cookie found', false); |
|
|
|
|
} |
|
|
|
|