libksba  1.5.0
About: KSBA is a library to make the tasks of working with X.509 certificates, CMS data and related objects more easy.
  Fossies Dox: libksba-1.5.0.tar.bz2  ("unofficial" and yet experimental doxygen-generated source code documentation)  

ksba.h File Reference
#include <gpg-error.h>
#include <stdio.h>
Include dependency graph for ksba.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define KSBA_VERSION   "1.5.0"
 
#define KSBA_VERSION_NUMBER   0x010500
 
#define _KSBA_DEPRECATED
 
#define KSBA_CLASS_UNIVERSAL   0
 
#define KSBA_CLASS_APPLICATION   1
 
#define KSBA_CLASS_CONTEXT   2
 
#define KSBA_CLASS_PRIVATE   3
 
#define KSBA_CLASS_ENCAPSULATE   0x80 /* Pseudo class. */
 
#define KSBA_TYPE_BOOLEAN   1
 
#define KSBA_TYPE_INTEGER   2
 
#define KSBA_TYPE_BIT_STRING   3
 
#define KSBA_TYPE_OCTET_STRING   4
 
#define KSBA_TYPE_NULL   5
 
#define KSBA_TYPE_OBJECT_ID   6
 
#define KSBA_TYPE_OBJECT_DESCRIPTOR   7
 
#define KSBA_TYPE_EXTERNAL   8
 
#define KSBA_TYPE_REAL   9
 
#define KSBA_TYPE_ENUMERATED   10
 
#define KSBA_TYPE_EMBEDDED_PDV   11
 
#define KSBA_TYPE_UTF8_STRING   12
 
#define KSBA_TYPE_RELATIVE_OID   13
 
#define KSBA_TYPE_TIME   14
 
#define KSBA_TYPE_SEQUENCE   16
 
#define KSBA_TYPE_SET   17
 
#define KSBA_TYPE_NUMERIC_STRING   18
 
#define KSBA_TYPE_PRINTABLE_STRING   19
 
#define KSBA_TYPE_TELETEX_STRING   20
 
#define KSBA_TYPE_VIDEOTEX_STRING   21
 
#define KSBA_TYPE_IA5_STRING   22
 
#define KSBA_TYPE_UTC_TIME   23
 
#define KSBA_TYPE_GENERALIZED_TIME   24
 
#define KSBA_TYPE_GRAPHIC_STRING   25
 
#define KSBA_TYPE_VISIBLE_STRING   26
 
#define KSBA_TYPE_GENERAL_STRING   27
 
#define KSBA_TYPE_UNIVERSAL_STRING   28
 
#define KSBA_TYPE_CHARACTER_STRING   29
 
#define KSBA_TYPE_BMP_STRING   30
 
#define KSBA_TYPE_DATE   31
 
#define KSBA_TYPE_TIME_OF_DAY   32
 
#define KSBA_TYPE_DATE_TIME   33
 
#define KSBA_TYPE_DURATION   34
 
#define KSBA_TYPE_OID_IRI   35
 
#define KSBA_TYPE_RELATIVE_OID_IRI   36
 

Typedefs

typedef gpg_error_t KsbaError
 
typedef ksba_content_type_t KsbaContentType
 
typedef ksba_stop_reason_t KsbaStopReason
 
typedef ksba_crl_reason_t KsbaCRLReason
 
typedef ksba_key_usage_t KsbaKeyUsage
 
typedef char ksba_isotime_t[16]
 
typedef struct ksba_cert_sksba_cert_t
 
typedef struct ksba_cert_sKsbaCert
 
typedef struct ksba_cms_sksba_cms_t
 
typedef struct ksba_cms_sKsbaCMS
 
typedef struct ksba_crl_sksba_crl_t
 
typedef struct ksba_crl_sKsbaCRL
 
typedef struct ksba_ocsp_sksba_ocsp_t
 
typedef struct ksba_certreq_sksba_certreq_t
 
typedef struct ksba_certreq_sKsbaCertreq
 
typedef struct ksba_reader_sksba_reader_t
 
typedef struct ksba_reader_sKsbaReader
 
typedef struct ksba_writer_sksba_writer_t
 
typedef struct ksba_writer_sKsbaWriter
 
typedef struct ksba_asn_tree_sksba_asn_tree_t
 
typedef struct ksba_asn_tree_sKsbaAsnTree
 
typedef struct ksba_name_sksba_name_t
 
typedef struct ksba_name_sKsbaName
 
typedef unsigned char * ksba_sexp_t
 
typedef unsigned char * KsbaSexp
 
typedef const unsigned char * ksba_const_sexp_t
 
typedef const unsigned char * KsbaConstSexp
 
typedef struct ksba_der_sksba_der_t
 

Enumerations

enum  ksba_content_type_t {
  KSBA_CT_NONE = 0, KSBA_CT_DATA = 1, KSBA_CT_SIGNED_DATA = 2, KSBA_CT_ENVELOPED_DATA = 3,
  KSBA_CT_DIGESTED_DATA = 4, KSBA_CT_ENCRYPTED_DATA = 5, KSBA_CT_AUTH_DATA = 6, KSBA_CT_PKCS12 = 7,
  KSBA_CT_SPC_IND_DATA_CTX = 8, KSBA_CT_OPENPGP_KEYBLOCK = 9
}
 
enum  ksba_stop_reason_t {
  KSBA_SR_NONE = 0, KSBA_SR_RUNNING = 1, KSBA_SR_GOT_CONTENT = 2, KSBA_SR_NEED_HASH = 3,
  KSBA_SR_BEGIN_DATA = 4, KSBA_SR_END_DATA = 5, KSBA_SR_READY = 6, KSBA_SR_NEED_SIG = 7,
  KSBA_SR_DETACHED_DATA = 8, KSBA_SR_BEGIN_ITEMS = 9, KSBA_SR_GOT_ITEM = 10, KSBA_SR_END_ITEMS = 11
}
 
enum  ksba_crl_reason_t {
  KSBA_CRLREASON_UNSPECIFIED = 1, KSBA_CRLREASON_KEY_COMPROMISE = 2, KSBA_CRLREASON_CA_COMPROMISE = 4, KSBA_CRLREASON_AFFILIATION_CHANGED = 8,
  KSBA_CRLREASON_SUPERSEDED = 16, KSBA_CRLREASON_CESSATION_OF_OPERATION = 32, KSBA_CRLREASON_CERTIFICATE_HOLD = 64, KSBA_CRLREASON_REMOVE_FROM_CRL = 256,
  KSBA_CRLREASON_PRIVILEGE_WITHDRAWN = 512, KSBA_CRLREASON_AA_COMPROMISE = 1024, KSBA_CRLREASON_OTHER = 32768
}
 
enum  ksba_ocsp_response_status_t {
  KSBA_OCSP_RSPSTATUS_SUCCESS = 0, KSBA_OCSP_RSPSTATUS_MALFORMED = 1, KSBA_OCSP_RSPSTATUS_INTERNAL = 2, KSBA_OCSP_RSPSTATUS_TRYLATER = 3,
  KSBA_OCSP_RSPSTATUS_SIGREQUIRED = 5, KSBA_OCSP_RSPSTATUS_UNAUTHORIZED = 6, KSBA_OCSP_RSPSTATUS_REPLAYED = 253, KSBA_OCSP_RSPSTATUS_OTHER = 254,
  KSBA_OCSP_RSPSTATUS_NONE = 255
}
 
enum  ksba_status_t { KSBA_STATUS_NONE = 0, KSBA_STATUS_UNKNOWN = 1, KSBA_STATUS_GOOD = 2, KSBA_STATUS_REVOKED = 4 }
 
enum  ksba_key_usage_t {
  KSBA_KEYUSAGE_DIGITAL_SIGNATURE = 1, KSBA_KEYUSAGE_NON_REPUDIATION = 2, KSBA_KEYUSAGE_KEY_ENCIPHERMENT = 4, KSBA_KEYUSAGE_DATA_ENCIPHERMENT = 8,
  KSBA_KEYUSAGE_KEY_AGREEMENT = 16, KSBA_KEYUSAGE_KEY_CERT_SIGN = 32, KSBA_KEYUSAGE_CRL_SIGN = 64, KSBA_KEYUSAGE_ENCIPHER_ONLY = 128,
  KSBA_KEYUSAGE_DECIPHER_ONLY = 256
}
 

Functions

gpg_error_t ksba_cert_new (ksba_cert_t *acert)
 
void ksba_cert_ref (ksba_cert_t cert)
 
void ksba_cert_release (ksba_cert_t cert)
 
gpg_error_t ksba_cert_set_user_data (ksba_cert_t cert, const char *key, const void *data, size_t datalen)
 
gpg_error_t ksba_cert_get_user_data (ksba_cert_t cert, const char *key, void *buffer, size_t bufferlen, size_t *datalen)
 
gpg_error_t ksba_cert_read_der (ksba_cert_t cert, ksba_reader_t reader)
 
gpg_error_t ksba_cert_init_from_mem (ksba_cert_t cert, const void *buffer, size_t length)
 
const unsigned char * ksba_cert_get_image (ksba_cert_t cert, size_t *r_length)
 
gpg_error_t ksba_cert_hash (ksba_cert_t cert, int what, void(*hasher)(void *, const void *, size_t length), void *hasher_arg)
 
const char * ksba_cert_get_digest_algo (ksba_cert_t cert)
 
ksba_sexp_t ksba_cert_get_serial (ksba_cert_t cert)
 
char * ksba_cert_get_issuer (ksba_cert_t cert, int idx)
 
gpg_error_t ksba_cert_get_validity (ksba_cert_t cert, int what, ksba_isotime_t r_time)
 
char * ksba_cert_get_subject (ksba_cert_t cert, int idx)
 
ksba_sexp_t ksba_cert_get_public_key (ksba_cert_t cert)
 
ksba_sexp_t ksba_cert_get_sig_val (ksba_cert_t cert)
 
gpg_error_t ksba_cert_get_extension (ksba_cert_t cert, int idx, char const **r_oid, int *r_crit, size_t *r_deroff, size_t *r_derlen)
 
gpg_error_t ksba_cert_is_ca (ksba_cert_t cert, int *r_ca, int *r_pathlen)
 
gpg_error_t ksba_cert_get_key_usage (ksba_cert_t cert, unsigned int *r_flags)
 
gpg_error_t ksba_cert_get_cert_policies (ksba_cert_t cert, char **r_policies)
 
gpg_error_t ksba_cert_get_ext_key_usages (ksba_cert_t cert, char **result)
 
gpg_error_t ksba_cert_get_crl_dist_point (ksba_cert_t cert, int idx, ksba_name_t *r_distpoint, ksba_name_t *r_issuer, ksba_crl_reason_t *r_reason)
 
gpg_error_t ksba_cert_get_auth_key_id (ksba_cert_t cert, ksba_sexp_t *r_keyid, ksba_name_t *r_name, ksba_sexp_t *r_serial)
 
gpg_error_t ksba_cert_get_subj_key_id (ksba_cert_t cert, int *r_crit, ksba_sexp_t *r_keyid)
 
gpg_error_t ksba_cert_get_authority_info_access (ksba_cert_t cert, int idx, char **r_method, ksba_name_t *r_location)
 
gpg_error_t ksba_cert_get_subject_info_access (ksba_cert_t cert, int idx, char **r_method, ksba_name_t *r_location)
 
ksba_content_type_t ksba_cms_identify (ksba_reader_t reader)
 
gpg_error_t ksba_cms_new (ksba_cms_t *r_cms)
 
void ksba_cms_release (ksba_cms_t cms)
 
gpg_error_t ksba_cms_set_reader_writer (ksba_cms_t cms, ksba_reader_t r, ksba_writer_t w)
 
gpg_error_t ksba_cms_parse (ksba_cms_t cms, ksba_stop_reason_t *r_stopreason)
 
gpg_error_t ksba_cms_build (ksba_cms_t cms, ksba_stop_reason_t *r_stopreason)
 
ksba_content_type_t ksba_cms_get_content_type (ksba_cms_t cms, int what)
 
const char * ksba_cms_get_content_oid (ksba_cms_t cms, int what)
 
gpg_error_t ksba_cms_get_content_enc_iv (ksba_cms_t cms, void *iv, size_t maxivlen, size_t *ivlen)
 
const char * ksba_cms_get_digest_algo_list (ksba_cms_t cms, int idx)
 
gpg_error_t ksba_cms_get_issuer_serial (ksba_cms_t cms, int idx, char **r_issuer, ksba_sexp_t *r_serial)
 
const char * ksba_cms_get_digest_algo (ksba_cms_t cms, int idx)
 
ksba_cert_t ksba_cms_get_cert (ksba_cms_t cms, int idx)
 
gpg_error_t ksba_cms_get_message_digest (ksba_cms_t cms, int idx, char **r_digest, size_t *r_digest_len)
 
gpg_error_t ksba_cms_get_signing_time (ksba_cms_t cms, int idx, ksba_isotime_t r_sigtime)
 
gpg_error_t ksba_cms_get_sigattr_oids (ksba_cms_t cms, int idx, const char *reqoid, char **r_value)
 
ksba_sexp_t ksba_cms_get_sig_val (ksba_cms_t cms, int idx)
 
ksba_sexp_t ksba_cms_get_enc_val (ksba_cms_t cms, int idx)
 
void ksba_cms_set_hash_function (ksba_cms_t cms, void(*hash_fnc)(void *, const void *, size_t), void *hash_fnc_arg)
 
gpg_error_t ksba_cms_hash_signed_attrs (ksba_cms_t cms, int idx)
 
gpg_error_t ksba_cms_set_content_type (ksba_cms_t cms, int what, ksba_content_type_t type)
 
gpg_error_t ksba_cms_add_digest_algo (ksba_cms_t cms, const char *oid)
 
gpg_error_t ksba_cms_add_signer (ksba_cms_t cms, ksba_cert_t cert)
 
gpg_error_t ksba_cms_add_cert (ksba_cms_t cms, ksba_cert_t cert)
 
gpg_error_t ksba_cms_add_smime_capability (ksba_cms_t cms, const char *oid, const unsigned char *der, size_t derlen)
 
gpg_error_t ksba_cms_set_message_digest (ksba_cms_t cms, int idx, const unsigned char *digest, size_t digest_len)
 
gpg_error_t ksba_cms_set_signing_time (ksba_cms_t cms, int idx, const ksba_isotime_t sigtime)
 
gpg_error_t ksba_cms_set_sig_val (ksba_cms_t cms, int idx, ksba_const_sexp_t sigval)
 
gpg_error_t ksba_cms_set_content_enc_algo (ksba_cms_t cms, const char *oid, const void *iv, size_t ivlen)
 
gpg_error_t ksba_cms_add_recipient (ksba_cms_t cms, ksba_cert_t cert)
 
gpg_error_t ksba_cms_set_enc_val (ksba_cms_t cms, int idx, ksba_const_sexp_t encval)
 
gpg_error_t ksba_crl_new (ksba_crl_t *r_crl)
 
void ksba_crl_release (ksba_crl_t crl)
 
gpg_error_t ksba_crl_set_reader (ksba_crl_t crl, ksba_reader_t r)
 
void ksba_crl_set_hash_function (ksba_crl_t crl, void(*hash_fnc)(void *, const void *, size_t), void *hash_fnc_arg)
 
const char * ksba_crl_get_digest_algo (ksba_crl_t crl)
 
gpg_error_t ksba_crl_get_issuer (ksba_crl_t crl, char **r_issuer)
 
gpg_error_t ksba_crl_get_extension (ksba_crl_t crl, int idx, char const **oid, int *critical, unsigned char const **der, size_t *derlen)
 
gpg_error_t ksba_crl_get_auth_key_id (ksba_crl_t crl, ksba_sexp_t *r_keyid, ksba_name_t *r_name, ksba_sexp_t *r_serial)
 
gpg_error_t ksba_crl_get_crl_number (ksba_crl_t crl, ksba_sexp_t *number)
 
gpg_error_t ksba_crl_get_update_times (ksba_crl_t crl, ksba_isotime_t this_update, ksba_isotime_t next_update)
 
gpg_error_t ksba_crl_get_item (ksba_crl_t crl, ksba_sexp_t *r_serial, ksba_isotime_t r_revocation_date, ksba_crl_reason_t *r_reason)
 
ksba_sexp_t ksba_crl_get_sig_val (ksba_crl_t crl)
 
gpg_error_t ksba_crl_parse (ksba_crl_t crl, ksba_stop_reason_t *r_stopreason)
 
gpg_error_t ksba_ocsp_new (ksba_ocsp_t *r_oscp)
 
void ksba_ocsp_release (ksba_ocsp_t ocsp)
 
gpg_error_t ksba_ocsp_set_digest_algo (ksba_ocsp_t ocsp, const char *oid)
 
gpg_error_t ksba_ocsp_set_requestor (ksba_ocsp_t ocsp, ksba_cert_t cert)
 
gpg_error_t ksba_ocsp_add_target (ksba_ocsp_t ocsp, ksba_cert_t cert, ksba_cert_t issuer_cert)
 
size_t ksba_ocsp_set_nonce (ksba_ocsp_t ocsp, unsigned char *nonce, size_t noncelen)
 
gpg_error_t ksba_ocsp_prepare_request (ksba_ocsp_t ocsp)
 
gpg_error_t ksba_ocsp_hash_request (ksba_ocsp_t ocsp, void(*hasher)(void *, const void *, size_t length), void *hasher_arg)
 
gpg_error_t ksba_ocsp_set_sig_val (ksba_ocsp_t ocsp, ksba_const_sexp_t sigval)
 
gpg_error_t ksba_ocsp_add_cert (ksba_ocsp_t ocsp, ksba_cert_t cert)
 
gpg_error_t ksba_ocsp_build_request (ksba_ocsp_t ocsp, unsigned char **r_buffer, size_t *r_buflen)
 
gpg_error_t ksba_ocsp_parse_response (ksba_ocsp_t ocsp, const unsigned char *msg, size_t msglen, ksba_ocsp_response_status_t *resp_status)
 
const char * ksba_ocsp_get_digest_algo (ksba_ocsp_t ocsp)
 
gpg_error_t ksba_ocsp_hash_response (ksba_ocsp_t ocsp, const unsigned char *msg, size_t msglen, void(*hasher)(void *, const void *, size_t length), void *hasher_arg)
 
ksba_sexp_t ksba_ocsp_get_sig_val (ksba_ocsp_t ocsp, ksba_isotime_t produced_at)
 
gpg_error_t ksba_ocsp_get_responder_id (ksba_ocsp_t ocsp, char **r_name, ksba_sexp_t *r_keyid)
 
ksba_cert_t ksba_ocsp_get_cert (ksba_ocsp_t ocsp, int idx)
 
gpg_error_t ksba_ocsp_get_status (ksba_ocsp_t ocsp, ksba_cert_t cert, ksba_status_t *r_status, ksba_isotime_t r_this_update, ksba_isotime_t r_next_update, ksba_isotime_t r_revocation_time, ksba_crl_reason_t *r_reason)
 
gpg_error_t ksba_ocsp_get_extension (ksba_ocsp_t ocsp, ksba_cert_t cert, int idx, char const **r_oid, int *r_crit, unsigned char const **r_der, size_t *r_derlen)
 
gpg_error_t ksba_certreq_new (ksba_certreq_t *r_cr)
 
void ksba_certreq_release (ksba_certreq_t cr)
 
gpg_error_t ksba_certreq_set_writer (ksba_certreq_t cr, ksba_writer_t w)
 
void ksba_certreq_set_hash_function (ksba_certreq_t cr, void(*hash_fnc)(void *, const void *, size_t), void *hash_fnc_arg)
 
gpg_error_t ksba_certreq_add_subject (ksba_certreq_t cr, const char *name)
 
gpg_error_t ksba_certreq_set_public_key (ksba_certreq_t cr, ksba_const_sexp_t key)
 
gpg_error_t ksba_certreq_add_extension (ksba_certreq_t cr, const char *oid, int is_crit, const void *der, size_t derlen)
 
gpg_error_t ksba_certreq_set_sig_val (ksba_certreq_t cr, ksba_const_sexp_t sigval)
 
gpg_error_t ksba_certreq_build (ksba_certreq_t cr, ksba_stop_reason_t *r_stopreason)
 
gpg_error_t ksba_certreq_set_serial (ksba_certreq_t cr, ksba_const_sexp_t sn)
 
gpg_error_t ksba_certreq_set_issuer (ksba_certreq_t cr, const char *name)
 
gpg_error_t ksba_certreq_set_validity (ksba_certreq_t cr, int what, const ksba_isotime_t timebuf)
 
gpg_error_t ksba_certreq_set_siginfo (ksba_certreq_t cr, ksba_const_sexp_t siginfo)
 
gpg_error_t ksba_reader_new (ksba_reader_t *r_r)
 
void ksba_reader_release (ksba_reader_t r)
 
gpg_error_t ksba_reader_set_release_notify (ksba_reader_t r, void(*notify)(void *, ksba_reader_t), void *notify_value)
 
gpg_error_t ksba_reader_clear (ksba_reader_t r, unsigned char **buffer, size_t *buflen)
 
gpg_error_t ksba_reader_error (ksba_reader_t r)
 
gpg_error_t ksba_reader_set_mem (ksba_reader_t r, const void *buffer, size_t length)
 
gpg_error_t ksba_reader_set_fd (ksba_reader_t r, int fd)
 
gpg_error_t ksba_reader_set_file (ksba_reader_t r, FILE *fp)
 
gpg_error_t ksba_reader_set_cb (ksba_reader_t r, int(*cb)(void *, char *, size_t, size_t *), void *cb_value)
 
gpg_error_t ksba_reader_read (ksba_reader_t r, char *buffer, size_t length, size_t *nread)
 
gpg_error_t ksba_reader_unread (ksba_reader_t r, const void *buffer, size_t count)
 
unsigned long ksba_reader_tell (ksba_reader_t r)
 
gpg_error_t ksba_writer_new (ksba_writer_t *r_w)
 
void ksba_writer_release (ksba_writer_t w)
 
gpg_error_t ksba_writer_set_release_notify (ksba_writer_t w, void(*notify)(void *, ksba_writer_t), void *notify_value)
 
int ksba_writer_error (ksba_writer_t w)
 
unsigned long ksba_writer_tell (ksba_writer_t w)
 
gpg_error_t ksba_writer_set_fd (ksba_writer_t w, int fd)
 
gpg_error_t ksba_writer_set_file (ksba_writer_t w, FILE *fp)
 
gpg_error_t ksba_writer_set_cb (ksba_writer_t w, int(*cb)(void *, const void *, size_t), void *cb_value)
 
gpg_error_t ksba_writer_set_mem (ksba_writer_t w, size_t initial_size)
 
const void * ksba_writer_get_mem (ksba_writer_t w, size_t *nbytes)
 
void * ksba_writer_snatch_mem (ksba_writer_t w, size_t *nbytes)
 
gpg_error_t ksba_writer_set_filter (ksba_writer_t w, gpg_error_t(*filter)(void *, const void *, size_t, size_t *, void *, size_t, size_t *), void *filter_arg)
 
gpg_error_t ksba_writer_write (ksba_writer_t w, const void *buffer, size_t length)
 
gpg_error_t ksba_writer_write_octet_string (ksba_writer_t w, const void *buffer, size_t length, int flush)
 
int ksba_asn_parse_file (const char *filename, ksba_asn_tree_t *result, int debug)
 
void ksba_asn_tree_release (ksba_asn_tree_t tree)
 
void ksba_asn_tree_dump (ksba_asn_tree_t tree, const char *name, FILE *fp)
 
gpg_error_t ksba_asn_create_tree (const char *mod_name, ksba_asn_tree_t *result)
 
char * ksba_oid_to_str (const char *buffer, size_t length)
 
gpg_error_t ksba_oid_from_str (const char *string, unsigned char **rbuf, size_t *rlength)
 
gpg_error_t ksba_dn_der2str (const void *der, size_t derlen, char **r_string)
 
gpg_error_t ksba_dn_str2der (const char *string, unsigned char **rder, size_t *rderlen)
 
gpg_error_t ksba_dn_teststr (const char *string, int seq, size_t *rerroff, size_t *rerrlen)
 
gpg_error_t ksba_name_new (ksba_name_t *r_name)
 
void ksba_name_ref (ksba_name_t name)
 
void ksba_name_release (ksba_name_t name)
 
const char * ksba_name_enum (ksba_name_t name, int idx)
 
char * ksba_name_get_uri (ksba_name_t name, int idx)
 
void ksba_der_release (ksba_der_t d)
 
ksba_der_t ksba_der_builder_new (unsigned int nitems)
 
void ksba_der_builder_reset (ksba_der_t d)
 
void ksba_der_add_ptr (ksba_der_t d, int cls, int tag, void *value, size_t valuelen)
 
void ksba_der_add_val (ksba_der_t d, int cls, int tag, const void *value, size_t valuelen)
 
void ksba_der_add_int (ksba_der_t d, const void *value, size_t valuelen, int force_positive)
 
void ksba_der_add_oid (ksba_der_t d, const char *oidstr)
 
void ksba_der_add_bts (ksba_der_t d, const void *value, size_t valuelen, unsigned int unusedbits)
 
void ksba_der_add_der (ksba_der_t d, const void *der, size_t derlen)
 
void ksba_der_add_tag (ksba_der_t d, int cls, int tag)
 
void ksba_der_add_end (ksba_der_t d)
 
gpg_error_t ksba_der_builder_get (ksba_der_t d, unsigned char **r_obj, size_t *r_objlen)
 
void ksba_set_malloc_hooks (void *(*new_alloc_func)(size_t n), void *(*new_realloc_func)(void *p, size_t n), void(*new_free_func)(void *))
 
void ksba_set_hash_buffer_function (gpg_error_t(*fnc)(void *arg, const char *oid, const void *buffer, size_t length, size_t resultsize, unsigned char *result, size_t *resultlen), void *fnc_arg)
 
void * ksba_malloc (size_t n)
 
void * ksba_calloc (size_t n, size_t m)
 
void * ksba_realloc (void *p, size_t n)
 
char * ksba_strdup (const char *p)
 
void ksba_free (void *a)
 
const char * ksba_check_version (const char *req_version)
 

Macro Definition Documentation

◆ _KSBA_DEPRECATED

#define _KSBA_DEPRECATED

Definition at line 68 of file ksba.h.

◆ KSBA_CLASS_APPLICATION

#define KSBA_CLASS_APPLICATION   1

Definition at line 73 of file ksba.h.

◆ KSBA_CLASS_CONTEXT

#define KSBA_CLASS_CONTEXT   2

Definition at line 74 of file ksba.h.

◆ KSBA_CLASS_ENCAPSULATE

#define KSBA_CLASS_ENCAPSULATE   0x80 /* Pseudo class. */

Definition at line 76 of file ksba.h.

◆ KSBA_CLASS_PRIVATE

#define KSBA_CLASS_PRIVATE   3

Definition at line 75 of file ksba.h.

◆ KSBA_CLASS_UNIVERSAL

#define KSBA_CLASS_UNIVERSAL   0

Definition at line 72 of file ksba.h.

◆ KSBA_TYPE_BIT_STRING

#define KSBA_TYPE_BIT_STRING   3

Definition at line 80 of file ksba.h.

◆ KSBA_TYPE_BMP_STRING

#define KSBA_TYPE_BMP_STRING   30

Definition at line 106 of file ksba.h.

◆ KSBA_TYPE_BOOLEAN

#define KSBA_TYPE_BOOLEAN   1

Definition at line 78 of file ksba.h.

◆ KSBA_TYPE_CHARACTER_STRING

#define KSBA_TYPE_CHARACTER_STRING   29

Definition at line 105 of file ksba.h.

◆ KSBA_TYPE_DATE

#define KSBA_TYPE_DATE   31

Definition at line 107 of file ksba.h.

◆ KSBA_TYPE_DATE_TIME

#define KSBA_TYPE_DATE_TIME   33

Definition at line 109 of file ksba.h.

◆ KSBA_TYPE_DURATION

#define KSBA_TYPE_DURATION   34

Definition at line 110 of file ksba.h.

◆ KSBA_TYPE_EMBEDDED_PDV

#define KSBA_TYPE_EMBEDDED_PDV   11

Definition at line 88 of file ksba.h.

◆ KSBA_TYPE_ENUMERATED

#define KSBA_TYPE_ENUMERATED   10

Definition at line 87 of file ksba.h.

◆ KSBA_TYPE_EXTERNAL

#define KSBA_TYPE_EXTERNAL   8

Definition at line 85 of file ksba.h.

◆ KSBA_TYPE_GENERAL_STRING

#define KSBA_TYPE_GENERAL_STRING   27

Definition at line 103 of file ksba.h.

◆ KSBA_TYPE_GENERALIZED_TIME

#define KSBA_TYPE_GENERALIZED_TIME   24

Definition at line 100 of file ksba.h.

◆ KSBA_TYPE_GRAPHIC_STRING

#define KSBA_TYPE_GRAPHIC_STRING   25

Definition at line 101 of file ksba.h.

◆ KSBA_TYPE_IA5_STRING

#define KSBA_TYPE_IA5_STRING   22

Definition at line 98 of file ksba.h.

◆ KSBA_TYPE_INTEGER

#define KSBA_TYPE_INTEGER   2

Definition at line 79 of file ksba.h.

◆ KSBA_TYPE_NULL

#define KSBA_TYPE_NULL   5

Definition at line 82 of file ksba.h.

◆ KSBA_TYPE_NUMERIC_STRING

#define KSBA_TYPE_NUMERIC_STRING   18

Definition at line 94 of file ksba.h.

◆ KSBA_TYPE_OBJECT_DESCRIPTOR

#define KSBA_TYPE_OBJECT_DESCRIPTOR   7

Definition at line 84 of file ksba.h.

◆ KSBA_TYPE_OBJECT_ID

#define KSBA_TYPE_OBJECT_ID   6

Definition at line 83 of file ksba.h.

◆ KSBA_TYPE_OCTET_STRING

#define KSBA_TYPE_OCTET_STRING   4

Definition at line 81 of file ksba.h.

◆ KSBA_TYPE_OID_IRI

#define KSBA_TYPE_OID_IRI   35

Definition at line 111 of file ksba.h.

◆ KSBA_TYPE_PRINTABLE_STRING

#define KSBA_TYPE_PRINTABLE_STRING   19

Definition at line 95 of file ksba.h.

◆ KSBA_TYPE_REAL

#define KSBA_TYPE_REAL   9

Definition at line 86 of file ksba.h.

◆ KSBA_TYPE_RELATIVE_OID

#define KSBA_TYPE_RELATIVE_OID   13

Definition at line 90 of file ksba.h.

◆ KSBA_TYPE_RELATIVE_OID_IRI

#define KSBA_TYPE_RELATIVE_OID_IRI   36

Definition at line 112 of file ksba.h.

◆ KSBA_TYPE_SEQUENCE

#define KSBA_TYPE_SEQUENCE   16

Definition at line 92 of file ksba.h.

◆ KSBA_TYPE_SET

#define KSBA_TYPE_SET   17

Definition at line 93 of file ksba.h.

◆ KSBA_TYPE_TELETEX_STRING

#define KSBA_TYPE_TELETEX_STRING   20

Definition at line 96 of file ksba.h.

◆ KSBA_TYPE_TIME

#define KSBA_TYPE_TIME   14

Definition at line 91 of file ksba.h.

◆ KSBA_TYPE_TIME_OF_DAY

#define KSBA_TYPE_TIME_OF_DAY   32

Definition at line 108 of file ksba.h.

◆ KSBA_TYPE_UNIVERSAL_STRING

#define KSBA_TYPE_UNIVERSAL_STRING   28

Definition at line 104 of file ksba.h.

◆ KSBA_TYPE_UTC_TIME

#define KSBA_TYPE_UTC_TIME   23

Definition at line 99 of file ksba.h.

◆ KSBA_TYPE_UTF8_STRING

#define KSBA_TYPE_UTF8_STRING   12

Definition at line 89 of file ksba.h.

◆ KSBA_TYPE_VIDEOTEX_STRING

#define KSBA_TYPE_VIDEOTEX_STRING   21

Definition at line 97 of file ksba.h.

◆ KSBA_TYPE_VISIBLE_STRING

#define KSBA_TYPE_VISIBLE_STRING   26

Definition at line 102 of file ksba.h.

◆ KSBA_VERSION

#define KSBA_VERSION   "1.5.0"

Definition at line 49 of file ksba.h.

◆ KSBA_VERSION_NUMBER

#define KSBA_VERSION_NUMBER   0x010500

Definition at line 53 of file ksba.h.

Typedef Documentation

◆ ksba_asn_tree_t

Definition at line 258 of file ksba.h.

◆ ksba_cert_t

typedef struct ksba_cert_s* ksba_cert_t

Definition at line 217 of file ksba.h.

◆ ksba_certreq_t

typedef struct ksba_certreq_s* ksba_certreq_t

Definition at line 240 of file ksba.h.

◆ ksba_cms_t

typedef struct ksba_cms_s* ksba_cms_t

Definition at line 223 of file ksba.h.

◆ ksba_const_sexp_t

typedef const unsigned char* ksba_const_sexp_t

Definition at line 274 of file ksba.h.

◆ ksba_crl_t

typedef struct ksba_crl_s* ksba_crl_t

Definition at line 229 of file ksba.h.

◆ ksba_der_t

typedef struct ksba_der_s* ksba_der_t

Definition at line 280 of file ksba.h.

◆ ksba_isotime_t

typedef char ksba_isotime_t[16]

Definition at line 211 of file ksba.h.

◆ ksba_name_t

typedef struct ksba_name_s* ksba_name_t

Definition at line 264 of file ksba.h.

◆ ksba_ocsp_t

typedef struct ksba_ocsp_s* ksba_ocsp_t

Definition at line 235 of file ksba.h.

◆ ksba_reader_t

typedef struct ksba_reader_s* ksba_reader_t

Definition at line 246 of file ksba.h.

◆ ksba_sexp_t

typedef unsigned char* ksba_sexp_t

Definition at line 272 of file ksba.h.

◆ ksba_writer_t

typedef struct ksba_writer_s* ksba_writer_t

Definition at line 252 of file ksba.h.

◆ KsbaAsnTree

typedef struct ksba_asn_tree_s* KsbaAsnTree

Definition at line 259 of file ksba.h.

◆ KsbaCert

typedef struct ksba_cert_s* KsbaCert

Definition at line 218 of file ksba.h.

◆ KsbaCertreq

typedef struct ksba_certreq_s* KsbaCertreq

Definition at line 241 of file ksba.h.

◆ KsbaCMS

typedef struct ksba_cms_s* KsbaCMS

Definition at line 224 of file ksba.h.

◆ KsbaConstSexp

typedef const unsigned char* KsbaConstSexp

Definition at line 275 of file ksba.h.

◆ KsbaContentType

Definition at line 132 of file ksba.h.

◆ KsbaCRL

typedef struct ksba_crl_s* KsbaCRL

Definition at line 230 of file ksba.h.

◆ KsbaCRLReason

Definition at line 169 of file ksba.h.

◆ KsbaError

typedef gpg_error_t KsbaError

Definition at line 116 of file ksba.h.

◆ KsbaKeyUsage

Definition at line 208 of file ksba.h.

◆ KsbaName

typedef struct ksba_name_s* KsbaName

Definition at line 265 of file ksba.h.

◆ KsbaReader

typedef struct ksba_reader_s* KsbaReader

Definition at line 247 of file ksba.h.

◆ KsbaSexp

typedef unsigned char* KsbaSexp

Definition at line 273 of file ksba.h.

◆ KsbaStopReason

Definition at line 152 of file ksba.h.

◆ KsbaWriter

typedef struct ksba_writer_s* KsbaWriter

Definition at line 253 of file ksba.h.

Enumeration Type Documentation

◆ ksba_content_type_t

Enumerator
KSBA_CT_NONE 
KSBA_CT_DATA 
KSBA_CT_SIGNED_DATA 
KSBA_CT_ENVELOPED_DATA 
KSBA_CT_DIGESTED_DATA 
KSBA_CT_ENCRYPTED_DATA 
KSBA_CT_AUTH_DATA 
KSBA_CT_PKCS12 
KSBA_CT_SPC_IND_DATA_CTX 
KSBA_CT_OPENPGP_KEYBLOCK 

Definition at line 118 of file ksba.h.

◆ ksba_crl_reason_t

Enumerator
KSBA_CRLREASON_UNSPECIFIED 
KSBA_CRLREASON_KEY_COMPROMISE 
KSBA_CRLREASON_CA_COMPROMISE 
KSBA_CRLREASON_AFFILIATION_CHANGED 
KSBA_CRLREASON_SUPERSEDED 
KSBA_CRLREASON_CESSATION_OF_OPERATION 
KSBA_CRLREASON_CERTIFICATE_HOLD 
KSBA_CRLREASON_REMOVE_FROM_CRL 
KSBA_CRLREASON_PRIVILEGE_WITHDRAWN 
KSBA_CRLREASON_AA_COMPROMISE 
KSBA_CRLREASON_OTHER 

Definition at line 154 of file ksba.h.

◆ ksba_key_usage_t

Enumerator
KSBA_KEYUSAGE_DIGITAL_SIGNATURE 
KSBA_KEYUSAGE_NON_REPUDIATION 
KSBA_KEYUSAGE_KEY_ENCIPHERMENT 
KSBA_KEYUSAGE_DATA_ENCIPHERMENT 
KSBA_KEYUSAGE_KEY_AGREEMENT 
KSBA_KEYUSAGE_KEY_CERT_SIGN 
KSBA_KEYUSAGE_CRL_SIGN 
KSBA_KEYUSAGE_ENCIPHER_ONLY 
KSBA_KEYUSAGE_DECIPHER_ONLY 

Definition at line 195 of file ksba.h.

◆ ksba_ocsp_response_status_t

Enumerator
KSBA_OCSP_RSPSTATUS_SUCCESS 
KSBA_OCSP_RSPSTATUS_MALFORMED 
KSBA_OCSP_RSPSTATUS_INTERNAL 
KSBA_OCSP_RSPSTATUS_TRYLATER 
KSBA_OCSP_RSPSTATUS_SIGREQUIRED 
KSBA_OCSP_RSPSTATUS_UNAUTHORIZED 
KSBA_OCSP_RSPSTATUS_REPLAYED 
KSBA_OCSP_RSPSTATUS_OTHER 
KSBA_OCSP_RSPSTATUS_NONE 

Definition at line 171 of file ksba.h.

◆ ksba_status_t

Enumerator
KSBA_STATUS_NONE 
KSBA_STATUS_UNKNOWN 
KSBA_STATUS_GOOD 
KSBA_STATUS_REVOKED 

Definition at line 185 of file ksba.h.

◆ ksba_stop_reason_t

Enumerator
KSBA_SR_NONE 
KSBA_SR_RUNNING 
KSBA_SR_GOT_CONTENT 
KSBA_SR_NEED_HASH 
KSBA_SR_BEGIN_DATA 
KSBA_SR_END_DATA 
KSBA_SR_READY 
KSBA_SR_NEED_SIG 
KSBA_SR_DETACHED_DATA 
KSBA_SR_BEGIN_ITEMS 
KSBA_SR_GOT_ITEM 
KSBA_SR_END_ITEMS 

Definition at line 136 of file ksba.h.

Function Documentation

◆ ksba_asn_create_tree()

gpg_error_t ksba_asn_create_tree ( const char *  mod_name,
ksba_asn_tree_t result 
)

◆ ksba_asn_parse_file()

int ksba_asn_parse_file ( const char *  filename,
ksba_asn_tree_t result,
int  debug 
)

◆ ksba_asn_tree_dump()

void ksba_asn_tree_dump ( ksba_asn_tree_t  tree,
const char *  name,
FILE *  fp 
)

◆ ksba_asn_tree_release()

◆ ksba_calloc()

void* ksba_calloc ( size_t  n,
size_t  m 
)

Referenced by _ksba_xcalloc().

◆ ksba_cert_get_auth_key_id()

gpg_error_t ksba_cert_get_auth_key_id ( ksba_cert_t  cert,
ksba_sexp_t r_keyid,
ksba_name_t r_name,
ksba_sexp_t r_serial 
)

◆ ksba_cert_get_authority_info_access()

gpg_error_t ksba_cert_get_authority_info_access ( ksba_cert_t  cert,
int  idx,
char **  r_method,
ksba_name_t r_location 
)

◆ ksba_cert_get_cert_policies()

gpg_error_t ksba_cert_get_cert_policies ( ksba_cert_t  cert,
char **  r_policies 
)

◆ ksba_cert_get_crl_dist_point()

gpg_error_t ksba_cert_get_crl_dist_point ( ksba_cert_t  cert,
int  idx,
ksba_name_t r_distpoint,
ksba_name_t r_issuer,
ksba_crl_reason_t r_reason 
)

◆ ksba_cert_get_digest_algo()

const char* ksba_cert_get_digest_algo ( ksba_cert_t  cert)

◆ ksba_cert_get_ext_key_usages()

gpg_error_t ksba_cert_get_ext_key_usages ( ksba_cert_t  cert,
char **  result 
)

◆ ksba_cert_get_extension()

gpg_error_t ksba_cert_get_extension ( ksba_cert_t  cert,
int  idx,
char const **  r_oid,
int *  r_crit,
size_t *  r_deroff,
size_t *  r_derlen 
)

◆ ksba_cert_get_image()

const unsigned char* ksba_cert_get_image ( ksba_cert_t  cert,
size_t *  r_length 
)

◆ ksba_cert_get_issuer()

char* ksba_cert_get_issuer ( ksba_cert_t  cert,
int  idx 
)

◆ ksba_cert_get_key_usage()

gpg_error_t ksba_cert_get_key_usage ( ksba_cert_t  cert,
unsigned int *  r_flags 
)

◆ ksba_cert_get_public_key()

ksba_sexp_t ksba_cert_get_public_key ( ksba_cert_t  cert)

◆ ksba_cert_get_serial()

ksba_sexp_t ksba_cert_get_serial ( ksba_cert_t  cert)

◆ ksba_cert_get_sig_val()

ksba_sexp_t ksba_cert_get_sig_val ( ksba_cert_t  cert)

◆ ksba_cert_get_subj_key_id()

gpg_error_t ksba_cert_get_subj_key_id ( ksba_cert_t  cert,
int *  r_crit,
ksba_sexp_t r_keyid 
)

◆ ksba_cert_get_subject()

char* ksba_cert_get_subject ( ksba_cert_t  cert,
int  idx 
)

◆ ksba_cert_get_subject_info_access()

gpg_error_t ksba_cert_get_subject_info_access ( ksba_cert_t  cert,
int  idx,
char **  r_method,
ksba_name_t r_location 
)

◆ ksba_cert_get_user_data()

gpg_error_t ksba_cert_get_user_data ( ksba_cert_t  cert,
const char *  key,
void *  buffer,
size_t  bufferlen,
size_t *  datalen 
)

◆ ksba_cert_get_validity()

gpg_error_t ksba_cert_get_validity ( ksba_cert_t  cert,
int  what,
ksba_isotime_t  r_time 
)

◆ ksba_cert_hash()

gpg_error_t ksba_cert_hash ( ksba_cert_t  cert,
int  what,
void(*)(void *, const void *, size_t length)  hasher,
void *  hasher_arg 
)

◆ ksba_cert_init_from_mem()

gpg_error_t ksba_cert_init_from_mem ( ksba_cert_t  cert,
const void *  buffer,
size_t  length 
)

Referenced by parse_response().

◆ ksba_cert_is_ca()

gpg_error_t ksba_cert_is_ca ( ksba_cert_t  cert,
int *  r_ca,
int *  r_pathlen 
)

◆ ksba_cert_new()

gpg_error_t ksba_cert_new ( ksba_cert_t acert)

◆ ksba_cert_read_der()

gpg_error_t ksba_cert_read_der ( ksba_cert_t  cert,
ksba_reader_t  reader 
)

◆ ksba_cert_ref()

◆ ksba_cert_release()

◆ ksba_cert_set_user_data()

gpg_error_t ksba_cert_set_user_data ( ksba_cert_t  cert,
const char *  key,
const void *  data,
size_t  datalen 
)

◆ ksba_certreq_add_extension()

gpg_error_t ksba_certreq_add_extension ( ksba_certreq_t  cr,
const char *  oid,
int  is_crit,
const void *  der,
size_t  derlen 
)

◆ ksba_certreq_add_subject()

gpg_error_t ksba_certreq_add_subject ( ksba_certreq_t  cr,
const char *  name 
)

◆ ksba_certreq_build()

gpg_error_t ksba_certreq_build ( ksba_certreq_t  cr,
ksba_stop_reason_t r_stopreason 
)

◆ ksba_certreq_new()

gpg_error_t ksba_certreq_new ( ksba_certreq_t r_cr)

◆ ksba_certreq_release()

void ksba_certreq_release ( ksba_certreq_t  cr)

◆ ksba_certreq_set_hash_function()

void ksba_certreq_set_hash_function ( ksba_certreq_t  cr,
void(*)(void *, const void *, size_t)  hash_fnc,
void *  hash_fnc_arg 
)

◆ ksba_certreq_set_issuer()

gpg_error_t ksba_certreq_set_issuer ( ksba_certreq_t  cr,
const char *  name 
)

◆ ksba_certreq_set_public_key()

gpg_error_t ksba_certreq_set_public_key ( ksba_certreq_t  cr,
ksba_const_sexp_t  key 
)

◆ ksba_certreq_set_serial()

gpg_error_t ksba_certreq_set_serial ( ksba_certreq_t  cr,
ksba_const_sexp_t  sn 
)

◆ ksba_certreq_set_sig_val()

gpg_error_t ksba_certreq_set_sig_val ( ksba_certreq_t  cr,
ksba_const_sexp_t  sigval 
)

◆ ksba_certreq_set_siginfo()

gpg_error_t ksba_certreq_set_siginfo ( ksba_certreq_t  cr,
ksba_const_sexp_t  siginfo 
)

◆ ksba_certreq_set_validity()

gpg_error_t ksba_certreq_set_validity ( ksba_certreq_t  cr,
int  what,
const ksba_isotime_t  timebuf 
)

◆ ksba_certreq_set_writer()

gpg_error_t ksba_certreq_set_writer ( ksba_certreq_t  cr,
ksba_writer_t  w 
)

◆ ksba_check_version()

const char* ksba_check_version ( const char *  req_version)

◆ ksba_cms_add_cert()

gpg_error_t ksba_cms_add_cert ( ksba_cms_t  cms,
ksba_cert_t  cert 
)

◆ ksba_cms_add_digest_algo()

gpg_error_t ksba_cms_add_digest_algo ( ksba_cms_t  cms,
const char *  oid 
)

◆ ksba_cms_add_recipient()

gpg_error_t ksba_cms_add_recipient ( ksba_cms_t  cms,
ksba_cert_t  cert 
)

◆ ksba_cms_add_signer()

gpg_error_t ksba_cms_add_signer ( ksba_cms_t  cms,
ksba_cert_t  cert 
)

Referenced by _ksba_cms_add_recipient().

◆ ksba_cms_add_smime_capability()

gpg_error_t ksba_cms_add_smime_capability ( ksba_cms_t  cms,
const char *  oid,
const unsigned char *  der,
size_t  derlen 
)

◆ ksba_cms_build()

gpg_error_t ksba_cms_build ( ksba_cms_t  cms,
ksba_stop_reason_t r_stopreason 
)

◆ ksba_cms_get_cert()

ksba_cert_t ksba_cms_get_cert ( ksba_cms_t  cms,
int  idx 
)

◆ ksba_cms_get_content_enc_iv()

gpg_error_t ksba_cms_get_content_enc_iv ( ksba_cms_t  cms,
void *  iv,
size_t  maxivlen,
size_t *  ivlen 
)

◆ ksba_cms_get_content_oid()

const char* ksba_cms_get_content_oid ( ksba_cms_t  cms,
int  what 
)

◆ ksba_cms_get_content_type()

ksba_content_type_t ksba_cms_get_content_type ( ksba_cms_t  cms,
int  what 
)

◆ ksba_cms_get_digest_algo()

const char* ksba_cms_get_digest_algo ( ksba_cms_t  cms,
int  idx 
)

◆ ksba_cms_get_digest_algo_list()

const char* ksba_cms_get_digest_algo_list ( ksba_cms_t  cms,
int  idx 
)

◆ ksba_cms_get_enc_val()

ksba_sexp_t ksba_cms_get_enc_val ( ksba_cms_t  cms,
int  idx 
)

◆ ksba_cms_get_issuer_serial()

gpg_error_t ksba_cms_get_issuer_serial ( ksba_cms_t  cms,
int  idx,
char **  r_issuer,
ksba_sexp_t r_serial 
)

◆ ksba_cms_get_message_digest()

gpg_error_t ksba_cms_get_message_digest ( ksba_cms_t  cms,
int  idx,
char **  r_digest,
size_t *  r_digest_len 
)

◆ ksba_cms_get_sig_val()

ksba_sexp_t ksba_cms_get_sig_val ( ksba_cms_t  cms,
int  idx 
)

◆ ksba_cms_get_sigattr_oids()

gpg_error_t ksba_cms_get_sigattr_oids ( ksba_cms_t  cms,
int  idx,
const char *  reqoid,
char **  r_value 
)

◆ ksba_cms_get_signing_time()

gpg_error_t ksba_cms_get_signing_time ( ksba_cms_t  cms,
int  idx,
ksba_isotime_t  r_sigtime 
)

◆ ksba_cms_hash_signed_attrs()

gpg_error_t ksba_cms_hash_signed_attrs ( ksba_cms_t  cms,
int  idx 
)

◆ ksba_cms_identify()

ksba_content_type_t ksba_cms_identify ( ksba_reader_t  reader)

◆ ksba_cms_new()

gpg_error_t ksba_cms_new ( ksba_cms_t r_cms)

◆ ksba_cms_parse()

gpg_error_t ksba_cms_parse ( ksba_cms_t  cms,
ksba_stop_reason_t r_stopreason 
)

◆ ksba_cms_release()

void ksba_cms_release ( ksba_cms_t  cms)

◆ ksba_cms_set_content_enc_algo()

gpg_error_t ksba_cms_set_content_enc_algo ( ksba_cms_t  cms,
const char *  oid,
const void *  iv,
size_t  ivlen 
)

◆ ksba_cms_set_content_type()

gpg_error_t ksba_cms_set_content_type ( ksba_cms_t  cms,
int  what,
ksba_content_type_t  type 
)

◆ ksba_cms_set_enc_val()

gpg_error_t ksba_cms_set_enc_val ( ksba_cms_t  cms,
int  idx,
ksba_const_sexp_t  encval 
)

◆ ksba_cms_set_hash_function()

void ksba_cms_set_hash_function ( ksba_cms_t  cms,
void(*)(void *, const void *, size_t)  hash_fnc,
void *  hash_fnc_arg 
)

◆ ksba_cms_set_message_digest()

gpg_error_t ksba_cms_set_message_digest ( ksba_cms_t  cms,
int  idx,
const unsigned char *  digest,
size_t  digest_len 
)

◆ ksba_cms_set_reader_writer()

gpg_error_t ksba_cms_set_reader_writer ( ksba_cms_t  cms,
ksba_reader_t  r,
ksba_writer_t  w 
)

◆ ksba_cms_set_sig_val()

gpg_error_t ksba_cms_set_sig_val ( ksba_cms_t  cms,
int  idx,
ksba_const_sexp_t  sigval 
)

◆ ksba_cms_set_signing_time()

gpg_error_t ksba_cms_set_signing_time ( ksba_cms_t  cms,
int  idx,
const ksba_isotime_t  sigtime 
)

◆ ksba_crl_get_auth_key_id()

gpg_error_t ksba_crl_get_auth_key_id ( ksba_crl_t  crl,
ksba_sexp_t r_keyid,
ksba_name_t r_name,
ksba_sexp_t r_serial 
)

◆ ksba_crl_get_crl_number()

gpg_error_t ksba_crl_get_crl_number ( ksba_crl_t  crl,
ksba_sexp_t number 
)

◆ ksba_crl_get_digest_algo()

const char* ksba_crl_get_digest_algo ( ksba_crl_t  crl)

◆ ksba_crl_get_extension()

gpg_error_t ksba_crl_get_extension ( ksba_crl_t  crl,
int  idx,
char const **  oid,
int *  critical,
unsigned char const **  der,
size_t *  derlen 
)

◆ ksba_crl_get_issuer()

gpg_error_t ksba_crl_get_issuer ( ksba_crl_t  crl,
char **  r_issuer 
)

◆ ksba_crl_get_item()

gpg_error_t ksba_crl_get_item ( ksba_crl_t  crl,
ksba_sexp_t r_serial,
ksba_isotime_t  r_revocation_date,
ksba_crl_reason_t r_reason 
)

◆ ksba_crl_get_sig_val()

ksba_sexp_t ksba_crl_get_sig_val ( ksba_crl_t  crl)

◆ ksba_crl_get_update_times()

gpg_error_t ksba_crl_get_update_times ( ksba_crl_t  crl,
ksba_isotime_t  this_update,
ksba_isotime_t  next_update 
)

◆ ksba_crl_new()

gpg_error_t ksba_crl_new ( ksba_crl_t r_crl)

◆ ksba_crl_parse()

gpg_error_t ksba_crl_parse ( ksba_crl_t  crl,
ksba_stop_reason_t r_stopreason 
)

◆ ksba_crl_release()

void ksba_crl_release ( ksba_crl_t  crl)

◆ ksba_crl_set_hash_function()

void ksba_crl_set_hash_function ( ksba_crl_t  crl,
void(*)(void *, const void *, size_t)  hash_fnc,
void *  hash_fnc_arg 
)

◆ ksba_crl_set_reader()

gpg_error_t ksba_crl_set_reader ( ksba_crl_t  crl,
ksba_reader_t  r 
)

◆ ksba_der_add_bts()

void ksba_der_add_bts ( ksba_der_t  d,
const void *  value,
size_t  valuelen,
unsigned int  unusedbits 
)

◆ ksba_der_add_der()

void ksba_der_add_der ( ksba_der_t  d,
const void *  der,
size_t  derlen 
)

◆ ksba_der_add_end()

void ksba_der_add_end ( ksba_der_t  d)

◆ ksba_der_add_int()

void ksba_der_add_int ( ksba_der_t  d,
const void *  value,
size_t  valuelen,
int  force_positive 
)

◆ ksba_der_add_oid()

void ksba_der_add_oid ( ksba_der_t  d,
const char *  oidstr 
)

◆ ksba_der_add_ptr()

void ksba_der_add_ptr ( ksba_der_t  d,
int  cls,
int  tag,
void *  value,
size_t  valuelen 
)

◆ ksba_der_add_tag()

void ksba_der_add_tag ( ksba_der_t  d,
int  cls,
int  tag 
)

◆ ksba_der_add_val()

void ksba_der_add_val ( ksba_der_t  d,
int  cls,
int  tag,
const void *  value,
size_t  valuelen 
)

◆ ksba_der_builder_get()

gpg_error_t ksba_der_builder_get ( ksba_der_t  d,
unsigned char **  r_obj,
size_t *  r_objlen 
)

◆ ksba_der_builder_new()

ksba_der_t ksba_der_builder_new ( unsigned int  nitems)

◆ ksba_der_builder_reset()

void ksba_der_builder_reset ( ksba_der_t  d)

◆ ksba_der_release()

void ksba_der_release ( ksba_der_t  d)

Referenced by sign_and_write().

◆ ksba_dn_der2str()

gpg_error_t ksba_dn_der2str ( const void *  der,
size_t  derlen,
char **  r_string 
)

◆ ksba_dn_str2der()

gpg_error_t ksba_dn_str2der ( const char *  string,
unsigned char **  rder,
size_t *  rderlen 
)

◆ ksba_dn_teststr()

gpg_error_t ksba_dn_teststr ( const char *  string,
int  seq,
size_t *  rerroff,
size_t *  rerrlen 
)

◆ ksba_free()

void ksba_free ( void *  a)

◆ ksba_malloc()

void* ksba_malloc ( size_t  n)

◆ ksba_name_enum()

const char* ksba_name_enum ( ksba_name_t  name,
int  idx 
)

Referenced by _ksba_name_get_uri().

◆ ksba_name_get_uri()

char* ksba_name_get_uri ( ksba_name_t  name,
int  idx 
)

◆ ksba_name_new()

gpg_error_t ksba_name_new ( ksba_name_t r_name)

Referenced by _ksba_name_new_from_der().

◆ ksba_name_ref()

void ksba_name_ref ( ksba_name_t  name)

◆ ksba_name_release()

void ksba_name_release ( ksba_name_t  name)

◆ ksba_ocsp_add_cert()

gpg_error_t ksba_ocsp_add_cert ( ksba_ocsp_t  ocsp,
ksba_cert_t  cert 
)

◆ ksba_ocsp_add_target()

gpg_error_t ksba_ocsp_add_target ( ksba_ocsp_t  ocsp,
ksba_cert_t  cert,
ksba_cert_t  issuer_cert 
)

◆ ksba_ocsp_build_request()

gpg_error_t ksba_ocsp_build_request ( ksba_ocsp_t  ocsp,
unsigned char **  r_buffer,
size_t *  r_buflen 
)

◆ ksba_ocsp_get_cert()

ksba_cert_t ksba_ocsp_get_cert ( ksba_ocsp_t  ocsp,
int  idx 
)

◆ ksba_ocsp_get_digest_algo()

const char* ksba_ocsp_get_digest_algo ( ksba_ocsp_t  ocsp)

◆ ksba_ocsp_get_extension()

gpg_error_t ksba_ocsp_get_extension ( ksba_ocsp_t  ocsp,
ksba_cert_t  cert,
int  idx,
char const **  r_oid,
int *  r_crit,
unsigned char const **  r_der,
size_t *  r_derlen 
)

◆ ksba_ocsp_get_responder_id()

gpg_error_t ksba_ocsp_get_responder_id ( ksba_ocsp_t  ocsp,
char **  r_name,
ksba_sexp_t r_keyid 
)

◆ ksba_ocsp_get_sig_val()

ksba_sexp_t ksba_ocsp_get_sig_val ( ksba_ocsp_t  ocsp,
ksba_isotime_t  produced_at 
)

◆ ksba_ocsp_get_status()

gpg_error_t ksba_ocsp_get_status ( ksba_ocsp_t  ocsp,
ksba_cert_t  cert,
ksba_status_t r_status,
ksba_isotime_t  r_this_update,
ksba_isotime_t  r_next_update,
ksba_isotime_t  r_revocation_time,
ksba_crl_reason_t r_reason 
)

◆ ksba_ocsp_hash_request()

gpg_error_t ksba_ocsp_hash_request ( ksba_ocsp_t  ocsp,
void(*)(void *, const void *, size_t length)  hasher,
void *  hasher_arg 
)

◆ ksba_ocsp_hash_response()

gpg_error_t ksba_ocsp_hash_response ( ksba_ocsp_t  ocsp,
const unsigned char *  msg,
size_t  msglen,
void(*)(void *, const void *, size_t length)  hasher,
void *  hasher_arg 
)

◆ ksba_ocsp_new()

gpg_error_t ksba_ocsp_new ( ksba_ocsp_t r_oscp)

◆ ksba_ocsp_parse_response()

gpg_error_t ksba_ocsp_parse_response ( ksba_ocsp_t  ocsp,
const unsigned char *  msg,
size_t  msglen,
ksba_ocsp_response_status_t resp_status 
)

◆ ksba_ocsp_prepare_request()

gpg_error_t ksba_ocsp_prepare_request ( ksba_ocsp_t  ocsp)

◆ ksba_ocsp_release()

void ksba_ocsp_release ( ksba_ocsp_t  ocsp)

◆ ksba_ocsp_set_digest_algo()

gpg_error_t ksba_ocsp_set_digest_algo ( ksba_ocsp_t  ocsp,
const char *  oid 
)

◆ ksba_ocsp_set_nonce()

size_t ksba_ocsp_set_nonce ( ksba_ocsp_t  ocsp,
unsigned char *  nonce,
size_t  noncelen 
)

◆ ksba_ocsp_set_requestor()

gpg_error_t ksba_ocsp_set_requestor ( ksba_ocsp_t  ocsp,
ksba_cert_t  cert 
)

◆ ksba_ocsp_set_sig_val()

gpg_error_t ksba_ocsp_set_sig_val ( ksba_ocsp_t  ocsp,
ksba_const_sexp_t  sigval 
)

◆ ksba_oid_from_str()

◆ ksba_oid_to_str()

◆ ksba_reader_clear()

gpg_error_t ksba_reader_clear ( ksba_reader_t  r,
unsigned char **  buffer,
size_t *  buflen 
)

◆ ksba_reader_error()

◆ ksba_reader_new()

gpg_error_t ksba_reader_new ( ksba_reader_t r_r)

◆ ksba_reader_read()

gpg_error_t ksba_reader_read ( ksba_reader_t  r,
char *  buffer,
size_t  length,
size_t *  nread 
)

◆ ksba_reader_release()

void ksba_reader_release ( ksba_reader_t  r)

◆ ksba_reader_set_cb()

gpg_error_t ksba_reader_set_cb ( ksba_reader_t  r,
int(*)(void *, char *, size_t, size_t *)  cb,
void *  cb_value 
)

◆ ksba_reader_set_fd()

gpg_error_t ksba_reader_set_fd ( ksba_reader_t  r,
int  fd 
)

◆ ksba_reader_set_file()

gpg_error_t ksba_reader_set_file ( ksba_reader_t  r,
FILE *  fp 
)

Referenced by one_file().

◆ ksba_reader_set_mem()

gpg_error_t ksba_reader_set_mem ( ksba_reader_t  r,
const void *  buffer,
size_t  length 
)

◆ ksba_reader_set_release_notify()

gpg_error_t ksba_reader_set_release_notify ( ksba_reader_t  r,
void(*)(void *, ksba_reader_t notify,
void *  notify_value 
)

◆ ksba_reader_tell()

◆ ksba_reader_unread()

gpg_error_t ksba_reader_unread ( ksba_reader_t  r,
const void *  buffer,
size_t  count 
)

◆ ksba_realloc()

void* ksba_realloc ( void *  p,
size_t  n 
)

◆ ksba_set_hash_buffer_function()

void ksba_set_hash_buffer_function ( gpg_error_t(*)(void *arg, const char *oid, const void *buffer, size_t length, size_t resultsize, unsigned char *result, size_t *resultlen)  fnc,
void *  fnc_arg 
)

◆ ksba_set_malloc_hooks()

void ksba_set_malloc_hooks ( void *(*)(size_t n)  new_alloc_func,
void *(*)(void *p, size_t n)  new_realloc_func,
void(*)(void *)  new_free_func 
)

◆ ksba_strdup()

char* ksba_strdup ( const char *  p)

Referenced by _ksba_xstrdup().

◆ ksba_writer_error()

int ksba_writer_error ( ksba_writer_t  w)

◆ ksba_writer_get_mem()

const void* ksba_writer_get_mem ( ksba_writer_t  w,
size_t *  nbytes 
)

◆ ksba_writer_new()

◆ ksba_writer_release()

◆ ksba_writer_set_cb()

gpg_error_t ksba_writer_set_cb ( ksba_writer_t  w,
int(*)(void *, const void *, size_t)  cb,
void *  cb_value 
)

◆ ksba_writer_set_fd()

gpg_error_t ksba_writer_set_fd ( ksba_writer_t  w,
int  fd 
)

◆ ksba_writer_set_file()

gpg_error_t ksba_writer_set_file ( ksba_writer_t  w,
FILE *  fp 
)

◆ ksba_writer_set_filter()

gpg_error_t ksba_writer_set_filter ( ksba_writer_t  w,
gpg_error_t(*)(void *, const void *, size_t, size_t *, void *, size_t, size_t *)  filter,
void *  filter_arg 
)

◆ ksba_writer_set_mem()

◆ ksba_writer_set_release_notify()

gpg_error_t ksba_writer_set_release_notify ( ksba_writer_t  w,
void(*)(void *, ksba_writer_t notify,
void *  notify_value 
)

◆ ksba_writer_snatch_mem()

◆ ksba_writer_tell()

unsigned long ksba_writer_tell ( ksba_writer_t  w)

◆ ksba_writer_write()

◆ ksba_writer_write_octet_string()

gpg_error_t ksba_writer_write_octet_string ( ksba_writer_t  w,
const void *  buffer,
size_t  length,
int  flush 
)