دنبال کننده ها

۱۳۹۶ مهر ۱۲, چهارشنبه

node.js - Add time to jsonwebtoken expire date

[ad_1]



I'm using jsonwebtoken and I would like to know if it's possible to add time to an expire date of a specific token. I know how to refresh a token but I just want to extend the date of expiration. I want to do it when I check the token everytime the user make a request like this :



jwt.verify(token, PASS, (err, decoded) => 
if (!err)
jwt.sign(decoded, PASS, expiresIn: 60);

);


Thanks a lot for your help




[ad_2]

لینک منبع