Rhonabwy: JWK, JWKS, JWS, JWE type

Rhonabwy Javascript Object Signing and Encryption (JOSE) library - JWK, JWKS, JWS, JWE and JWT

Data Structures | Macros | Typedefs | Enumerations
JWK, JWKS, JWS, JWE type

## Data Structures
struct | jws_t
struct | jwe_t
struct | jwt_t

## Macros
#define | RHONABWY_INTEGER_FORMAT JSON_INTEGER_FORMAT

## Typedefs
typedef json_t | jwk_t
typedef json_t | jwks_t
typedef json_int_t | rhn_int_t

## Enumerations
enum | jwa_alg { R_JWA_ALG_UNKNOWN = 0 , R_JWA_ALG_NONE = 1 , R_JWA_ALG_HS256 = 2 , R_JWA_ALG_HS384 = 3 , R_JWA_ALG_HS512 = 4 , R_JWA_ALG_RS256 = 5 , R_JWA_ALG_RS384 = 6 , R_JWA_ALG_RS512 = 7 , R_JWA_ALG_ES256 = 8 , R_JWA_ALG_ES384 = 9 , R_JWA_ALG_ES512 = 10 , R_JWA_ALG_EDDSA = 11 , R_JWA_ALG_PS256 = 12 , R_JWA_ALG_PS384 = 13 , R_JWA_ALG_PS512 = 14 , R_JWA_ALG_RSA1_5 = 15 , R_JWA_ALG_RSA_OAEP = 16 , R_JWA_ALG_RSA_OAEP_256 = 17 , R_JWA_ALG_A128KW = 18 , R_JWA_ALG_A192KW = 19 , R_JWA_ALG_A256KW = 20 , R_JWA_ALG_DIR = 21 , R_JWA_ALG_ECDH_ES = 22 , R_JWA_ALG_ECDH_ES_A128KW = 23 , R_JWA_ALG_ECDH_ES_A192KW = 24 , R_JWA_ALG_ECDH_ES_A256KW = 25 , R_JWA_ALG_A128GCMKW = 26 , R_JWA_ALG_A192GCMKW = 27 , R_JWA_ALG_A256GCMKW = 28 , R_JWA_ALG_PBES2_H256 = 29 , R_JWA_ALG_PBES2_H384 = 30 , R_JWA_ALG_PBES2_H512 = 31 , R_JWA_ALG_ES256K = 32 }
enum | rhn_claim_opt { R_JWT_CLAIM_NOP = 0 , R_JWT_CLAIM_ISS = 1 , R_JWT_CLAIM_SUB = 2 , R_JWT_CLAIM_AUD = 3 , R_JWT_CLAIM_EXP = 4 , R_JWT_CLAIM_NBF = 5 , R_JWT_CLAIM_IAT = 6 , R_JWT_CLAIM_JTI = 7 , R_JWT_CLAIM_STR = 8 , R_JWT_CLAIM_INT = 9 , R_JWT_CLAIM_JSN = 10 , R_JWT_CLAIM_TYP = 11 , R_JWT_CLAIM_CTY = 12 }
enum | jwa_enc { R_JWA_ENC_UNKNOWN = 0 , R_JWA_ENC_A128CBC = 1 , R_JWA_ENC_A192CBC = 2 , R_JWA_ENC_A256CBC = 3 , R_JWA_ENC_A128GCM = 4 , R_JWA_ENC_A192GCM = 5 , R_JWA_ENC_A256GCM = 6 }
enum | rhn_opt { RHN_OPT_NONE = 0 , RHN_OPT_HEADER_INT_VALUE = 1 , RHN_OPT_HEADER_STR_VALUE = 2 , RHN_OPT_HEADER_JSON_T_VALUE = 3 , RHN_OPT_HEADER_FULL_JSON_T = 4 , RHN_OPT_HEADER_FULL_JSON_STR = 5 , RHN_OPT_UN_HEADER_FULL_JSON_T = 6 , RHN_OPT_UN_HEADER_FULL_JSON_STR = 7 , RHN_OPT_PAYLOAD = 8 , RHN_OPT_CLAIM_INT_VALUE = 9 , RHN_OPT_CLAIM_STR_VALUE = 10 , RHN_OPT_CLAIM_JSON_T_VALUE = 11 , RHN_OPT_CLAIM_FULL_JSON_T = 12 , RHN_OPT_CLAIM_FULL_JSON_STR = 13 , RHN_OPT_ENC_ALG = 14 , RHN_OPT_ENC = 15 , RHN_OPT_SIG_ALG = 16 , RHN_OPT_CIPHER_KEY = 17 , RHN_OPT_IV = 18 , RHN_OPT_AAD = 19 , RHN_OPT_SIGN_KEY_JWK = 20 , RHN_OPT_SIGN_KEY_JWKS = 21 , RHN_OPT_SIGN_KEY_GNUTLS = 22 , RHN_OPT_SIGN_KEY_JSON_T = 23 , RHN_OPT_SIGN_KEY_JSON_STR = 24 , RHN_OPT_SIGN_KEY_PEM_DER = 25 , RHN_OPT_VERIFY_KEY_JWK = 26 , RHN_OPT_VERIFY_KEY_JWKS = 27 , RHN_OPT_VERIFY_KEY_GNUTLS = 28 , RHN_OPT_VERIFY_KEY_JSON_T = 29 , RHN_OPT_VERIFY_KEY_JSON_STR = 30 , RHN_OPT_VERIFY_KEY_PEM_DER = 31 , RHN_OPT_ENCRYPT_KEY_JWK = 32 , RHN_OPT_ENCRYPT_KEY_JWKS = 33 , RHN_OPT_ENCRYPT_KEY_GNUTLS = 34 , RHN_OPT_ENCRYPT_KEY_JSON_T = 35 , RHN_OPT_ENCRYPT_KEY_JSON_STR = 36 , RHN_OPT_ENCRYPT_KEY_PEM_DER = 37 , RHN_OPT_DECRYPT_KEY_JWK = 38 , RHN_OPT_DECRYPT_KEY_JWKS = 39 , RHN_OPT_DECRYPT_KEY_GNUTLS = 40 , RHN_OPT_DECRYPT_KEY_JSON_T = 41 , RHN_OPT_DECRYPT_KEY_JSON_STR = 42 , RHN_OPT_DECRYPT_KEY_PEM_DER = 43 }

## Detailed Description

Definition of the types jwk_t, jwks_t, jws_t and jwe_t

## Macro Definition Documentation

## ◆ RHONABWY_INTEGER_FORMAT

#define RHONABWY_INTEGER_FORMAT JSON_INTEGER_FORMAT

## Typedef Documentation

## ◆ jwk_t

typedef json_t jwk_t

## ◆ jwks_t

typedef json_t jwks_t

## ◆ rhn_int_t

typedef json_int_t rhn_int_t

## Enumeration Type Documentation

## ◆ jwa_alg

enum jwa_alg

Enumerator
R_JWA_ALG_UNKNOWN |
R_JWA_ALG_NONE |
R_JWA_ALG_HS256 |
R_JWA_ALG_HS384 |
R_JWA_ALG_HS512 |
R_JWA_ALG_RS256 |
R_JWA_ALG_RS384 |
R_JWA_ALG_RS512 |
R_JWA_ALG_ES256 |
R_JWA_ALG_ES384 |
R_JWA_ALG_ES512 |
R_JWA_ALG_EDDSA |
R_JWA_ALG_PS256 |
R_JWA_ALG_PS384 |
R_JWA_ALG_PS512 |
R_JWA_ALG_RSA1_5 |
R_JWA_ALG_RSA_OAEP |
R_JWA_ALG_RSA_OAEP_256 |
R_JWA_ALG_A128KW |
R_JWA_ALG_A192KW |
R_JWA_ALG_A256KW |
R_JWA_ALG_DIR |
R_JWA_ALG_ECDH_ES |
R_JWA_ALG_ECDH_ES_A128KW |
R_JWA_ALG_ECDH_ES_A192KW |
R_JWA_ALG_ECDH_ES_A256KW |
R_JWA_ALG_A128GCMKW |
R_JWA_ALG_A192GCMKW |
R_JWA_ALG_A256GCMKW |
R_JWA_ALG_PBES2_H256 |
R_JWA_ALG_PBES2_H384 |
R_JWA_ALG_PBES2_H512 |
R_JWA_ALG_ES256K |

## ◆ rhn_claim_opt

enum rhn_claim_opt

Enumerator
R_JWT_CLAIM_NOP |
R_JWT_CLAIM_ISS |
R_JWT_CLAIM_SUB |
R_JWT_CLAIM_AUD |
R_JWT_CLAIM_EXP |
R_JWT_CLAIM_NBF |
R_JWT_CLAIM_IAT |
R_JWT_CLAIM_JTI |
R_JWT_CLAIM_STR |
R_JWT_CLAIM_INT |
R_JWT_CLAIM_JSN |
R_JWT_CLAIM_TYP |
R_JWT_CLAIM_CTY |

## ◆ jwa_enc

enum jwa_enc

Enumerator
R_JWA_ENC_UNKNOWN |
R_JWA_ENC_A128CBC |
R_JWA_ENC_A192CBC |
R_JWA_ENC_A256CBC |
R_JWA_ENC_A128GCM |
R_JWA_ENC_A192GCM |
R_JWA_ENC_A256GCM |

## ◆ rhn_opt

enum rhn_opt

Enumerator
RHN_OPT_NONE | End option list, mandatory at the end of the option list.
RHN_OPT_HEADER_INT_VALUE | Header Integer value, following parameters must be const char * name, int i_value.
RHN_OPT_HEADER_STR_VALUE | Header String value, following parameters must be const char * name, const char * str_value.
RHN_OPT_HEADER_JSON_T_VALUE | Header JSON value, following parameters must be const char * name, json_t * j_value.
RHN_OPT_HEADER_FULL_JSON_T | JSON value to set the entire header, following parameter must be json_t * j_value.
RHN_OPT_HEADER_FULL_JSON_STR | Stringified JSON value to set the entire header, following parameter must be const char * str_value.
RHN_OPT_UN_HEADER_FULL_JSON_T | JSON value to set the entire unprotected header, following parameter must be json_t * j_value.
RHN_OPT_UN_HEADER_FULL_JSON_STR | Stringified JSON value to set the entire unprotected header, following parameter must be const char * str_value.
RHN_OPT_PAYLOAD | JSON value to set the entire payload, following parameters must be const unsigned char * value, size_t value_length.
RHN_OPT_CLAIM_INT_VALUE | Claims Integer value, following parameters must be const char * name, int i_value.
RHN_OPT_CLAIM_STR_VALUE | Claims String value, following parameters must be const char * name, const char * str_value.
RHN_OPT_CLAIM_JSON_T_VALUE | Claims JSON value, following parameters must be const char * name, json_t * j_value.
RHN_OPT_CLAIM_FULL_JSON_T | JSON value to set the entire claims, following parameter must be json_t * j_value.
RHN_OPT_CLAIM_FULL_JSON_STR | Stringified JSON value to set the entire claims, following parameter must be const char * str_value.
RHN_OPT_ENC_ALG | Key management algorithm, following parameter must be a jwa_alg value.
RHN_OPT_ENC | Encryption algorithm, following parameter must be a jwa_enc value.
RHN_OPT_SIG_ALG | Signature algorithm, following parameter must be a jwa_alg value.
RHN_OPT_CIPHER_KEY | Cipher key to encrypt data, following parameters must be const unsigned char * value, size_t value_length.
RHN_OPT_IV | Initial Value (IV) for data encryption, following parameters must be const unsigned char * value, size_t value_length.
RHN_OPT_AAD | Additional Authenticated Data (AAD) for data encryption, following parameters must be const unsigned char * value, size_t value_length.
RHN_OPT_SIGN_KEY_JWK | Private key in JWK format to sign the token, following parameter must be a jwk_t * value.
RHN_OPT_SIGN_KEY_JWKS | Private key set in JWKS format to sign the token, following parameter must be a jwks_t * value.
RHN_OPT_SIGN_KEY_GNUTLS | Private key in GnuTLS format to sign the token, following parameter must be a gnutls_privkey_t value.
RHN_OPT_SIGN_KEY_JSON_T | Private key in JSON format to sign the token, following parameter must be a json_t * value.
RHN_OPT_SIGN_KEY_JSON_STR | Private key in stringified JSON format to sign the token, following parameter must be a const char * value.
RHN_OPT_SIGN_KEY_PEM_DER | Private key in PEM or DER format to sign the token, following parameter must be R_FORMAT_PEM or R_FORMAT_DER, const unsigned char * value, size_t value_length.
RHN_OPT_VERIFY_KEY_JWK | Public key in JWK format to verify the token signature, following parameter must be a jwk_t * value.
RHN_OPT_VERIFY_KEY_JWKS | Public key set in JWKS format to verify the token signature, following parameter must be a jwks_t * value.
RHN_OPT_VERIFY_KEY_GNUTLS | Public key in GnuTLS format to verify the token signature, following parameter must be a gnutls_pubkey_t value.
RHN_OPT_VERIFY_KEY_JSON_T | Public key in JSON format to verify the token signature, following parameter must be a json_t * value.
RHN_OPT_VERIFY_KEY_JSON_STR | Public key in stringified JSON format to verify the token signature, following parameter must be a const char * value.
RHN_OPT_VERIFY_KEY_PEM_DER | Public key in PEM or DER format to verify the token signature, following parameter must be R_FORMAT_PEM or R_FORMAT_DER, const unsigned char * value, size_t value_length.
RHN_OPT_ENCRYPT_KEY_JWK | Public key in JWK format to encrypt the token, following parameter must be a jwk_t * value.
RHN_OPT_ENCRYPT_KEY_JWKS | Public key set in JWKS format to encrypt the token, following parameter must be a jwks_t * value.
RHN_OPT_ENCRYPT_KEY_GNUTLS | Public key in GnuTLS format to encrypt the token, following parameter must be a gnutls_pubkey_t value.
RHN_OPT_ENCRYPT_KEY_JSON_T | Public key in JSON format to encrypt the token, following parameter must be a json_t * value.
RHN_OPT_ENCRYPT_KEY_JSON_STR | Public key in stringified JSON format to encrypt the token, following parameter must be a const char * value.
RHN_OPT_ENCRYPT_KEY_PEM_DER | Public key in PEM or DER format to encrypt the token, following parameter must be R_FORMAT_PEM or R_FORMAT_DER, const unsigned char * value, size_t value_length.
RHN_OPT_DECRYPT_KEY_JWK | Private key in JWK format to decrypt the token, following parameter must be a jwk_t * value.
RHN_OPT_DECRYPT_KEY_JWKS | Private key set in JWKS format to decrypt the token, following parameter must be a jwks_t * value.
RHN_OPT_DECRYPT_KEY_GNUTLS | Private key in GnuTLS format to decrypt the token, following parameter must be a gnutls_privkey_t value.
RHN_OPT_DECRYPT_KEY_JSON_T | Private key in JSON format to decrypt the token, following parameter must be a json_t * value.
RHN_OPT_DECRYPT_KEY_JSON_STR | Private key in stringified JSON format to decrypt the token, following parameter must be a const char * value.
RHN_OPT_DECRYPT_KEY_PEM_DER | Private key in PEM or DER format to decrypt the token, following parameter must be R_FORMAT_PEM or R_FORMAT_DER, const unsigned char * value, size_t value_length.