forked from wolfSSL/wolfssl
Merge pull request #6454 from philljj/spelling_cleanup
Used codespell and fixed obvious typos in src and wolfssl.
This commit is contained in:
@ -33335,7 +33335,7 @@ static int DoSessionTicket(WOLFSSL* ssl, const byte* input, word32* inOutIdx,
|
|||||||
if (alertType != invalid_alert) {
|
if (alertType != invalid_alert) {
|
||||||
int err;
|
int err;
|
||||||
|
|
||||||
/* propogate socket errors to avoid re-calling send alert */
|
/* propagate socket errors to avoid re-calling send alert */
|
||||||
err = SendAlert(ssl, alert_fatal, alertType);
|
err = SendAlert(ssl, alert_fatal, alertType);
|
||||||
if (err == SOCKET_ERROR_E)
|
if (err == SOCKET_ERROR_E)
|
||||||
ret = SOCKET_ERROR_E;
|
ret = SOCKET_ERROR_E;
|
||||||
@ -34871,7 +34871,7 @@ static int DoSessionTicket(WOLFSSL* ssl, const byte* input, word32* inOutIdx,
|
|||||||
byte bogusID[ID_LEN];
|
byte bogusID[ID_LEN];
|
||||||
byte bogusIDSz = ssl->session->sessionIDSz;
|
byte bogusIDSz = ssl->session->sessionIDSz;
|
||||||
XMEMCPY(bogusID, ssl->session->sessionID, ID_LEN);
|
XMEMCPY(bogusID, ssl->session->sessionID, ID_LEN);
|
||||||
/* Failure here should not interupt the resumption. We already have
|
/* Failure here should not interrupt the resumption. We already have
|
||||||
* all the cipher material we need in `it` */
|
* all the cipher material we need in `it` */
|
||||||
WOLFSSL_MSG("Copying in session from passed in arg");
|
WOLFSSL_MSG("Copying in session from passed in arg");
|
||||||
(void)wolfSSL_DupSession(sess, ssl->session, 1);
|
(void)wolfSSL_DupSession(sess, ssl->session, 1);
|
||||||
|
@ -2382,7 +2382,7 @@ char* wolfSSL_i2s_ASN1_STRING(WOLFSSL_v3_ext_method *method,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
/* Convert unreadable strings to hexdecimal. */
|
/* Convert unreadable strings to hexadecimal. */
|
||||||
ret = wolfssl_asn1_string_to_hex_chars(s);
|
ret = wolfssl_asn1_string_to_hex_chars(s);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2833,7 +2833,7 @@ static int wolfssl_asn1_string_dump_hex(WOLFSSL_BIO *bio,
|
|||||||
/* Calculate end of string. */
|
/* Calculate end of string. */
|
||||||
end = str->data + str->length - 1;
|
end = str->data + str->length - 1;
|
||||||
for (p = str->data; p <= end; p++) {
|
for (p = str->data; p <= end; p++) {
|
||||||
/* Encode string characther as hex into temporary. */
|
/* Encode string character as hex into temporary. */
|
||||||
ByteToHexStr((byte)*p, hex_tmp);
|
ByteToHexStr((byte)*p, hex_tmp);
|
||||||
/* Update count of written characters. */
|
/* Update count of written characters. */
|
||||||
str_len += 2;
|
str_len += 2;
|
||||||
@ -2853,7 +2853,7 @@ static int wolfssl_asn1_string_dump_hex(WOLFSSL_BIO *bio,
|
|||||||
* @param [in] c Character to check for.
|
* @param [in] c Character to check for.
|
||||||
* @param [in] str String to check.
|
* @param [in] str String to check.
|
||||||
* @return 1 when character found.
|
* @return 1 when character found.
|
||||||
* @return 0 when characther not found.
|
* @return 0 when character not found.
|
||||||
*/
|
*/
|
||||||
static int wolfssl_check_esc_char(char c)
|
static int wolfssl_check_esc_char(char c)
|
||||||
{
|
{
|
||||||
|
@ -1777,7 +1777,7 @@ int wolfSSL_BN_mod_add(WOLFSSL_BIGNUM *r, const WOLFSSL_BIGNUM *a,
|
|||||||
ret = 0;
|
ret = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Perfom operation with wolfCrypt. */
|
/* Perform operation with wolfCrypt. */
|
||||||
if ((ret == 1) && (mp_addmod((mp_int*)a->internal, (mp_int*)b->internal,
|
if ((ret == 1) && (mp_addmod((mp_int*)a->internal, (mp_int*)b->internal,
|
||||||
(mp_int*)m->internal, (mp_int*)r->internal) != MP_OKAY)) {
|
(mp_int*)m->internal, (mp_int*)r->internal) != MP_OKAY)) {
|
||||||
WOLFSSL_MSG("mp_add_d error");
|
WOLFSSL_MSG("mp_add_d error");
|
||||||
@ -1973,7 +1973,7 @@ int wolfSSL_BN_gcd(WOLFSSL_BIGNUM* r, WOLFSSL_BIGNUM* a, WOLFSSL_BIGNUM* b,
|
|||||||
* @param [in] top Whether top bits must be set.
|
* @param [in] top Whether top bits must be set.
|
||||||
* Valid values: WOLFSSL_BN_RAND_TOP_ANY,
|
* Valid values: WOLFSSL_BN_RAND_TOP_ANY,
|
||||||
* WOLFSSL_BN_RAND_TOP_ONE, WOLFSSL_BN_RAND_TOP_TWO.
|
* WOLFSSL_BN_RAND_TOP_ONE, WOLFSSL_BN_RAND_TOP_TWO.
|
||||||
* @param [in] botttom Whether bottom bit must be set.
|
* @param [in] bottom Whether bottom bit must be set.
|
||||||
* Valid values: WOLFSSL_BN_RAND_BOTTOM_ANY,
|
* Valid values: WOLFSSL_BN_RAND_BOTTOM_ANY,
|
||||||
WOLFSSL_BN_RAND_BOTTOM_ODD.
|
WOLFSSL_BN_RAND_BOTTOM_ODD.
|
||||||
* @return 1 on success.
|
* @return 1 on success.
|
||||||
@ -2081,7 +2081,7 @@ int wolfSSL_BN_rand(WOLFSSL_BIGNUM* bn, int bits, int top, int bottom)
|
|||||||
* @param [in] top Whether top bits must be set.
|
* @param [in] top Whether top bits must be set.
|
||||||
* Valid values: WOLFSSL_BN_RAND_TOP_ANY,
|
* Valid values: WOLFSSL_BN_RAND_TOP_ANY,
|
||||||
* WOLFSSL_BN_RAND_TOP_ONE, WOLFSSL_BN_RAND_TOP_TWO.
|
* WOLFSSL_BN_RAND_TOP_ONE, WOLFSSL_BN_RAND_TOP_TWO.
|
||||||
* @param [in] botttom Whether bottom bit must be set.
|
* @param [in] bottom Whether bottom bit must be set.
|
||||||
* Valid values: WOLFSSL_BN_RAND_BOTTOM_ANY,
|
* Valid values: WOLFSSL_BN_RAND_BOTTOM_ANY,
|
||||||
WOLFSSL_BN_RAND_BOTTOM_ODD.
|
WOLFSSL_BN_RAND_BOTTOM_ODD.
|
||||||
* @return 1 on success.
|
* @return 1 on success.
|
||||||
|
@ -2165,7 +2165,7 @@ static void AddTls13HandShakeHeader(byte* output, word32 length,
|
|||||||
(void)ssl;
|
(void)ssl;
|
||||||
|
|
||||||
#ifdef WOLFSSL_DTLS13
|
#ifdef WOLFSSL_DTLS13
|
||||||
/* message_hash type is used for a syntetic message that replaces the first
|
/* message_hash type is used for a synthetic message that replaces the first
|
||||||
ClientHello in the hash transcript when using HelloRetryRequest. It will
|
ClientHello in the hash transcript when using HelloRetryRequest. It will
|
||||||
never be transmitted and, as the DTLS-only fields must not be considered
|
never be transmitted and, as the DTLS-only fields must not be considered
|
||||||
when computing the hash transcript, we can avoid to use the DTLS
|
when computing the hash transcript, we can avoid to use the DTLS
|
||||||
|
@ -57,7 +57,7 @@ Possible IO enable options:
|
|||||||
* indefinetely. If not enabled EmbedReceiveFrom will return timeout after
|
* indefinetely. If not enabled EmbedReceiveFrom will return timeout after
|
||||||
* DTLS_RECEIVEFROM_MAX_INVALID_PEER number of packets from invalid peers. When
|
* DTLS_RECEIVEFROM_MAX_INVALID_PEER number of packets from invalid peers. When
|
||||||
* enabled, without a timer, EmbedReceivefrom can't check if the timeout is
|
* enabled, without a timer, EmbedReceivefrom can't check if the timeout is
|
||||||
* expired and it may never return under a continous flow of invalid packets.
|
* expired and it may never return under a continuous flow of invalid packets.
|
||||||
* default: off
|
* default: off
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -9500,7 +9500,7 @@ WOLF_STACK_OF(WOLFSSL_X509)* wolfSSL_X509_chain_up_ref(
|
|||||||
|
|
||||||
if (ret == WOLFSSL_SUCCESS) {
|
if (ret == WOLFSSL_SUCCESS) {
|
||||||
for (idx = 0; idx < req->customExtCount; idx++) {
|
for (idx = 0; idx < req->customExtCount; idx++) {
|
||||||
/* Note that ownership is NOT transfered.
|
/* Note that ownership is NOT transferred.
|
||||||
* req->custom_exts buffers still need to be cleaned
|
* req->custom_exts buffers still need to be cleaned
|
||||||
* up. */
|
* up. */
|
||||||
cert->customCertExt[idx] = req->custom_exts[idx];
|
cert->customCertExt[idx] = req->custom_exts[idx];
|
||||||
|
@ -3182,7 +3182,7 @@ typedef struct KeyShareEntry {
|
|||||||
byte* pubKey; /* Public key */
|
byte* pubKey; /* Public key */
|
||||||
word32 pubKeyLen; /* Public key length */
|
word32 pubKeyLen; /* Public key length */
|
||||||
#if !defined(NO_DH) || defined(HAVE_PQC)
|
#if !defined(NO_DH) || defined(HAVE_PQC)
|
||||||
byte* privKey; /* Private key - DH ond PQ KEMs only */
|
byte* privKey; /* Private key - DH and PQ KEMs only */
|
||||||
#endif
|
#endif
|
||||||
#ifdef WOLFSSL_ASYNC_CRYPT
|
#ifdef WOLFSSL_ASYNC_CRYPT
|
||||||
int lastRet;
|
int lastRet;
|
||||||
|
@ -3767,7 +3767,7 @@ static WC_INLINE int myEccSharedSecret(WOLFSSL* ssl, ecc_key* otherKey,
|
|||||||
#endif
|
#endif
|
||||||
pubKey = otherKey;
|
pubKey = otherKey;
|
||||||
|
|
||||||
/* TLS v1.2 and older we must generate a key here for the client ony.
|
/* TLS v1.2 and older we must generate a key here for the client only.
|
||||||
* TLS v1.3 calls key gen early with key share */
|
* TLS v1.3 calls key gen early with key share */
|
||||||
if (wolfSSL_GetVersion(ssl) < WOLFSSL_TLSV1_3) {
|
if (wolfSSL_GetVersion(ssl) < WOLFSSL_TLSV1_3) {
|
||||||
ret = myEccKeyGen(ssl, privKey, 0, otherKey->dp->id, ctx);
|
ret = myEccKeyGen(ssl, privKey, 0, otherKey->dp->id, ctx);
|
||||||
|
@ -985,7 +985,7 @@ typedef struct Asn1 {
|
|||||||
Asn1Item item;
|
Asn1Item item;
|
||||||
/* Current depth of ASN.1 item. */
|
/* Current depth of ASN.1 item. */
|
||||||
unsigned char depth;
|
unsigned char depth;
|
||||||
/* End indeces of ASN.1 items at different depths. */
|
/* End indices of ASN.1 items at different depths. */
|
||||||
word32 end_idx[ASN_MAX_DEPTH];
|
word32 end_idx[ASN_MAX_DEPTH];
|
||||||
|
|
||||||
/* Buffer to print. */
|
/* Buffer to print. */
|
||||||
|
@ -1855,7 +1855,7 @@ extern void uITRON4_free(void *p) ;
|
|||||||
#define WOLFSSL_CAAM_HASH
|
#define WOLFSSL_CAAM_HASH
|
||||||
#endif
|
#endif
|
||||||
#if defined(WOLFSSL_DEVCRYPTO_HMAC)
|
#if defined(WOLFSSL_DEVCRYPTO_HMAC)
|
||||||
/* HMAC is throught the devcrypto calls */
|
/* HMAC is through the devcrypto calls */
|
||||||
#define WOLFSSL_CAAM_HMAC
|
#define WOLFSSL_CAAM_HMAC
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user