add: Added an optional closure argument to the validate_claim method.
To be used to allow the user to provide custom validation logic for a
particular claim
add: Added logic in the parse method to run custom validation closures
if one is specified. This means claim validators will verify the
claim exists and verify the value matches what is expected. If a
custom closure is provided, the validator first checks the claim
exists and then the value is provided to the closure for further
validation by the end user.
add: PasetoTokenParseError::InvalidClaimValueType(String) for claim
values we try to convert to an invalid type
add: PasetoTokenParseError::CustomClaimValidation for claims which
fail in user provided custom validation closures
add: Implement Default trait on all reserved claims so that they can
be passed into custom validation closures
add: Implement From(&str) for CustomClaim so that they can be passed
into custom validation closures which always ignore passed in values
when adding the claim to the validator
add: Added an optional closure argument to the validate_claim method. To be used to allow the user to provide custom validation logic for a particular claim
add: Added logic in the parse method to run custom validation closures if one is specified. This means claim validators will verify the claim exists and verify the value matches what is expected. If a custom closure is provided, the validator first checks the claim exists and then the value is provided to the closure for further validation by the end user.
add: PasetoTokenParseError::InvalidClaimValueType(String) for claim values we try to convert to an invalid type
add: PasetoTokenParseError::CustomClaimValidation for claims which fail in user provided custom validation closures
add: Implement Default trait on all reserved claims so that they can be passed into custom validation closures
add: Implement From(&str) for CustomClaim so that they can be passed into custom validation closures which always ignore passed in values when adding the claim to the validator
chore: closes #1