jaredhanson / jaredhanson/passport-http

Add auth info in basic callback

Open
#14 6 comments 1 reaction 0 assignees View on GitHub
Dominant language
JavaScript
Stars
261
Forks
112
PR merge metrics
No merged PRs in 30d

Description

At the moment you are not taking info in basic auth callback. So extra information about authenticated client cannot be passed to req.authInfo object.
I changed code as follows.
this._verify(userid, password, function(err, user, info) {
if (err) { return self.error(err); }
if (!user) { return self.fail(self._challenge()); }
self.success(user, info);
});

I am sure others would also benefit if you change code as above.

Contributor guide

Open the contributing guide

Research direction

Start at the basic authentication callback and trace the verify callback through the success path. Confirm that the extra info argument is passed with the authenticated user and becomes available on req.authInfo; the issue does not name a file or test to run.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
authentication
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.