mirror of https://github.com/openssl/openssl
crypto: Fix various typos, repeated words, align some spelling to LDP.
partially revamped from #16712 - fall thru -> fall through - time stamp -> timestamp - file name -> filename - host name -> hostname 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:
parent
8b5424eae5
commit
1567a821a4
|
@ -92,7 +92,7 @@ int ossl_asn1_time_to_tm(struct tm *tm, const ASN1_TIME *d)
|
|||
*
|
||||
* 1. "seconds" is a 'MUST'
|
||||
* 2. "Zulu" timezone is a 'MUST'
|
||||
* 3. "+|-" is not allowed to indicate a time zone
|
||||
* 3. "+|-" is not allowed to indicate a timezone
|
||||
*/
|
||||
if (d->type == V_ASN1_UTCTIME) {
|
||||
if (d->flags & ASN1_STRING_FLAG_X509_TIME) {
|
||||
|
|
|
@ -17,19 +17,19 @@
|
|||
l1=l2=0; \
|
||||
switch (n) { \
|
||||
case 8: l2 =((unsigned long)(*(--(c)))) ; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 7: l2|=((unsigned long)(*(--(c))))<< 8; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 6: l2|=((unsigned long)(*(--(c))))<<16; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 5: l2|=((unsigned long)(*(--(c))))<<24; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 4: l1 =((unsigned long)(*(--(c)))) ; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 3: l1|=((unsigned long)(*(--(c))))<< 8; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 2: l1|=((unsigned long)(*(--(c))))<<16; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 1: l1|=((unsigned long)(*(--(c))))<<24; \
|
||||
} \
|
||||
}
|
||||
|
@ -39,19 +39,19 @@
|
|||
c+=n; \
|
||||
switch (n) { \
|
||||
case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \
|
||||
} \
|
||||
}
|
||||
|
|
|
@ -203,7 +203,7 @@ unsigned short BIO_ADDR_rawport(const BIO_ADDR *ap)
|
|||
* @numeric: 0 if actual names should be returned, 1 if the numeric
|
||||
* representation should be returned.
|
||||
* @hostname: a pointer to a pointer to a memory area to store the
|
||||
* host name or numeric representation. Unused if NULL.
|
||||
* hostname or numeric representation. Unused if NULL.
|
||||
* @service: a pointer to a pointer to a memory area to store the
|
||||
* service name or numeric representation. Unused if NULL.
|
||||
*
|
||||
|
|
|
@ -276,7 +276,7 @@ _dopr(char **sbuffer,
|
|||
break;
|
||||
case 'E':
|
||||
flags |= DP_F_UP;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case 'e':
|
||||
if (cflags == DP_C_LDOUBLE)
|
||||
fvalue = va_arg(args, LDOUBLE);
|
||||
|
@ -288,7 +288,7 @@ _dopr(char **sbuffer,
|
|||
break;
|
||||
case 'G':
|
||||
flags |= DP_F_UP;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case 'g':
|
||||
if (cflags == DP_C_LDOUBLE)
|
||||
fvalue = va_arg(args, LDOUBLE);
|
||||
|
|
|
@ -149,7 +149,7 @@ static long fd_ctrl(BIO *b, int cmd, long num, void *ptr)
|
|||
switch (cmd) {
|
||||
case BIO_CTRL_RESET:
|
||||
num = 0;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case BIO_C_FILE_SEEK:
|
||||
ret = (long)UP_lseek(b->num, num, 0);
|
||||
break;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
/*
|
||||
* Following definition aliases fopen to fopen64 on above mentioned
|
||||
* platforms. This makes it possible to open and sequentially access files
|
||||
* larger than 2GB from 32-bit application. It does not allow to traverse
|
||||
* larger than 2GB from 32-bit application. It does not allow one to traverse
|
||||
* them beyond 2GB with fseek/ftell, but on the other hand *no* 32-bit
|
||||
* platform permits that, not with fseek/ftell. Not to mention that breaking
|
||||
* 2GB limit for seeking would require surgery to *our* API. But sequential
|
||||
|
|
|
@ -115,12 +115,12 @@ BN_ULONG bn_sub_part_words(BN_ULONG *r,
|
|||
r[1] = a[1];
|
||||
if (--dl <= 0)
|
||||
break;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case 2:
|
||||
r[2] = a[2];
|
||||
if (--dl <= 0)
|
||||
break;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case 3:
|
||||
r[3] = a[3];
|
||||
if (--dl <= 0)
|
||||
|
|
|
@ -62,19 +62,19 @@
|
|||
l1=l2=0; \
|
||||
switch (n) { \
|
||||
case 8: l2 =((unsigned long)(*(--(c)))) ; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 7: l2|=((unsigned long)(*(--(c))))<< 8; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 6: l2|=((unsigned long)(*(--(c))))<<16; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 5: l2|=((unsigned long)(*(--(c))))<<24; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 4: l1 =((unsigned long)(*(--(c)))) ; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 3: l1|=((unsigned long)(*(--(c))))<< 8; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 2: l1|=((unsigned long)(*(--(c))))<<16; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 1: l1|=((unsigned long)(*(--(c))))<<24; \
|
||||
} \
|
||||
}
|
||||
|
@ -84,19 +84,19 @@
|
|||
c+=n; \
|
||||
switch (n) { \
|
||||
case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \
|
||||
} \
|
||||
}
|
||||
|
|
|
@ -774,7 +774,7 @@ DEFINE_set1_ASN1_OCTET_STRING(OSSL_CMP_CTX, senderNonce)
|
|||
/* Set the proxy server to use for HTTP(S) connections */
|
||||
DEFINE_OSSL_CMP_CTX_set1(proxy, char)
|
||||
|
||||
/* Set the (HTTP) host name of the CMP server */
|
||||
/* Set the (HTTP) hostname of the CMP server */
|
||||
DEFINE_OSSL_CMP_CTX_set1(server, char)
|
||||
|
||||
/* Set the server exclusion list of the HTTP proxy server */
|
||||
|
|
|
@ -78,7 +78,7 @@ struct ossl_cmp_ctx_st {
|
|||
X509 *cert; /* protection cert used to identify and sign for MSG_SIG_ALG */
|
||||
STACK_OF(X509) *chain; /* (cached) chain of protection cert including it */
|
||||
EVP_PKEY *pkey; /* the key pair corresponding to cert */
|
||||
ASN1_OCTET_STRING *referenceValue; /* optional user name for MSG_MAC_ALG */
|
||||
ASN1_OCTET_STRING *referenceValue; /* optional username for MSG_MAC_ALG */
|
||||
ASN1_OCTET_STRING *secretValue; /* password/shared secret for MSG_MAC_ALG */
|
||||
/* PBMParameters for MSG_MAC_ALG */
|
||||
size_t pbm_slen; /* salt length, currently fixed to 16 */
|
||||
|
|
|
@ -305,7 +305,7 @@ static int cms_cb(int operation, ASN1_VALUE **pval, const ASN1_ITEM *it,
|
|||
case ASN1_OP_STREAM_PRE:
|
||||
if (CMS_stream(&sarg->boundary, cms) <= 0)
|
||||
return 0;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case ASN1_OP_DETACHED_PRE:
|
||||
sarg->ndef_bio = CMS_dataInit(cms, sarg->out);
|
||||
if (!sarg->ndef_bio)
|
||||
|
|
|
@ -37,19 +37,19 @@
|
|||
l1=l2=0; \
|
||||
switch (n) { \
|
||||
case 8: l2 =((DES_LONG)(*(--(c))))<<24L; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 7: l2|=((DES_LONG)(*(--(c))))<<16L; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 6: l2|=((DES_LONG)(*(--(c))))<< 8L; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 5: l2|=((DES_LONG)(*(--(c)))); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 4: l1 =((DES_LONG)(*(--(c))))<<24L; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 3: l1|=((DES_LONG)(*(--(c))))<<16L; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 2: l1|=((DES_LONG)(*(--(c))))<< 8L; \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 1: l1|=((DES_LONG)(*(--(c)))); \
|
||||
} \
|
||||
}
|
||||
|
@ -79,19 +79,19 @@
|
|||
c+=n; \
|
||||
switch (n) { \
|
||||
case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \
|
||||
/* fall thru */ \
|
||||
/* fall through */ \
|
||||
case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \
|
||||
} \
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
*/
|
||||
|
||||
/*
|
||||
* ECDSA low level APIs are deprecated for public use, but still ok for
|
||||
* ECDSA low-level APIs are deprecated for public use, but still ok for
|
||||
* internal use.
|
||||
*/
|
||||
#include "internal/deprecated.h"
|
||||
|
@ -923,7 +923,7 @@ int ec_GF2m_simple_points_mul(const EC_GROUP *group, EC_POINT *r,
|
|||
|
||||
/*-
|
||||
* Computes the multiplicative inverse of a in GF(2^m), storing the result in r.
|
||||
* If a is zero (or equivalent), you'll get a EC_R_CANNOT_INVERT error.
|
||||
* If a is zero (or equivalent), you'll get an EC_R_CANNOT_INVERT error.
|
||||
* SCA hardening is with blinding: BN_GF2m_mod_inv does that.
|
||||
*/
|
||||
static int ec_GF2m_simple_field_inv(const EC_GROUP *group, BIGNUM *r,
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
*/
|
||||
|
||||
/*
|
||||
* ECDSA low level APIs are deprecated for public use, but still ok for
|
||||
* ECDSA low-level APIs are deprecated for public use, but still ok for
|
||||
* internal use.
|
||||
*/
|
||||
#include "internal/deprecated.h"
|
||||
|
@ -217,7 +217,7 @@ int ossl_ec_GFp_mont_field_sqr(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a
|
|||
|
||||
/*-
|
||||
* Computes the multiplicative inverse of a in GF(p), storing the result in r.
|
||||
* If a is zero (or equivalent), you'll get a EC_R_CANNOT_INVERT error.
|
||||
* If a is zero (or equivalent), you'll get an EC_R_CANNOT_INVERT error.
|
||||
* We have a Mont structure, so SCA hardening is FLT inversion.
|
||||
*/
|
||||
int ossl_ec_GFp_mont_field_inv(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a,
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
*/
|
||||
|
||||
/*
|
||||
* ECDSA low level APIs are deprecated for public use, but still ok for
|
||||
* ECDSA low-level APIs are deprecated for public use, but still ok for
|
||||
* internal use.
|
||||
*/
|
||||
#include "internal/deprecated.h"
|
||||
|
@ -1376,7 +1376,7 @@ int ossl_ec_GFp_simple_field_sqr(const EC_GROUP *group, BIGNUM *r, const BIGNUM
|
|||
|
||||
/*-
|
||||
* Computes the multiplicative inverse of a in GF(p), storing the result in r.
|
||||
* If a is zero (or equivalent), you'll get a EC_R_CANNOT_INVERT error.
|
||||
* If a is zero (or equivalent), you'll get an EC_R_CANNOT_INVERT error.
|
||||
* Since we don't have a Mont structure here, SCA hardening is with blinding.
|
||||
* NB: "a" must be in _decoded_ form. (i.e. field_decode must precede.)
|
||||
*/
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
#include "eng_local.h"
|
||||
|
||||
/*
|
||||
* Initialise a engine type for use (or up its functional reference count if
|
||||
* Initialise an engine type for use (or up its functional reference count if
|
||||
* it's already in use). This version is only used internally.
|
||||
*/
|
||||
int engine_unlocked_init(ENGINE *e)
|
||||
|
@ -41,7 +41,7 @@ int engine_unlocked_init(ENGINE *e)
|
|||
}
|
||||
|
||||
/*
|
||||
* Free a functional reference to a engine type. This version is only used
|
||||
* Free a functional reference to an engine type. This version is only used
|
||||
* internally.
|
||||
*/
|
||||
int engine_unlocked_finish(ENGINE *e, int unlock_for_handlers)
|
||||
|
|
|
@ -2483,7 +2483,7 @@ lookup_translation(struct translation_st *tmpl,
|
|||
tmpl->ctrl_hexstr = ctrl_hexstr;
|
||||
} else if (tmpl->param_key != NULL) {
|
||||
/*
|
||||
* Search criteria that originates from a OSSL_PARAM setter or
|
||||
* Search criteria that originates from an OSSL_PARAM setter or
|
||||
* getter.
|
||||
*
|
||||
* Ctrls were fundamentally bidirectional, with only the ctrl
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
*/
|
||||
|
||||
/*
|
||||
* This file uses the low level AES functions (which are deprecated for
|
||||
* This file uses the low-level AES functions (which are deprecated for
|
||||
* non-internal use) in order to implement the EVP AES ciphers.
|
||||
*/
|
||||
#include "internal/deprecated.h"
|
||||
|
@ -3434,7 +3434,7 @@ static int aes_ccm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr)
|
|||
|
||||
case EVP_CTRL_AEAD_SET_IVLEN:
|
||||
arg = 15 - arg;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case EVP_CTRL_CCM_SET_L:
|
||||
if (arg < 2 || arg > 8)
|
||||
return 0;
|
||||
|
@ -4013,7 +4013,7 @@ static int aes_ocb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
|
|||
|
||||
if (in != NULL) {
|
||||
/*
|
||||
* Need to ensure we are only passing full blocks to low level OCB
|
||||
* Need to ensure we are only passing full blocks to low-level OCB
|
||||
* routines. We do it here rather than in EVP_EncryptUpdate/
|
||||
* EVP_DecryptUpdate because we need to pass full blocks of AAD too
|
||||
* and those routines don't support that
|
||||
|
|
|
@ -589,7 +589,7 @@ static int aria_ccm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr)
|
|||
|
||||
case EVP_CTRL_AEAD_SET_IVLEN:
|
||||
arg = 15 - arg;
|
||||
/* fall thru */
|
||||
/* fall through */
|
||||
case EVP_CTRL_CCM_SET_L:
|
||||
if (arg < 2 || arg > 8)
|
||||
return 0;
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
/*
|
||||
* Following definition aliases fopen to fopen64 on above mentioned
|
||||
* platforms. This makes it possible to open and sequentially access files
|
||||
* larger than 2GB from 32-bit application. It does not allow to traverse
|
||||
* larger than 2GB from 32-bit application. It does not allow one to traverse
|
||||
* them beyond 2GB with fseek/ftell, but on the other hand *no* 32-bit
|
||||
* platform permits that, not with fseek/ftell. Not to mention that breaking
|
||||
* 2GB limit for seeking would require surgery to *our* API. But sequential
|
||||
|
|
Loading…
Reference in New Issue