mirror of
https://github.com/yuzu-emu/liftinstall.git
synced 2024-11-21 23:35:43 +01:00
Force disable exp and nbf validation.
Some clients had the wrong time information so it would fail to validate their token when installing. Remove these checks since they'll be checked on the server side anyway
This commit is contained in:
parent
6af46ec703
commit
eb556c8cab
@ -138,7 +138,7 @@ pub fn validate_token(
|
||||
};
|
||||
|
||||
// Configure validation for audience and issuer if the configuration provides it
|
||||
let validation = match validation {
|
||||
let mut validation = match validation {
|
||||
Some(v) => {
|
||||
let mut valid = Validation::new(Algorithm::RS256);
|
||||
valid.iss = v.iss;
|
||||
@ -149,7 +149,8 @@ pub fn validate_token(
|
||||
}
|
||||
None => Validation::default(),
|
||||
};
|
||||
|
||||
validation.validate_exp = false;
|
||||
validation.validate_nbf = false;
|
||||
// Verify the JWT token
|
||||
decode::<JWTClaims>(&body, pub_key.as_slice(), &validation)
|
||||
.map(|tok| tok.claims)
|
||||
|
Loading…
Reference in New Issue
Block a user