crypto/*: Fix various typos, repeated words, align some spelling to LDP.

partially revamped from #16712
- fall thru -> fall through
- time stamp -> timestamp
- host name -> hostname
- ipv6 -> IPv6

Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19059)
This commit is contained in:
FdaSilvaYY 2022-08-23 20:37:03 +02:00 committed by Pauli
parent 1567a821a4
commit c734058309
21 changed files with 98 additions and 98 deletions

View File

@ -327,7 +327,7 @@ int BIO_listen(int sock, const BIO_ADDR *addr, int options)
} }
} }
/* On OpenBSD it is always ipv6 only with ipv6 sockets thus read-only */ /* On OpenBSD it is always IPv6 only with IPv6 sockets thus read-only */
# if defined(IPV6_V6ONLY) && !defined(__OpenBSD__) # if defined(IPV6_V6ONLY) && !defined(__OpenBSD__)
if (BIO_ADDR_family(addr) == AF_INET6) { if (BIO_ADDR_family(addr) == AF_INET6) {
/* /*

View File

@ -19,7 +19,7 @@
* The prime is: 2^768 - 2 ^704 - 1 + 2^64 * { [2^638 pi] + 149686 } * The prime is: 2^768 - 2 ^704 - 1 + 2^64 * { [2^638 pi] + 149686 }
* *
* RFC2409 specifies a generator of 2. * RFC2409 specifies a generator of 2.
* RFC2412 specifies a generator of of 22. * RFC2412 specifies a generator of 22.
*/ */
BIGNUM *BN_get_rfc2409_prime_768(BIGNUM *bn) BIGNUM *BN_get_rfc2409_prime_768(BIGNUM *bn)

View File

@ -618,7 +618,7 @@ int OSSL_CMP_validate_msg(OSSL_CMP_CTX *ctx, const OSSL_CMP_MSG *msg)
} }
if (check_msg_find_cert(ctx, msg)) { if (check_msg_find_cert(ctx, msg)) {
ossl_cmp_debug(ctx, ossl_cmp_debug(ctx,
"sucessfully validated signature-based CMP message protection using trust store"); "successfully validated signature-based CMP message protection using trust store");
return 1; return 1;
} }
} else { /* use pinned sender cert */ } else { /* use pinned sender cert */

View File

@ -14,7 +14,7 @@
struct dsa_st { struct dsa_st {
/* /*
* This first variable is used to pick up errors where a DSA is passed * This first variable is used to pick up errors where a DSA is passed
* instead of of a EVP_PKEY * instead of an EVP_PKEY
*/ */
int pad; int pad;
int32_t version; int32_t version;

View File

@ -621,7 +621,7 @@ int ossl_ffc_params_FIPS186_4_gen_verify(OSSL_LIB_CTX *libctx,
p = params->p; p = params->p;
q = params->q; q = params->q;
goto g_only; goto g_only;
/* otherwise fall thru to validate p & q */ /* otherwise fall through to validate p & q */
} }
/* p & q will be used for generation and validation */ /* p & q will be used for generation and validation */
@ -922,7 +922,7 @@ int ossl_ffc_params_FIPS186_2_gen_verify(OSSL_LIB_CTX *libctx,
p = params->p; p = params->p;
q = params->q; q = params->q;
goto g_only; goto g_only;
/* otherwise fall thru to validate p and q */ /* otherwise fall through to validate p and q */
} }
use_random_seed = (seed_in == NULL); use_random_seed = (seed_in == NULL);

View File

@ -51,7 +51,7 @@ struct ossl_http_req_ctx_st {
void *upd_arg; /* Optional arg for update callback function */ void *upd_arg; /* Optional arg for update callback function */
int use_ssl; /* Use HTTPS */ int use_ssl; /* Use HTTPS */
char *proxy; /* Optional proxy name or URI */ char *proxy; /* Optional proxy name or URI */
char *server; /* Optional server host name */ char *server; /* Optional server hostname */
char *port; /* Optional server port */ char *port; /* Optional server port */
BIO *mem; /* Mem BIO holding request header or response */ BIO *mem; /* Mem BIO holding request header or response */
BIO *req; /* BIO holding the request provided by caller */ BIO *req; /* BIO holding the request provided by caller */
@ -565,14 +565,14 @@ int OSSL_HTTP_REQ_CTX_nbio(OSSL_HTTP_REQ_CTX *rctx)
} }
rctx->state = OHS_WRITE_INIT; rctx->state = OHS_WRITE_INIT;
/* fall thru */ /* fall through */
case OHS_WRITE_INIT: case OHS_WRITE_INIT:
rctx->len_to_send = BIO_get_mem_data(rctx->mem, &rctx->pos); rctx->len_to_send = BIO_get_mem_data(rctx->mem, &rctx->pos);
rctx->state = OHS_WRITE_HDR; rctx->state = OHS_WRITE_HDR;
if (OSSL_TRACE_ENABLED(HTTP)) if (OSSL_TRACE_ENABLED(HTTP))
OSSL_TRACE(HTTP, "Sending request header:\n"); OSSL_TRACE(HTTP, "Sending request header:\n");
/* fall thru */ /* fall through */
case OHS_WRITE_HDR: case OHS_WRITE_HDR:
/* Copy some chunk of data from rctx->mem to rctx->wbio */ /* Copy some chunk of data from rctx->mem to rctx->wbio */
case OHS_WRITE_REQ: case OHS_WRITE_REQ:
@ -612,7 +612,7 @@ int OSSL_HTTP_REQ_CTX_nbio(OSSL_HTTP_REQ_CTX *rctx)
} }
rctx->state = OHS_FLUSH; rctx->state = OHS_FLUSH;
/* fall thru */ /* fall through */
case OHS_FLUSH: case OHS_FLUSH:
i = BIO_flush(rctx->wbio); i = BIO_flush(rctx->wbio);

View File

@ -83,9 +83,9 @@ int OSSL_parse_url(const char *url, char **pscheme, char **puser, char **phost,
else else
host = p; host = p;
/* parse host name/address as far as needed here */ /* parse hostname/address as far as needed here */
if (host[0] == '[') { if (host[0] == '[') {
/* ipv6 literal, which may include ':' */ /* IPv6 literal, which may include ':' */
host_end = strchr(host + 1, ']'); host_end = strchr(host + 1, ']');
if (host_end == NULL) if (host_end == NULL)
goto parse_err; goto parse_err;

View File

@ -23,19 +23,19 @@ else \
l1=l2=0; \ l1=l2=0; \
switch (n) { \ switch (n) { \
case 8: l2 =((unsigned long)(*(--(c)))) ; \ case 8: l2 =((unsigned long)(*(--(c)))) ; \
/* fall thru */ \ /* fall through */ \
case 7: l2|=((unsigned long)(*(--(c))))<< 8; \ case 7: l2|=((unsigned long)(*(--(c))))<< 8; \
/* fall thru */ \ /* fall through */ \
case 6: l2|=((unsigned long)(*(--(c))))<<16; \ case 6: l2|=((unsigned long)(*(--(c))))<<16; \
/* fall thru */ \ /* fall through */ \
case 5: l2|=((unsigned long)(*(--(c))))<<24; \ case 5: l2|=((unsigned long)(*(--(c))))<<24; \
/* fall thru */ \ /* fall through */ \
case 4: l1 =((unsigned long)(*(--(c)))) ; \ case 4: l1 =((unsigned long)(*(--(c)))) ; \
/* fall thru */ \ /* fall through */ \
case 3: l1|=((unsigned long)(*(--(c))))<< 8; \ case 3: l1|=((unsigned long)(*(--(c))))<< 8; \
/* fall thru */ \ /* fall through */ \
case 2: l1|=((unsigned long)(*(--(c))))<<16; \ case 2: l1|=((unsigned long)(*(--(c))))<<16; \
/* fall thru */ \ /* fall through */ \
case 1: l1|=((unsigned long)(*(--(c))))<<24; \ case 1: l1|=((unsigned long)(*(--(c))))<<24; \
} \ } \
} }
@ -45,19 +45,19 @@ else \
c+=n; \ c+=n; \
switch (n) { \ switch (n) { \
case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \ case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \ case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \
/* fall thru */ \ /* fall through */ \
case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \ case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \
/* fall thru */ \ /* fall through */ \
case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \ case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \
/* fall thru */ \ /* fall through */ \
case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \ case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \ case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \
/* fall thru */ \ /* fall through */ \
case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \ case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \
/* fall thru */ \ /* fall through */ \
case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \ case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \
} \ } \
} }

View File

@ -41,7 +41,7 @@ static int pk7_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it,
case ASN1_OP_STREAM_PRE: case ASN1_OP_STREAM_PRE:
if (PKCS7_stream(&sarg->boundary, *pp7) <= 0) if (PKCS7_stream(&sarg->boundary, *pp7) <= 0)
return 0; return 0;
/* fall thru */ /* fall through */
case ASN1_OP_DETACHED_PRE: case ASN1_OP_DETACHED_PRE:
sarg->ndef_bio = PKCS7_dataInit(*pp7, sarg->out); sarg->ndef_bio = PKCS7_dataInit(*pp7, sarg->out);
if (!sarg->ndef_bio) if (!sarg->ndef_bio)

View File

@ -20,19 +20,19 @@
l1=l2=0; \ l1=l2=0; \
switch (n) { \ switch (n) { \
case 8: l2 =((unsigned long)(*(--(c))))<<24L; \ case 8: l2 =((unsigned long)(*(--(c))))<<24L; \
/* fall thru */ \ /* fall through */ \
case 7: l2|=((unsigned long)(*(--(c))))<<16L; \ case 7: l2|=((unsigned long)(*(--(c))))<<16L; \
/* fall thru */ \ /* fall through */ \
case 6: l2|=((unsigned long)(*(--(c))))<< 8L; \ case 6: l2|=((unsigned long)(*(--(c))))<< 8L; \
/* fall thru */ \ /* fall through */ \
case 5: l2|=((unsigned long)(*(--(c)))); \ case 5: l2|=((unsigned long)(*(--(c)))); \
/* fall thru */ \ /* fall through */ \
case 4: l1 =((unsigned long)(*(--(c))))<<24L; \ case 4: l1 =((unsigned long)(*(--(c))))<<24L; \
/* fall thru */ \ /* fall through */ \
case 3: l1|=((unsigned long)(*(--(c))))<<16L; \ case 3: l1|=((unsigned long)(*(--(c))))<<16L; \
/* fall thru */ \ /* fall through */ \
case 2: l1|=((unsigned long)(*(--(c))))<< 8L; \ case 2: l1|=((unsigned long)(*(--(c))))<< 8L; \
/* fall thru */ \ /* fall through */ \
case 1: l1|=((unsigned long)(*(--(c)))); \ case 1: l1|=((unsigned long)(*(--(c)))); \
} \ } \
} }
@ -49,19 +49,19 @@
c+=n; \ c+=n; \
switch (n) { \ switch (n) { \
case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \ case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \ case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \ case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \ case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \ case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \ case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \ case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \ case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \
} \ } \
} }
@ -72,19 +72,19 @@
l1=l2=0; \ l1=l2=0; \
switch (n) { \ switch (n) { \
case 8: l2 =((unsigned long)(*(--(c)))) ; \ case 8: l2 =((unsigned long)(*(--(c)))) ; \
/* fall thru */ \ /* fall through */ \
case 7: l2|=((unsigned long)(*(--(c))))<< 8; \ case 7: l2|=((unsigned long)(*(--(c))))<< 8; \
/* fall thru */ \ /* fall through */ \
case 6: l2|=((unsigned long)(*(--(c))))<<16; \ case 6: l2|=((unsigned long)(*(--(c))))<<16; \
/* fall thru */ \ /* fall through */ \
case 5: l2|=((unsigned long)(*(--(c))))<<24; \ case 5: l2|=((unsigned long)(*(--(c))))<<24; \
/* fall thru */ \ /* fall through */ \
case 4: l1 =((unsigned long)(*(--(c)))) ; \ case 4: l1 =((unsigned long)(*(--(c)))) ; \
/* fall thru */ \ /* fall through */ \
case 3: l1|=((unsigned long)(*(--(c))))<< 8; \ case 3: l1|=((unsigned long)(*(--(c))))<< 8; \
/* fall thru */ \ /* fall through */ \
case 2: l1|=((unsigned long)(*(--(c))))<<16; \ case 2: l1|=((unsigned long)(*(--(c))))<<16; \
/* fall thru */ \ /* fall through */ \
case 1: l1|=((unsigned long)(*(--(c))))<<24; \ case 1: l1|=((unsigned long)(*(--(c))))<<24; \
} \ } \
} }
@ -94,19 +94,19 @@
c+=n; \ c+=n; \
switch (n) { \ switch (n) { \
case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \ case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \ case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \
/* fall thru */ \ /* fall through */ \
case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \ case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \
/* fall thru */ \ /* fall through */ \
case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \ case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \
/* fall thru */ \ /* fall through */ \
case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \ case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \ case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \
/* fall thru */ \ /* fall through */ \
case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \ case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \
/* fall thru */ \ /* fall through */ \
case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \ case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \
} \ } \
} }

View File

@ -22,19 +22,19 @@
l1=l2=0; \ l1=l2=0; \
switch (n) { \ switch (n) { \
case 8: l2 =((unsigned long)(*(--(c))))<<24L; \ case 8: l2 =((unsigned long)(*(--(c))))<<24L; \
/* fall thru */ \ /* fall through */ \
case 7: l2|=((unsigned long)(*(--(c))))<<16L; \ case 7: l2|=((unsigned long)(*(--(c))))<<16L; \
/* fall thru */ \ /* fall through */ \
case 6: l2|=((unsigned long)(*(--(c))))<< 8L; \ case 6: l2|=((unsigned long)(*(--(c))))<< 8L; \
/* fall thru */ \ /* fall through */ \
case 5: l2|=((unsigned long)(*(--(c)))); \ case 5: l2|=((unsigned long)(*(--(c)))); \
/* fall thru */ \ /* fall through */ \
case 4: l1 =((unsigned long)(*(--(c))))<<24L; \ case 4: l1 =((unsigned long)(*(--(c))))<<24L; \
/* fall thru */ \ /* fall through */ \
case 3: l1|=((unsigned long)(*(--(c))))<<16L; \ case 3: l1|=((unsigned long)(*(--(c))))<<16L; \
/* fall thru */ \ /* fall through */ \
case 2: l1|=((unsigned long)(*(--(c))))<< 8L; \ case 2: l1|=((unsigned long)(*(--(c))))<< 8L; \
/* fall thru */ \ /* fall through */ \
case 1: l1|=((unsigned long)(*(--(c)))); \ case 1: l1|=((unsigned long)(*(--(c)))); \
} \ } \
} }
@ -51,19 +51,19 @@
c+=n; \ c+=n; \
switch (n) { \ switch (n) { \
case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \ case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \ case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \ case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \ case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \ case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \ case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \ case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \
/* fall thru */ \ /* fall through */ \
case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \ case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \
} \ } \
} }
@ -74,19 +74,19 @@
l1=l2=0; \ l1=l2=0; \
switch (n) { \ switch (n) { \
case 8: l2 =((unsigned long)(*(--(c)))) ; \ case 8: l2 =((unsigned long)(*(--(c)))) ; \
/* fall thru */ \ /* fall through */ \
case 7: l2|=((unsigned long)(*(--(c))))<< 8; \ case 7: l2|=((unsigned long)(*(--(c))))<< 8; \
/* fall thru */ \ /* fall through */ \
case 6: l2|=((unsigned long)(*(--(c))))<<16; \ case 6: l2|=((unsigned long)(*(--(c))))<<16; \
/* fall thru */ \ /* fall through */ \
case 5: l2|=((unsigned long)(*(--(c))))<<24; \ case 5: l2|=((unsigned long)(*(--(c))))<<24; \
/* fall thru */ \ /* fall through */ \
case 4: l1 =((unsigned long)(*(--(c)))) ; \ case 4: l1 =((unsigned long)(*(--(c)))) ; \
/* fall thru */ \ /* fall through */ \
case 3: l1|=((unsigned long)(*(--(c))))<< 8; \ case 3: l1|=((unsigned long)(*(--(c))))<< 8; \
/* fall thru */ \ /* fall through */ \
case 2: l1|=((unsigned long)(*(--(c))))<<16; \ case 2: l1|=((unsigned long)(*(--(c))))<<16; \
/* fall thru */ \ /* fall through */ \
case 1: l1|=((unsigned long)(*(--(c))))<<24; \ case 1: l1|=((unsigned long)(*(--(c))))<<24; \
} \ } \
} }
@ -96,19 +96,19 @@
c+=n; \ c+=n; \
switch (n) { \ switch (n) { \
case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \ case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \ case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \
/* fall thru */ \ /* fall through */ \
case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \ case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \
/* fall thru */ \ /* fall through */ \
case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \ case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \
/* fall thru */ \ /* fall through */ \
case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \ case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \
/* fall thru */ \ /* fall through */ \
case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \ case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \
/* fall thru */ \ /* fall through */ \
case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \ case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \
/* fall thru */ \ /* fall through */ \
case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \ case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \
} \ } \
} }

View File

@ -210,22 +210,22 @@ int SipHash_Final(SIPHASH *ctx, unsigned char *out, size_t outlen)
switch (ctx->len) { switch (ctx->len) {
case 7: case 7:
b |= ((uint64_t)ctx->leavings[6]) << 48; b |= ((uint64_t)ctx->leavings[6]) << 48;
/* fall thru */ /* fall through */
case 6: case 6:
b |= ((uint64_t)ctx->leavings[5]) << 40; b |= ((uint64_t)ctx->leavings[5]) << 40;
/* fall thru */ /* fall through */
case 5: case 5:
b |= ((uint64_t)ctx->leavings[4]) << 32; b |= ((uint64_t)ctx->leavings[4]) << 32;
/* fall thru */ /* fall through */
case 4: case 4:
b |= ((uint64_t)ctx->leavings[3]) << 24; b |= ((uint64_t)ctx->leavings[3]) << 24;
/* fall thru */ /* fall through */
case 3: case 3:
b |= ((uint64_t)ctx->leavings[2]) << 16; b |= ((uint64_t)ctx->leavings[2]) << 16;
/* fall thru */ /* fall through */
case 2: case 2:
b |= ((uint64_t)ctx->leavings[1]) << 8; b |= ((uint64_t)ctx->leavings[1]) << 8;
/* fall thru */ /* fall through */
case 1: case 1:
b |= ((uint64_t)ctx->leavings[0]); b |= ((uint64_t)ctx->leavings[0]);
case 0: case 0:

View File

@ -627,7 +627,7 @@ OSSL_STORE_INFO *OSSL_STORE_INFO_new_CRL(X509_CRL *crl)
} }
/* /*
* Functions to try to extract data from a OSSL_STORE_INFO. * Functions to try to extract data from an OSSL_STORE_INFO.
*/ */
int OSSL_STORE_INFO_get_type(const OSSL_STORE_INFO *info) int OSSL_STORE_INFO_get_type(const OSSL_STORE_INFO *info)
{ {

View File

@ -110,7 +110,7 @@ struct TS_resp_ctx {
ASN1_INTEGER *seconds; /* accuracy, 0 means not specified. */ ASN1_INTEGER *seconds; /* accuracy, 0 means not specified. */
ASN1_INTEGER *millis; /* accuracy, 0 means not specified. */ ASN1_INTEGER *millis; /* accuracy, 0 means not specified. */
ASN1_INTEGER *micros; /* accuracy, 0 means not specified. */ ASN1_INTEGER *micros; /* accuracy, 0 means not specified. */
unsigned clock_precision_digits; /* fraction of seconds in time stamp unsigned clock_precision_digits; /* fraction of seconds in timestamp
* token. */ * token. */
unsigned flags; /* Optional info, see values above. */ unsigned flags; /* Optional info, see values above. */
/* Callback functions. */ /* Callback functions. */

View File

@ -278,7 +278,7 @@ int TS_RESP_verify_token(TS_VERIFY_CTX *ctx, PKCS7 *token)
} }
/*- /*-
* Verifies whether the 'token' contains a valid time stamp token * Verifies whether the 'token' contains a valid timestamp token
* with regards to the settings of the context. Only those checks are * with regards to the settings of the context. Only those checks are
* carried out that are specified in the context: * carried out that are specified in the context:
* - Verifies the signature of the TS_TST_INFO. * - Verifies the signature of the TS_TST_INFO.

View File

@ -27,7 +27,7 @@ static int cache_objects(X509_LOOKUP *lctx, const char *uri,
/* /*
* We try to set the criterion, but don't care if it was valid or not. * We try to set the criterion, but don't care if it was valid or not.
* For a OSSL_STORE, it merely serves as an optimization, the expectation * For an OSSL_STORE, it merely serves as an optimization, the expectation
* being that if the criterion couldn't be used, we will get *everything* * being that if the criterion couldn't be used, we will get *everything*
* from the container that the URI represents rather than the subset that * from the container that the URI represents rather than the subset that
* the criterion indicates, so the biggest harm is that we cache more * the criterion indicates, so the biggest harm is that we cache more

View File

@ -440,7 +440,7 @@ int NAME_CONSTRAINTS_check_CN(X509 *x, NAME_CONSTRAINTS *nc)
ne = X509_NAME_get_entry(nm, i); ne = X509_NAME_get_entry(nm, i);
cn = X509_NAME_ENTRY_get_data(ne); cn = X509_NAME_ENTRY_get_data(ne);
/* Only process attributes that look like host names */ /* Only process attributes that look like hostnames */
if ((r = cn2dnsid(cn, &idval, &idlen)) != X509_V_OK) if ((r = cn2dnsid(cn, &idval, &idlen)) != X509_V_OK)
return r; return r;
if (idlen == 0) if (idlen == 0)

View File

@ -854,7 +854,7 @@ static int check_purpose_timestamp_sign(const X509_PURPOSE *xp, const X509 *x,
!(x->ex_kusage & (KU_NON_REPUDIATION | KU_DIGITAL_SIGNATURE)))) !(x->ex_kusage & (KU_NON_REPUDIATION | KU_DIGITAL_SIGNATURE))))
return 0; return 0;
/* Only time stamp key usage is permitted and it's required. */ /* Only timestamp key usage is permitted and it's required. */
if ((x->ex_flags & EXFLAG_XKUSAGE) == 0 || x->ex_xkusage != XKU_TIMESTAMP) if ((x->ex_flags & EXFLAG_XKUSAGE) == 0 || x->ex_xkusage != XKU_TIMESTAMP)
return 0; return 0;

View File

@ -174,7 +174,7 @@ static int crl_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it,
ASN1_INTEGER_free(crl->crl_number); ASN1_INTEGER_free(crl->crl_number);
ASN1_INTEGER_free(crl->base_crl_number); ASN1_INTEGER_free(crl->base_crl_number);
sk_GENERAL_NAMES_pop_free(crl->issuers, GENERAL_NAMES_free); sk_GENERAL_NAMES_pop_free(crl->issuers, GENERAL_NAMES_free);
/* fall thru */ /* fall through */
case ASN1_OP_NEW_POST: case ASN1_OP_NEW_POST:
crl->idp = NULL; crl->idp = NULL;

View File

@ -53,7 +53,7 @@ static int req_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it,
switch (operation) { switch (operation) {
case ASN1_OP_D2I_PRE: case ASN1_OP_D2I_PRE:
ASN1_OCTET_STRING_free(ret->distinguishing_id); ASN1_OCTET_STRING_free(ret->distinguishing_id);
/* fall thru */ /* fall through */
case ASN1_OP_NEW_POST: case ASN1_OP_NEW_POST:
ret->distinguishing_id = NULL; ret->distinguishing_id = NULL;
break; break;

View File

@ -55,7 +55,7 @@ static int x509_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it,
#endif #endif
ASN1_OCTET_STRING_free(ret->distinguishing_id); ASN1_OCTET_STRING_free(ret->distinguishing_id);
/* fall thru */ /* fall through */
case ASN1_OP_NEW_POST: case ASN1_OP_NEW_POST:
ret->ex_cached = 0; ret->ex_cached = 0;