jaredhanson / passport-http

HTTP Basic and Digest authentication strategies for Passport and Node.js.
https://www.passportjs.org/packages/passport-http/?utm_source=github&utm_medium=referral&utm_campaign=passport-http&utm_content=about
MIT License
268 stars 110 forks source link

Two different basic strategies #58

Closed tielur closed 8 years ago

tielur commented 8 years ago

I'm trying to implement two different basic strategies, with two different sets of correct tokens. Right now it looks like the basic strategy hard codes the name to basic, it would be nice if you could set this via options that way you could have multiple basic strategies with different names.

If there is a better way to go about handling this I'd love to hear about it.

tielur commented 8 years ago

It looks like this is already supported by passport.

passport.use('another-basic-strat', new BasicStrategy({...