javascript - How to dinamically configure Passportjs strategies? -
i playing around passport, , configuring twitter login way:
passport.use(new twitterstrategy({ consumerkey: '*****', consumersecret: '*****', callbackurl: "http://blabla/callback" }, function(token, tokensecret, profile, done) { done(null, profile) } ));
i want able configure values: (consumerkey, consumersecret, callbackurl) on runtime, based on logged user. advice?
you need use your consumer key , consumer secret, not ones of users. application able authenticate your users using twitter. keys , secrets used authenticate app twitter api.
see example project:
Comments
Post a Comment