Socket
Socket
Sign inDemoInstall

hawk

Package Overview
Dependencies
Maintainers
1
Versions
85
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.12.1 to 0.12.2

2

lib/browser.js

@@ -271,3 +271,3 @@ /*

var hash = CryptoJS[credentials.algorithm.toUpperCase()]('hawk.' + hawk.crypto.headerVersion + '.ts\n' + ts + '\n');
var hash = CryptoJS['Hmac' + credentials.algorithm.toUpperCase()]('hawk.' + hawk.crypto.headerVersion + '.ts\n' + ts + '\n', credentials.key);
return hash.toString(CryptoJS.enc.Base64);

@@ -274,0 +274,0 @@ }

@@ -0,0 +0,0 @@ // Load modules

@@ -94,6 +94,6 @@ // Load modules

var hash = Crypto.createHash(credentials.algorithm);
hash.update('hawk.' + exports.headerVersion + '.ts\n' + ts + '\n');
return hash.digest('base64');
var hmac = Crypto.createHmac(credentials.algorithm, credentials.key);
hmac.update('hawk.' + exports.headerVersion + '.ts\n' + ts + '\n');
return hmac.digest('base64');
};

@@ -0,0 +0,0 @@ // Export sub-modules

@@ -0,0 +0,0 @@ // Load modules

@@ -168,1 +168,8 @@ // Load modules

};
exports.unauthorized = function (message) {
return Boom.unauthorized(message, 'Hawk');
};
{
"name": "hawk",
"description": "HTTP Hawk Authentication Scheme",
"version": "0.12.1",
"version": "0.12.2",
"author": "Eran Hammer <eran@hueniverse.com> (http://hueniverse.com)",

@@ -6,0 +6,0 @@ "contributors": [],

@@ -0,0 +0,0 @@ ![hawk Logo](https://raw.github.com/hueniverse/hawk/master/images/hawk.png)

@@ -0,0 +0,0 @@ // Load modules

@@ -70,2 +70,11 @@ // Load modules

});
describe('#unauthorized', function () {
it('returns a hawk 401', function (done) {
expect(Hawk.utils.unauthorized('kaboom').response.headers['WWW-Authenticate']).to.equal('Hawk error="kaboom"');
done();
});
});
});

@@ -72,0 +81,0 @@ });

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc