Discussed in #135.
Adds a new function dangerous_insecure_decode_with_validation, which is a middle-ground between decode and dangerous_unsafe_decode. It takes a Validation and uses the validate function to run validations, but it does not do any signature verification.
I added the same set of tests that decode and dangerous_unsafe_decode have:
Regular
Invalid token
Invalid signature
Invalid algorithm
The new function passes numbers 1 and 3, but fails for numbers 2 and 4.
Note: the tests appear to be failing due to compiling the latest version of base64 (v0.12.2) on Rust 1.39.0.
Discussed in #135. Adds a new function
dangerous_insecure_decode_with_validation
, which is a middle-ground betweendecode
anddangerous_unsafe_decode
. It takes aValidation
and uses thevalidate
function to run validations, but it does not do any signature verification.I added the same set of tests that
decode
anddangerous_unsafe_decode
have:The new function passes numbers 1 and 3, but fails for numbers 2 and 4.
Note: the tests appear to be failing due to compiling the latest version of
base64
(v0.12.2) on Rust 1.39.0.