mirror of
https://github.com/arun11299/cpp-jwt.git
synced 2025-05-15 01:08:31 +00:00
Added more documentation and some bug fixes in verification process
This commit is contained in:
parent
3d9e15b5c8
commit
e42720a446
6 changed files with 91 additions and 10 deletions
|
@ -17,6 +17,7 @@ enum class AlgorithmErrc
|
|||
|
||||
/**
|
||||
* Algorithm error conditions
|
||||
* TODO: Remove it or use it!
|
||||
*/
|
||||
enum class AlgorithmFailureSource
|
||||
{
|
||||
|
@ -27,18 +28,29 @@ enum class AlgorithmFailureSource
|
|||
*/
|
||||
enum class DecodeErrc
|
||||
{
|
||||
// No algorithms provided in decode API
|
||||
EmptyAlgoList = 1,
|
||||
// The JWT signature has incorrect format
|
||||
SignatureFormatError,
|
||||
// The JSON library failed to parse
|
||||
JsonParseError,
|
||||
// Algorithm field in header is missing
|
||||
AlgHeaderMiss,
|
||||
// Type field in header is missing
|
||||
TypHeaderMiss,
|
||||
// Unexpected type field value
|
||||
TypMismatch,
|
||||
// Found duplicate claims
|
||||
DuplClaims,
|
||||
// Key/Secret not passed as decode argument
|
||||
KeyNotPresent,
|
||||
// Key/secret passed as argument for NONE algorithm.
|
||||
// Not a hard error.
|
||||
KeyNotRequiredForNoneAlg,
|
||||
};
|
||||
|
||||
/**
|
||||
* Errors handled during verification process.
|
||||
*/
|
||||
enum class VerificationErrc
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue