rrrodzilla / rusty_paseto

A type-driven, ergonomic RUST implementation of the PASETO protocol for secure stateless tokens.
https://crates.io/crates/rusty_paseto
MIT License
68 stars 8 forks source link

Add closure to claim validation API #1

Closed rrrodzilla closed 2 years ago

rrrodzilla commented 2 years ago

Currently, claim validation is a simple check that the claim exists in the decrypted token and the decrypted value matches the provided value. The API needs to be extended to allow the user to provide their own validation closure in order to support more complex validation scenarios.