Rhonabwy
Create, modify, parse or export Json Web Keys as defined in the RFC 7517
|
#include <string.h>
#include <gnutls/abstract.h>
#include <gnutls/x509.h>
#include <gnutls/crypto.h>
#include <orcania.h>
#include <yder.h>
#include <ulfius.h>
#include <rhonabwy.h>
Macros | |
#define | RHN_BEGIN_CERT_TAG "-----BEGIN CERTIFICATE-----" |
Functions | |
int | r_jwk_init (jwk_t **jwk) |
void | r_jwk_free (jwk_t *jwk) |
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_key_type (jwk_t *jwk, unsigned int *bits, int x5u_flags) |
int | r_jwk_extract_pubkey (jwk_t *jwk_privkey, jwk_t *jwk_pubkey, int x5u_flags) |
int | r_jwk_import_from_json_str (jwk_t *jwk, const char *input) |
int | r_jwk_import_from_json_t (jwk_t *jwk, json_t *j_input) |
int | r_jwk_import_from_pem_der (jwk_t *jwk, int type, int format, const unsigned char *input, size_t input_len) |
int | r_jwk_import_from_gnutls_privkey (jwk_t *jwk, gnutls_privkey_t key) |
int | r_jwk_import_from_gnutls_pubkey (jwk_t *jwk, gnutls_pubkey_t pub) |
int | r_jwk_import_from_gnutls_x509_crt (jwk_t *jwk, gnutls_x509_crt_t crt) |
int | r_jwk_import_from_x5u (jwk_t *jwk, int x5u_flags, const char *x5u) |
int | r_jwk_import_from_symmetric_key (jwk_t *jwk, const unsigned char *key, size_t key_len) |
jwk_t * | r_jwk_copy (jwk_t *jwk) |
int | r_jwk_equal (jwk_t *jwk1, jwk_t *jwk2) |
char * | r_jwk_export_to_json_str (jwk_t *jwk, int pretty) |
json_t * | r_jwk_export_to_json_t (jwk_t *jwk) |
gnutls_privkey_t | r_jwk_export_to_gnutls_privkey (jwk_t *jwk) |
gnutls_pubkey_t | r_jwk_export_to_gnutls_pubkey (jwk_t *jwk, int x5u_flags) |
gnutls_x509_crt_t | r_jwk_export_to_gnutls_crt (jwk_t *jwk, int x5u_flags) |
int | r_jwk_export_to_pem_der (jwk_t *jwk, int format, unsigned char *output, size_t *output_len, int x5u_flags) |
int | r_jwk_export_to_symmetric_key (jwk_t *jwk, unsigned char *key, size_t *key_len) |
const char * | r_jwk_get_property_str (jwk_t *jwk, const char *key) |
const char * | r_jwk_get_property_array (jwk_t *jwk, const char *key, size_t index) |
int | r_jwk_get_property_array_size (jwk_t *jwk, const char *key) |
int | r_jwk_set_property_str (jwk_t *jwk, const char *key, const char *value) |
int | r_jwk_set_property_array (jwk_t *jwk, const char *key, size_t index, const char *value) |
int | r_jwk_append_property_array (jwk_t *jwk, const char *key, const char *value) |
int | r_jwk_delete_property_str (jwk_t *jwk, const char *key) |
int | r_jwk_delete_property_array_at (jwk_t *jwk, const char *key, size_t index) |
int | r_jwk_append_x5c (jwk_t *jwk, int format, const unsigned char *input, size_t input_len) |
char * | r_jwk_thumbprint (jwk_t *jwk, int hash, int x5u_flags) |
int | r_jwk_validate_x5c_chain (jwk_t *jwk, int x5u_flags) |
#define RHN_BEGIN_CERT_TAG "-----BEGIN CERTIFICATE-----" |
Rhonabwy JSON Web Key (JWK) library
jwk.c: functions definitions
Copyright 2020 Nicolas Mora mail@ babe loues t.or g
This program is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; version 2.1 of the License.
This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU GENERAL PUBLIC LICENSE for more details.
You should have received a copy of the GNU General Public License along with this library. If not, see http://www.gnu.org/licenses/.