webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
Classes | Macros | Typedefs | Enumerations | Functions
err.h File Reference
#include <stdio.h>
#include <openssl/base.h>

Go to the source code of this file.

Classes

struct  err_error_st
 
struct  err_state_st
 

Macros

#define ERR_ERROR_STRING_BUF_LEN   256
 
#define OPENSSL_PUT_ERROR(library, reason)   ERR_put_error(ERR_LIB_##library, 0, reason, __FILE__, __LINE__)
 
#define OPENSSL_PUT_SYSTEM_ERROR()   ERR_put_error(ERR_LIB_SYS, 0, 0, __FILE__, __LINE__);
 
#define ERR_FLAG_STRING   1
 
#define ERR_TXT_STRING   ERR_FLAG_STRING
 
#define ERR_FLAG_PUBLIC_MASK   0xf
 
#define ERR_FLAG_MALLOCED   16
 
#define ERR_FLAG_MARK   32
 
#define ERR_NUM_ERRORS   16
 
#define ERR_R_SYS_LIB   ERR_LIB_SYS
 
#define ERR_R_BN_LIB   ERR_LIB_BN
 
#define ERR_R_RSA_LIB   ERR_LIB_RSA
 
#define ERR_R_DH_LIB   ERR_LIB_DH
 
#define ERR_R_EVP_LIB   ERR_LIB_EVP
 
#define ERR_R_BUF_LIB   ERR_LIB_BUF
 
#define ERR_R_OBJ_LIB   ERR_LIB_OBJ
 
#define ERR_R_PEM_LIB   ERR_LIB_PEM
 
#define ERR_R_DSA_LIB   ERR_LIB_DSA
 
#define ERR_R_X509_LIB   ERR_LIB_X509
 
#define ERR_R_ASN1_LIB   ERR_LIB_ASN1
 
#define ERR_R_CONF_LIB   ERR_LIB_CONF
 
#define ERR_R_CRYPTO_LIB   ERR_LIB_CRYPTO
 
#define ERR_R_EC_LIB   ERR_LIB_EC
 
#define ERR_R_SSL_LIB   ERR_LIB_SSL
 
#define ERR_R_BIO_LIB   ERR_LIB_BIO
 
#define ERR_R_PKCS7_LIB   ERR_LIB_PKCS7
 
#define ERR_R_PKCS8_LIB   ERR_LIB_PKCS8
 
#define ERR_R_X509V3_LIB   ERR_LIB_X509V3
 
#define ERR_R_RAND_LIB   ERR_LIB_RAND
 
#define ERR_R_DSO_LIB   ERR_LIB_DSO
 
#define ERR_R_ENGINE_LIB   ERR_LIB_ENGINE
 
#define ERR_R_OCSP_LIB   ERR_LIB_OCSP
 
#define ERR_R_UI_LIB   ERR_LIB_UI
 
#define ERR_R_COMP_LIB   ERR_LIB_COMP
 
#define ERR_R_ECDSA_LIB   ERR_LIB_ECDSA
 
#define ERR_R_ECDH_LIB   ERR_LIB_ECDH
 
#define ERR_R_STORE_LIB   ERR_LIB_STORE
 
#define ERR_R_FIPS_LIB   ERR_LIB_FIPS
 
#define ERR_R_CMS_LIB   ERR_LIB_CMS
 
#define ERR_R_TS_LIB   ERR_LIB_TS
 
#define ERR_R_HMAC_LIB   ERR_LIB_HMAC
 
#define ERR_R_JPAKE_LIB   ERR_LIB_JPAKE
 
#define ERR_R_USER_LIB   ERR_LIB_USER
 
#define ERR_R_DIGEST_LIB   ERR_LIB_DIGEST
 
#define ERR_R_CIPHER_LIB   ERR_LIB_CIPHER
 
#define ERR_R_HKDF_LIB   ERR_LIB_HKDF
 
#define ERR_R_FATAL   64
 
#define ERR_R_MALLOC_FAILURE   (1 | ERR_R_FATAL)
 
#define ERR_R_SHOULD_NOT_HAVE_BEEN_CALLED   (2 | ERR_R_FATAL)
 
#define ERR_R_PASSED_NULL_PARAMETER   (3 | ERR_R_FATAL)
 
#define ERR_R_INTERNAL_ERROR   (4 | ERR_R_FATAL)
 
#define ERR_R_OVERFLOW   (5 | ERR_R_FATAL)
 
#define ERR_PACK(lib, reason)   (((((uint32_t)(lib)) & 0xff) << 24) | ((((uint32_t)(reason)) & 0xfff)))
 
#define ERR_GET_LIB(packed_error)   ((int)(((packed_error) >> 24) & 0xff))
 
#define ERR_GET_FUNC(packed_error)   0
 
#define ERR_GET_REASON(packed_error)   ((int)((packed_error) & 0xfff))
 
#define OPENSSL_DECLARE_ERROR_REASON(lib, reason)
 

Typedefs

typedef int(* ERR_print_errors_callback_t) (const char *str, size_t len, void *ctx)
 
typedef struct err_state_st ERR_STATE
 

Enumerations

enum  {
  ERR_LIB_NONE = 1, ERR_LIB_SYS, ERR_LIB_BN, ERR_LIB_RSA,
  ERR_LIB_DH, ERR_LIB_EVP, ERR_LIB_BUF, ERR_LIB_OBJ,
  ERR_LIB_PEM, ERR_LIB_DSA, ERR_LIB_X509, ERR_LIB_ASN1,
  ERR_LIB_CONF, ERR_LIB_CRYPTO, ERR_LIB_EC, ERR_LIB_SSL,
  ERR_LIB_BIO, ERR_LIB_PKCS7, ERR_LIB_PKCS8, ERR_LIB_X509V3,
  ERR_LIB_RAND, ERR_LIB_ENGINE, ERR_LIB_OCSP, ERR_LIB_UI,
  ERR_LIB_COMP, ERR_LIB_ECDSA, ERR_LIB_ECDH, ERR_LIB_HMAC,
  ERR_LIB_DIGEST, ERR_LIB_CIPHER, ERR_LIB_HKDF, ERR_LIB_USER,
  ERR_NUM_LIBS
}
 

Functions

OPENSSL_EXPORT void ERR_load_BIO_strings (void)
 
OPENSSL_EXPORT void ERR_load_ERR_strings (void)
 
OPENSSL_EXPORT void ERR_load_crypto_strings (void)
 
OPENSSL_EXPORT void ERR_free_strings (void)
 
OPENSSL_EXPORT uint32_t ERR_get_error (void)
 
OPENSSL_EXPORT uint32_t ERR_get_error_line (const char **file, int *line)
 
OPENSSL_EXPORT uint32_t ERR_get_error_line_data (const char **file, int *line, const char **data, int *flags)
 
OPENSSL_EXPORT uint32_t ERR_peek_error (void)
 
OPENSSL_EXPORT uint32_t ERR_peek_error_line (const char **file, int *line)
 
OPENSSL_EXPORT uint32_t ERR_peek_error_line_data (const char **file, int *line, const char **data, int *flags)
 
OPENSSL_EXPORT uint32_t ERR_peek_last_error (void)
 
OPENSSL_EXPORT uint32_t ERR_peek_last_error_line (const char **file, int *line)
 
OPENSSL_EXPORT uint32_t ERR_peek_last_error_line_data (const char **file, int *line, const char **data, int *flags)
 
OPENSSL_EXPORT char * ERR_error_string (uint32_t packed_error, char *buf)
 
OPENSSL_EXPORT void ERR_error_string_n (uint32_t packed_error, char *buf, size_t len)
 
OPENSSL_EXPORT const char * ERR_lib_error_string (uint32_t packed_error)
 
OPENSSL_EXPORT const char * ERR_reason_error_string (uint32_t packed_error)
 
OPENSSL_EXPORT void ERR_print_errors_cb (ERR_print_errors_callback_t callback, void *ctx)
 
OPENSSL_EXPORT void ERR_print_errors_fp (FILE *file)
 
OPENSSL_EXPORT void ERR_clear_error (void)
 
OPENSSL_EXPORT void ERR_remove_thread_state (const CRYPTO_THREADID *tid)
 
OPENSSL_EXPORT int ERR_get_next_error_library (void)
 
OPENSSL_EXPORT void ERR_remove_state (unsigned long pid)
 
OPENSSL_EXPORT const char * ERR_func_error_string (uint32_t packed_error)
 
OPENSSL_EXPORT void ERR_clear_system_error (void)
 
OPENSSL_EXPORT void ERR_put_error (int library, int unused, int reason, const char *file, unsigned line)
 
OPENSSL_EXPORT void ERR_add_error_data (unsigned count,...)
 
OPENSSL_EXPORT void ERR_add_error_dataf (const char *format,...) OPENSSL_PRINTF_FORMAT_FUNC(1
 
OPENSSL_EXPORT void OPENSSL_EXPORT int ERR_set_mark (void)
 
OPENSSL_EXPORT int ERR_pop_to_mark (void)
 

Macro Definition Documentation

◆ ERR_ERROR_STRING_BUF_LEN

#define ERR_ERROR_STRING_BUF_LEN   256

◆ ERR_FLAG_MALLOCED

#define ERR_FLAG_MALLOCED   16

◆ ERR_FLAG_MARK

#define ERR_FLAG_MARK   32

◆ ERR_FLAG_PUBLIC_MASK

#define ERR_FLAG_PUBLIC_MASK   0xf

◆ ERR_FLAG_STRING

#define ERR_FLAG_STRING   1

◆ ERR_GET_FUNC

#define ERR_GET_FUNC (   packed_error)    0

◆ ERR_GET_LIB

#define ERR_GET_LIB (   packed_error)    ((int)(((packed_error) >> 24) & 0xff))

◆ ERR_GET_REASON

#define ERR_GET_REASON (   packed_error)    ((int)((packed_error) & 0xfff))

◆ ERR_NUM_ERRORS

#define ERR_NUM_ERRORS   16

◆ ERR_PACK

#define ERR_PACK (   lib,
  reason 
)    (((((uint32_t)(lib)) & 0xff) << 24) | ((((uint32_t)(reason)) & 0xfff)))

◆ ERR_R_ASN1_LIB

#define ERR_R_ASN1_LIB   ERR_LIB_ASN1

◆ ERR_R_BIO_LIB

#define ERR_R_BIO_LIB   ERR_LIB_BIO

◆ ERR_R_BN_LIB

#define ERR_R_BN_LIB   ERR_LIB_BN

◆ ERR_R_BUF_LIB

#define ERR_R_BUF_LIB   ERR_LIB_BUF

◆ ERR_R_CIPHER_LIB

#define ERR_R_CIPHER_LIB   ERR_LIB_CIPHER

◆ ERR_R_CMS_LIB

#define ERR_R_CMS_LIB   ERR_LIB_CMS

◆ ERR_R_COMP_LIB

#define ERR_R_COMP_LIB   ERR_LIB_COMP

◆ ERR_R_CONF_LIB

#define ERR_R_CONF_LIB   ERR_LIB_CONF

◆ ERR_R_CRYPTO_LIB

#define ERR_R_CRYPTO_LIB   ERR_LIB_CRYPTO

◆ ERR_R_DH_LIB

#define ERR_R_DH_LIB   ERR_LIB_DH

◆ ERR_R_DIGEST_LIB

#define ERR_R_DIGEST_LIB   ERR_LIB_DIGEST

◆ ERR_R_DSA_LIB

#define ERR_R_DSA_LIB   ERR_LIB_DSA

◆ ERR_R_DSO_LIB

#define ERR_R_DSO_LIB   ERR_LIB_DSO

◆ ERR_R_EC_LIB

#define ERR_R_EC_LIB   ERR_LIB_EC

◆ ERR_R_ECDH_LIB

#define ERR_R_ECDH_LIB   ERR_LIB_ECDH

◆ ERR_R_ECDSA_LIB

#define ERR_R_ECDSA_LIB   ERR_LIB_ECDSA

◆ ERR_R_ENGINE_LIB

#define ERR_R_ENGINE_LIB   ERR_LIB_ENGINE

◆ ERR_R_EVP_LIB

#define ERR_R_EVP_LIB   ERR_LIB_EVP

◆ ERR_R_FATAL

#define ERR_R_FATAL   64

◆ ERR_R_FIPS_LIB

#define ERR_R_FIPS_LIB   ERR_LIB_FIPS

◆ ERR_R_HKDF_LIB

#define ERR_R_HKDF_LIB   ERR_LIB_HKDF

◆ ERR_R_HMAC_LIB

#define ERR_R_HMAC_LIB   ERR_LIB_HMAC

◆ ERR_R_INTERNAL_ERROR

#define ERR_R_INTERNAL_ERROR   (4 | ERR_R_FATAL)

◆ ERR_R_JPAKE_LIB

#define ERR_R_JPAKE_LIB   ERR_LIB_JPAKE

◆ ERR_R_MALLOC_FAILURE

#define ERR_R_MALLOC_FAILURE   (1 | ERR_R_FATAL)

◆ ERR_R_OBJ_LIB

#define ERR_R_OBJ_LIB   ERR_LIB_OBJ

◆ ERR_R_OCSP_LIB

#define ERR_R_OCSP_LIB   ERR_LIB_OCSP

◆ ERR_R_OVERFLOW

#define ERR_R_OVERFLOW   (5 | ERR_R_FATAL)

◆ ERR_R_PASSED_NULL_PARAMETER

#define ERR_R_PASSED_NULL_PARAMETER   (3 | ERR_R_FATAL)

◆ ERR_R_PEM_LIB

#define ERR_R_PEM_LIB   ERR_LIB_PEM

◆ ERR_R_PKCS7_LIB

#define ERR_R_PKCS7_LIB   ERR_LIB_PKCS7

◆ ERR_R_PKCS8_LIB

#define ERR_R_PKCS8_LIB   ERR_LIB_PKCS8

◆ ERR_R_RAND_LIB

#define ERR_R_RAND_LIB   ERR_LIB_RAND

◆ ERR_R_RSA_LIB

#define ERR_R_RSA_LIB   ERR_LIB_RSA

◆ ERR_R_SHOULD_NOT_HAVE_BEEN_CALLED

#define ERR_R_SHOULD_NOT_HAVE_BEEN_CALLED   (2 | ERR_R_FATAL)

◆ ERR_R_SSL_LIB

#define ERR_R_SSL_LIB   ERR_LIB_SSL

◆ ERR_R_STORE_LIB

#define ERR_R_STORE_LIB   ERR_LIB_STORE

◆ ERR_R_SYS_LIB

#define ERR_R_SYS_LIB   ERR_LIB_SYS

◆ ERR_R_TS_LIB

#define ERR_R_TS_LIB   ERR_LIB_TS

◆ ERR_R_UI_LIB

#define ERR_R_UI_LIB   ERR_LIB_UI

◆ ERR_R_USER_LIB

#define ERR_R_USER_LIB   ERR_LIB_USER

◆ ERR_R_X509_LIB

#define ERR_R_X509_LIB   ERR_LIB_X509

◆ ERR_R_X509V3_LIB

#define ERR_R_X509V3_LIB   ERR_LIB_X509V3

◆ ERR_TXT_STRING

#define ERR_TXT_STRING   ERR_FLAG_STRING

◆ OPENSSL_DECLARE_ERROR_REASON

#define OPENSSL_DECLARE_ERROR_REASON (   lib,
  reason 
)

◆ OPENSSL_PUT_ERROR

#define OPENSSL_PUT_ERROR (   library,
  reason 
)    ERR_put_error(ERR_LIB_##library, 0, reason, __FILE__, __LINE__)

◆ OPENSSL_PUT_SYSTEM_ERROR

#define OPENSSL_PUT_SYSTEM_ERROR ( )    ERR_put_error(ERR_LIB_SYS, 0, 0, __FILE__, __LINE__);

Typedef Documentation

◆ ERR_print_errors_callback_t

typedef int(* ERR_print_errors_callback_t) (const char *str, size_t len, void *ctx)

◆ ERR_STATE

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
ERR_LIB_NONE 
ERR_LIB_SYS 
ERR_LIB_BN 
ERR_LIB_RSA 
ERR_LIB_DH 
ERR_LIB_EVP 
ERR_LIB_BUF 
ERR_LIB_OBJ 
ERR_LIB_PEM 
ERR_LIB_DSA 
ERR_LIB_X509 
ERR_LIB_ASN1 
ERR_LIB_CONF 
ERR_LIB_CRYPTO 
ERR_LIB_EC 
ERR_LIB_SSL 
ERR_LIB_BIO 
ERR_LIB_PKCS7 
ERR_LIB_PKCS8 
ERR_LIB_X509V3 
ERR_LIB_RAND 
ERR_LIB_ENGINE 
ERR_LIB_OCSP 
ERR_LIB_UI 
ERR_LIB_COMP 
ERR_LIB_ECDSA 
ERR_LIB_ECDH 
ERR_LIB_HMAC 
ERR_LIB_DIGEST 
ERR_LIB_CIPHER 
ERR_LIB_HKDF 
ERR_LIB_USER 
ERR_NUM_LIBS 

Function Documentation

◆ ERR_add_error_data()

OPENSSL_EXPORT void ERR_add_error_data ( unsigned  count,
  ... 
)

◆ ERR_add_error_dataf()

OPENSSL_EXPORT void ERR_add_error_dataf ( const char *  format,
  ... 
)

◆ ERR_clear_error()

OPENSSL_EXPORT void ERR_clear_error ( void  )

◆ ERR_clear_system_error()

OPENSSL_EXPORT void ERR_clear_system_error ( void  )

◆ ERR_error_string()

OPENSSL_EXPORT char* ERR_error_string ( uint32_t  packed_error,
char *  buf 
)

◆ ERR_error_string_n()

OPENSSL_EXPORT void ERR_error_string_n ( uint32_t  packed_error,
char *  buf,
size_t  len 
)

◆ ERR_free_strings()

OPENSSL_EXPORT void ERR_free_strings ( void  )

◆ ERR_func_error_string()

OPENSSL_EXPORT const char* ERR_func_error_string ( uint32_t  packed_error)

◆ ERR_get_error()

OPENSSL_EXPORT uint32_t ERR_get_error ( void  )

◆ ERR_get_error_line()

OPENSSL_EXPORT uint32_t ERR_get_error_line ( const char **  file,
int *  line 
)

◆ ERR_get_error_line_data()

OPENSSL_EXPORT uint32_t ERR_get_error_line_data ( const char **  file,
int *  line,
const char **  data,
int *  flags 
)

◆ ERR_get_next_error_library()

OPENSSL_EXPORT int ERR_get_next_error_library ( void  )

◆ ERR_lib_error_string()

OPENSSL_EXPORT const char* ERR_lib_error_string ( uint32_t  packed_error)

◆ ERR_load_BIO_strings()

OPENSSL_EXPORT void ERR_load_BIO_strings ( void  )

◆ ERR_load_crypto_strings()

OPENSSL_EXPORT void ERR_load_crypto_strings ( void  )

◆ ERR_load_ERR_strings()

OPENSSL_EXPORT void ERR_load_ERR_strings ( void  )

◆ ERR_peek_error()

OPENSSL_EXPORT uint32_t ERR_peek_error ( void  )

◆ ERR_peek_error_line()

OPENSSL_EXPORT uint32_t ERR_peek_error_line ( const char **  file,
int *  line 
)

◆ ERR_peek_error_line_data()

OPENSSL_EXPORT uint32_t ERR_peek_error_line_data ( const char **  file,
int *  line,
const char **  data,
int *  flags 
)

◆ ERR_peek_last_error()

OPENSSL_EXPORT uint32_t ERR_peek_last_error ( void  )

◆ ERR_peek_last_error_line()

OPENSSL_EXPORT uint32_t ERR_peek_last_error_line ( const char **  file,
int *  line 
)

◆ ERR_peek_last_error_line_data()

OPENSSL_EXPORT uint32_t ERR_peek_last_error_line_data ( const char **  file,
int *  line,
const char **  data,
int *  flags 
)

◆ ERR_pop_to_mark()

OPENSSL_EXPORT int ERR_pop_to_mark ( void  )

◆ ERR_print_errors_cb()

OPENSSL_EXPORT void ERR_print_errors_cb ( ERR_print_errors_callback_t  callback,
void ctx 
)

◆ ERR_print_errors_fp()

OPENSSL_EXPORT void ERR_print_errors_fp ( FILE *  file)

◆ ERR_put_error()

OPENSSL_EXPORT void ERR_put_error ( int  library,
int  unused,
int  reason,
const char *  file,
unsigned  line 
)

◆ ERR_reason_error_string()

OPENSSL_EXPORT const char* ERR_reason_error_string ( uint32_t  packed_error)

◆ ERR_remove_state()

OPENSSL_EXPORT void ERR_remove_state ( unsigned long  pid)

◆ ERR_remove_thread_state()

OPENSSL_EXPORT void ERR_remove_thread_state ( const CRYPTO_THREADID tid)

◆ ERR_set_mark()

OPENSSL_EXPORT void OPENSSL_EXPORT int ERR_set_mark ( void  )