Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

http-auth

Package Overview
Dependencies
Maintainers
1
Versions
104
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

http-auth - npm Package Compare versions

Comparing version 1.1.2 to 1.1.3

2

lib/auth/digest.js

@@ -85,3 +85,3 @@ /**

if(userHash && typeof userHash === 'string') {
var ha1 = this.users[co.username];
var ha1 = this.users[co.username].split(":")[2];

@@ -88,0 +88,0 @@ // If algorithm is MD5-sess.

@@ -61,5 +61,4 @@ /**

if(authType == 'digest') {
var authTokens = authLine.split(":");
// Constructing A1 for digest access authentication.
authUsers[authTokens[0]] = authTokens[0] + ":" + authRealm + ":" + authTokens[1];
var authTokens = authLine.split(":");
authUsers[authTokens[0]] = authLine;
} else if(authType == 'basic') {

@@ -66,0 +65,0 @@ authUsers.push(authLine);

{
"name": "http-auth",
"description": "Node.js package for HTTP basic and digest access authentication.",
"version": "1.1.2",
"version": "1.1.3",
"author": "Gevorg Harutyunyan (http://github.com/gevorg)",

@@ -6,0 +6,0 @@ "maintainers": [

@@ -31,3 +31,4 @@ /**

// Initiates basic instance before each test.
source = new Digest("AweSome REALM", {"mia" : "mia:Private area.:supergirl"}, 'MD5');
source = new Digest("AweSome REALM", {"mia" :
"mia:Private area.:3a556dc7260e8e7f032d247fb668b06b"}, 'MD5');
// GOD knows why I need to call this.

@@ -34,0 +35,0 @@ callback();

@@ -119,3 +119,4 @@ /**

authRealm : "Some realm",
authList : ['karo:seed', 'samvel:beed'],
authList : ['samvel:Some realm:a14d1baeb46dd3f44d177cd28331f921',
'karo:Some realm:24b0b93d4e91583f77ee6da31ebeebc8'],
authType : 'digest'

@@ -126,4 +127,6 @@ });

// Checking for items.
test.equals(options.authUsers['karo'], 'karo:Some realm:seed', "User item is wrong!");
test.equals(options.authUsers['samvel'], 'samvel:Some realm:beed', "User item is wrong!");
test.equals(options.authUsers['karo'], 'karo:Some realm:24b0b93d4e91583f77ee6da31ebeebc8',
"User item is wrong!");
test.equals(options.authUsers['samvel'], 'samvel:Some realm:a14d1baeb46dd3f44d177cd28331f921',
"User item is wrong!");
// Test is done.

@@ -130,0 +133,0 @@ test.done();

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc