Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
var decodeClientCredentials = function(auth) {
var clientCredentials = new Buffer(auth.slice('basic '.length), 'base64').toString().split(':');
var clientId = querystring.unescape(clientCredentials[0]);
var clientSecret = querystring.unescape(clientCredentials[1]);
return { id: clientId, secret: clientSecret };
};
var decodeClientCredentials = function(auth) {
var clientCredentials = new Buffer(auth.slice('basic '.length), 'base64').toString().split(':');
var clientId = querystring.unescape(clientCredentials[0]);
var clientSecret = querystring.unescape(clientCredentials[1]);
return { id: clientId, secret: clientSecret };
};
var decodeClientCredentials = function(auth) {
var clientCredentials = new Buffer(auth.slice('basic '.length), 'base64').toString().split(':');
var clientId = querystring.unescape(clientCredentials[0]);
var clientSecret = querystring.unescape(clientCredentials[1]);
return { id: clientId, secret: clientSecret };
};
var decodeClientCredentials = function(auth) {
var clientCredentials = new Buffer(auth.slice('basic '.length), 'base64').toString().split(':');
var clientId = querystring.unescape(clientCredentials[0]);
var clientSecret = querystring.unescape(clientCredentials[1]);
return { id: clientId, secret: clientSecret };
};