Duration in Strategy configuration
Closed this issue · 3 comments
bencmbrook commented
Instead of including the state
and duration
options on the route handler, can it not be included in the strategy's options? I know it works when setting the state
, but it does not for duration
.
For example:
passport.use(new RedditStrategy({
clientID: REDDIT_CONSUMER_KEY,
clientSecret: REDDIT_CONSUMER_SECRET,
callbackURL: "http://127.0.0.1:3000/auth/reddit/callback",
state: "exampleState", // works
duration: "permanent" // does not work
},
function(...
manuel-di-iorio commented
+1
generalpiston commented
Confirmed this issue. I tried a few different variations:
duration
inRedditStrategy
instantiation.duration
andstate
inRedditStrategy
instantiation.duration
inauthenticate
call.duration
andstate
inauthenticate
call.duration
andstate
inRedditStrategy
instantiation and inauthenticated
call.
Nothing gets duration
into the list of query parameters.
Slotos commented
duration
parameter goes to authenticate
call.
Example app is updated and I had tested that duration is passed along. You can use it yourself, I'd made it take secrets from runtime environment. If that doesn't help, share the code you're having trouble with.
Closing this issue as non-reproducible. Will reopen once a reproduction case is presented.