Closed brandonros closed 1 year ago
You have to create a dummy DecodingKey and use https://docs.rs/jsonwebtoken/latest/jsonwebtoken/struct.Validation.html#method.insecure_disable_signature_validation
Example i haven't run:
let key = DecodingKey::from_secret(&[]);
let mut validation = Validation::new(Algorithm::HS256);
validation.insecure_disable_signature_validation();
let data = decode<TypeYouWant>(&token, &key, &validation)?;
Thank you!
I just want to be able to feed this library a JWT issued from a website and extract the expiration date, etc.
Since I am issued it by a website, I don't think I'd know the appropriate keys/secrets to validate its signature?