l8w8jwt
Loading...
Searching...
No Matches
Public Attributes | List of all members
l8w8jwt_claim Struct Reference

#include <claim.h>

Public Attributes

char * key
 
size_t key_length
 
char * value
 
size_t value_length
 
int type
 

Detailed Description

Struct containing a jwt claim key-value pair.

If allocated on the heap by the decode function, remember to call l8w8jwt_claims_free() on it once you're done using it.

Member Data Documentation

◆ key

char* l8w8jwt_claim::key

The token claim key (e.g. "iss", "iat", "sub", etc...).

NUL-terminated C-string!

◆ key_length

size_t l8w8jwt_claim::key_length

key string length.

Set this to 0 if you want to make the encoder use strlen(key) instead.

◆ type

int l8w8jwt_claim::type

The type of the claim's value.

0 = string, 1 = integer, 2 = number, 3 = boolean, 4 = null, 5 = array, 6 = object, 7 = other.

See also
https://www.w3schools.com/js/js_json_datatypes.asp

◆ value

char* l8w8jwt_claim::value

The claim's value as a NUL-terminated C-string.

◆ value_length

size_t l8w8jwt_claim::value_length

value string length.

Set this to 0 if you want to make the encoder use strlen(value) instead.


The documentation for this struct was generated from the following file: