Skip to content

Commit 5036187

Browse files
authored
Merge pull request #101 from aidangarske/codespell-workflow
codespell.yml - CI github workflow
2 parents 585c054 + b4bfb05 commit 5036187

30 files changed

+112
-65
lines changed

.github/workflows/codespell.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Codespell test
2+
3+
# START OF COMMON SECTION
4+
on:
5+
push:
6+
branches: [ 'master', 'main', 'release/**' ]
7+
pull_request:
8+
branches: [ '*' ]
9+
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.ref }}
12+
cancel-in-progress: true
13+
# END OF COMMON SECTION
14+
15+
jobs:
16+
codespell:
17+
name: Check for spelling errors
18+
runs-on: ubuntu-22.04
19+
timeout-minutes: 5
20+
steps:
21+
- name: Checkout wolfProvider
22+
uses: actions/checkout@v4
23+
24+
- name: Create exclude file if needed
25+
run: |
26+
if [ ! -f .codespellexcludelines ]; then
27+
touch .codespellexcludelines
28+
fi
29+
30+
- name: Run codespell
31+
uses: codespell-project/[email protected]
32+
with:
33+
check_filenames: true
34+
check_hidden: true
35+
# Add comma separated list of words that occur multiple times that should be ignored (sorted alphabetically, case sensitive)
36+
ignore_words_list: adin,addIn,aNULL,brunch,carryIn,chainG,ciph,cLen,cliKs,dout,emac,haveA,inCreated,inOut,inout,larg,LEAPYEAR,Merget,optionA,parm,parms,repid,rIn,userA,ser,siz,te,Te,toLen
37+
# The exclude_file contains lines of code that should be ignored. This is useful for individual lines which have non-words that can safely be ignored.
38+
exclude_file: '.codespellexcludelines'
39+
# To skip files entirely from being processed, add it to the following list:
40+
skip: '*.cproject,*.der,*.mtpj,*.pem,*.vcxproj,.git,*.launch,*.scfg,*.revoked,*.txt'
41+
42+
- name: Print errors
43+
if: ${{ failure() }}
44+
run: |
45+
if [ -f test-suite.log ] ; then
46+
cat test-suite.log
47+
fi

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ The quickest method is to use the `scripts/build-wolfprovider.sh` script as foll
5656
./scripts/build-wolfprovider.sh
5757
```
5858

59-
It will retreive the dependencies and compile them as necessary. To use other than the default (such as different releases) you can set various environment variables prior to calling the script:
59+
It will retrieve the dependencies and compile them as necessary. To use other than the default (such as different releases) you can set various environment variables prior to calling the script:
6060

6161
```
6262
OPENSSL_TAG=openssl-3.2.0 WOLFSSL_TAG=v5.7.2-stable WOLFPROV_DEBUG=1 scripts/build-wolfprovider.sh

autogen.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# autogen.sh
44
#
5-
# Create configure and makfile stuff...
5+
# Create configure and makefile stuff...
66
#
77

88
autoreconf --install --force --verbose

include/wolfprovider/internal.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@
103103
#define WP_RSA_DEFAULT_SALT_LEN 20
104104

105105
/* These values are taken from ssl.h.
106-
* Can't include this header as it re-declares OpenSSL types.
106+
* Can't include this header as it redeclares OpenSSL types.
107107
*/
108108
/* Named Groups */
109109
enum {

src/wp_aes_aead.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ typedef struct wp_AeadCtx {
6767
/** Current state of IV/nonce. */
6868
int ivState;
6969

70-
/** Initialized for encrpytion or decryption. */
70+
/** Initialized for encryption or decryption. */
7171
unsigned int enc:1;
7272
/** IV/nonce has been generated. */
7373
unsigned int ivGen:1;
@@ -263,7 +263,7 @@ static int wp_aead_tls_init(wp_AeadCtx* ctx, unsigned char* aad, size_t aadLen)
263263
*
264264
* @param [in, out] ctx AEAD context object.
265265
* @param [in] in More AAD data.
266-
* @parma [in] inLen Length of new AAD data.
266+
* @param [in] inLen Length of new AAD data.
267267
* @return 1 on success.
268268
* @return 0 on failure.
269269
*/
@@ -299,7 +299,7 @@ static int wp_aead_cache_aad(wp_AeadCtx *ctx, const unsigned char *in,
299299
*
300300
* @param [in, out] ctx AEAD context object.
301301
* @param [in] in More AAD data.
302-
* @parma [in] inLen Length of new AAD data.
302+
* @param [in] inLen Length of new AAD data.
303303
* @return 1 on success.
304304
* @return 0 on failure.
305305
*/

src/wp_aes_block.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -813,7 +813,7 @@ static int wp_aes_block_set_ctx_params(wp_AesBlockCtx *ctx,
813813
* @param [in, out] ctx AES block context object.
814814
* @param [in] kBits Number of bits in a valid key.
815815
* @param [in] ivBits Number of bits in a valid IV. 0 indicates no IV.
816-
* @parma [in] mode AES block mode: ECB or CBC.
816+
* @param [in] mode AES block mode: ECB or CBC.
817817
* @return 1 on success.
818818
* @return 0 on failure.
819819
*/

src/wp_aes_stream.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ static int wp_aes_stream_doit(wp_AesStreamCtx *ctx, unsigned char *out,
381381
#ifdef WP_HAVE_AESCFB
382382
if (ctx->mode == EVP_CIPH_CFB_MODE) {
383383
int rc;
384-
384+
385385
XMEMCPY(&ctx->aes.reg, ctx->iv, ctx->ivLen);
386386
if (ctx->enc) {
387387
rc = wc_AesCfbEncrypt(&ctx->aes, out, in, (word32)inLen);
@@ -578,7 +578,7 @@ static int wp_aes_stream_set_ctx_params(wp_AesStreamCtx *ctx,
578578
* @param [in, out] ctx AES stream context object.
579579
* @param [in] kBits Number of bits in a valid key.
580580
* @param [in] ivBits Number of bits in a valid IV. 0 indicates no IV.
581-
* @parma [in] mode AES stream mode: CTR.
581+
* @param [in] mode AES stream mode: CTR.
582582
* @return 1 on success.
583583
* @return 0 on failure.
584584
*/

src/wp_cmac.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ static int wp_cmac_init(wp_CmacCtx* macCtx, const unsigned char* key,
208208
* Update the MAC state with data.
209209
*
210210
* @param [in, out] macCtx CMAC context object to update.
211-
* @parma [in] data Data to be MACed.
211+
* @param [in] data Data to be MACed.
212212
* @param [in] dataLen Length of data in bytes.
213213
* @return 1 on success.
214214
* @return 0 on failure.

src/wp_des.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -778,7 +778,7 @@ static int wp_des3_block_set_ctx_params(wp_Des3BlockCtx *ctx,
778778
* @param [in, out] ctx DES3 block context object.
779779
* @param [in] kBits Number of bits in a valid key.
780780
* @param [in] ivBits Number of bits in a valid IV. 0 indicates no IV.
781-
* @parma [in] mode DES3 block mode: ECB or CBC.
781+
* @param [in] mode DES3 block mode: ECB or CBC.
782782
* @return 1 on success.
783783
* @return 0 on failure.
784784
*/

src/wp_dh_exch.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ static int wp_dh_derive_secret(wp_DhCtx* ctx, unsigned char* secret,
306306
* Can put the DH secret through a KDF.
307307
*
308308
* @param [in] ctx DH key exchange context object.
309-
* @param [out] secert Buffer to hold secret/key.
309+
* @param [out] secret Buffer to hold secret/key.
310310
* @param [out] secLen Length of secret/key data in bytes.
311311
* @param [in] secSize Size of buffer in bytes.
312312
* @return 1 on success.

0 commit comments

Comments
 (0)