Rhonabwy
Javascript Object Signing and Encryption (JOSE) library - JWK, JWKS, JWS, JWE and JWT
|
Functions | |
int | r_jwk_key_type (jwk_t *jwk, unsigned int *bits, int x5u_flags) |
int | r_jwk_is_valid (jwk_t *jwk) |
int | r_jwk_is_valid_x5u (jwk_t *jwk, int x5u_flags) |
int | r_jwk_generate_key_pair (jwk_t *jwk_privkey, jwk_t *jwk_pubkey, int type, unsigned int bits, const char *kid) |
int r_jwk_generate_key_pair | ( | jwk_t * | jwk_privkey, |
jwk_t * | jwk_pubkey, | ||
int | type, | ||
unsigned int | bits, | ||
const char * | kid | ||
) |
Generates a pair of private and public key using given parameters
jwk_privkey | the private key to set, must be initialized |
jwk_pubkey | the public key to set, must be initialized |
type | the type of key, values available are R_KEY_TYPE_RSA or R_KEY_TYPE_EC |
bits | the key size to generate, if the key type is R_KEY_TYPE_EC, the key size is the curve length: 256, 384 or 512 |
kid | the key ID to set to the JWKs, if NULL or empty, will be set automatically |
int r_jwk_is_valid | ( | jwk_t * | jwk | ) |
Check if the jwk is valid
jwk | the jwk_t * to test |
int r_jwk_is_valid_x5u | ( | jwk_t * | jwk, |
int | x5u_flags | ||
) |
Check if the x5u property is valid
jwk | the jwk_t * to test |
x5u_flags | Flags to retrieve x5u certificates pointed by x5u if necessary, could be 0 if not needed Flags available are
|
int r_jwk_key_type | ( | jwk_t * | jwk, |
unsigned int * | bits, | ||
int | x5u_flags | ||
) |
Get the type and algorithm of a jwk_t
jwk | the jwk_t * to test |
bits | set the key size in bits (may be NULL) |
x5u_flags | Flags to retrieve x5u certificates pointed by x5u if necessary, could be 0 if not needed Flags available are
|