diff options
author | beck <> | 2021-11-20 01:10:49 +0000 |
---|---|---|
committer | beck <> | 2021-11-20 01:10:49 +0000 |
commit | b7cded0ac3a92a8240de5424e37e204c1f237e33 (patch) | |
tree | 09562d0baf42f60ea370c64468465708195ec887 /src/lib/libcrypto/ct/ct_err.c | |
parent | ee06c57264840b41bbfa4268ff3d304fac1409d9 (diff) | |
download | openbsd-b7cded0ac3a92a8240de5424e37e204c1f237e33.tar.gz openbsd-b7cded0ac3a92a8240de5424e37e204c1f237e33.tar.bz2 openbsd-b7cded0ac3a92a8240de5424e37e204c1f237e33.zip |
Make these files compile - not hooked up to build yet.
ok jsing@ tb@
Diffstat (limited to 'src/lib/libcrypto/ct/ct_err.c')
-rw-r--r-- | src/lib/libcrypto/ct/ct_err.c | 34 |
1 files changed, 20 insertions, 14 deletions
diff --git a/src/lib/libcrypto/ct/ct_err.c b/src/lib/libcrypto/ct/ct_err.c index ab49f58e5a..f15e90891c 100644 --- a/src/lib/libcrypto/ct/ct_err.c +++ b/src/lib/libcrypto/ct/ct_err.c | |||
@@ -13,11 +13,12 @@ | |||
13 | 13 | ||
14 | #ifndef OPENSSL_NO_ERR | 14 | #ifndef OPENSSL_NO_ERR |
15 | 15 | ||
16 | static const ERR_STRING_DATA CT_str_functs[] = { | 16 | static ERR_STRING_DATA CT_str_functs[] = { |
17 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_NEW, 0), "CTLOG_new"}, | 17 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_NEW, 0), "CTLOG_new"}, |
18 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_NEW_FROM_BASE64, 0), | 18 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_NEW_FROM_BASE64, 0), |
19 | "CTLOG_new_from_base64"}, | 19 | "CTLOG_new_from_base64"}, |
20 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_NEW_FROM_CONF, 0), "ctlog_new_from_conf"}, | 20 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_NEW_FROM_CONF, 0), |
21 | "ctlog_new_from_conf"}, | ||
21 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_STORE_LOAD_CTX_NEW, 0), | 22 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_STORE_LOAD_CTX_NEW, 0), |
22 | "ctlog_store_load_ctx_new"}, | 23 | "ctlog_store_load_ctx_new"}, |
23 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_STORE_LOAD_FILE, 0), | 24 | {ERR_PACK(ERR_LIB_CT, CT_F_CTLOG_STORE_LOAD_FILE, 0), |
@@ -39,11 +40,14 @@ static const ERR_STRING_DATA CT_str_functs[] = { | |||
39 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_CTX_NEW, 0), "SCT_CTX_new"}, | 40 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_CTX_NEW, 0), "SCT_CTX_new"}, |
40 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_CTX_VERIFY, 0), "SCT_CTX_verify"}, | 41 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_CTX_VERIFY, 0), "SCT_CTX_verify"}, |
41 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_NEW, 0), "SCT_new"}, | 42 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_NEW, 0), "SCT_new"}, |
42 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_NEW_FROM_BASE64, 0), "SCT_new_from_base64"}, | 43 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_NEW_FROM_BASE64, 0), |
44 | "SCT_new_from_base64"}, | ||
43 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET0_LOG_ID, 0), "SCT_set0_log_id"}, | 45 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET0_LOG_ID, 0), "SCT_set0_log_id"}, |
44 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET1_EXTENSIONS, 0), "SCT_set1_extensions"}, | 46 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET1_EXTENSIONS, 0), |
47 | "SCT_set1_extensions"}, | ||
45 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET1_LOG_ID, 0), "SCT_set1_log_id"}, | 48 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET1_LOG_ID, 0), "SCT_set1_log_id"}, |
46 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET1_SIGNATURE, 0), "SCT_set1_signature"}, | 49 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET1_SIGNATURE, 0), |
50 | "SCT_set1_signature"}, | ||
47 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET_LOG_ENTRY_TYPE, 0), | 51 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET_LOG_ENTRY_TYPE, 0), |
48 | "SCT_set_log_entry_type"}, | 52 | "SCT_set_log_entry_type"}, |
49 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET_SIGNATURE_NID, 0), | 53 | {ERR_PACK(ERR_LIB_CT, CT_F_SCT_SET_SIGNATURE_NID, 0), |
@@ -52,8 +56,9 @@ static const ERR_STRING_DATA CT_str_functs[] = { | |||
52 | {0, NULL} | 56 | {0, NULL} |
53 | }; | 57 | }; |
54 | 58 | ||
55 | static const ERR_STRING_DATA CT_str_reasons[] = { | 59 | static ERR_STRING_DATA CT_str_reasons[] = { |
56 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_BASE64_DECODE_ERROR), "base64 decode error"}, | 60 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_BASE64_DECODE_ERROR), |
61 | "base64 decode error"}, | ||
57 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_INVALID_LOG_ID_LENGTH), | 62 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_INVALID_LOG_ID_LENGTH), |
58 | "invalid log id length"}, | 63 | "invalid log id length"}, |
59 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_LOG_CONF_INVALID), "log conf invalid"}, | 64 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_LOG_CONF_INVALID), "log conf invalid"}, |
@@ -70,7 +75,8 @@ static const ERR_STRING_DATA CT_str_reasons[] = { | |||
70 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_INVALID_SIGNATURE), | 75 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_INVALID_SIGNATURE), |
71 | "sct invalid signature"}, | 76 | "sct invalid signature"}, |
72 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_LIST_INVALID), "sct list invalid"}, | 77 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_LIST_INVALID), "sct list invalid"}, |
73 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_LOG_ID_MISMATCH), "sct log id mismatch"}, | 78 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_LOG_ID_MISMATCH), |
79 | "sct log id mismatch"}, | ||
74 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_NOT_SET), "sct not set"}, | 80 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_NOT_SET), "sct not set"}, |
75 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_UNSUPPORTED_VERSION), | 81 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_SCT_UNSUPPORTED_VERSION), |
76 | "sct unsupported version"}, | 82 | "sct unsupported version"}, |
@@ -78,19 +84,19 @@ static const ERR_STRING_DATA CT_str_reasons[] = { | |||
78 | "unrecognized signature nid"}, | 84 | "unrecognized signature nid"}, |
79 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_UNSUPPORTED_ENTRY_TYPE), | 85 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_UNSUPPORTED_ENTRY_TYPE), |
80 | "unsupported entry type"}, | 86 | "unsupported entry type"}, |
81 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_UNSUPPORTED_VERSION), "unsupported version"}, | 87 | {ERR_PACK(ERR_LIB_CT, 0, CT_R_UNSUPPORTED_VERSION), |
88 | "unsupported version"}, | ||
82 | {0, NULL} | 89 | {0, NULL} |
83 | }; | 90 | }; |
84 | 91 | ||
85 | #endif | 92 | #endif |
86 | 93 | ||
87 | int ERR_load_CT_strings(void) | 94 | int |
95 | ERR_load_CT_strings(void) | ||
88 | { | 96 | { |
89 | #ifndef OPENSSL_NO_ERR | ||
90 | if (ERR_func_error_string(CT_str_functs[0].error) == NULL) { | 97 | if (ERR_func_error_string(CT_str_functs[0].error) == NULL) { |
91 | ERR_load_strings_const(CT_str_functs); | 98 | ERR_load_strings(0, CT_str_functs); |
92 | ERR_load_strings_const(CT_str_reasons); | 99 | ERR_load_strings(0, CT_str_reasons); |
93 | } | 100 | } |
94 | #endif | ||
95 | return 1; | 101 | return 1; |
96 | } | 102 | } |