http: convert token to buffer for ws auth.
This commit is contained in:
parent
b76a382f78
commit
21b2a12278
@ -1159,6 +1159,8 @@ HTTPServer.prototype._initIO = function _initIO() {
|
||||
if (!utils.isHex256(token))
|
||||
return callback({ error: 'Invalid parameter.' });
|
||||
|
||||
token = new Buffer(token, 'hex');
|
||||
|
||||
if (socket.api && id === '!all') {
|
||||
socket.join(id);
|
||||
return callback();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user