Skip to content

Commit 44bac49

Browse files
Merge pull request #189 from lealem47/cluAdditions
Adding wolfCLU pkcs8, pkcs7 and base64 command docs
2 parents 1c54550 + 267f2b8 commit 44bac49

File tree

6 files changed

+73
-2
lines changed

6 files changed

+73
-2
lines changed

wolfCLU/Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,17 @@ SOURCES = Intro.md \
1818
hash.md \
1919
md5.md \
2020
pkcs12.md \
21+
pkcs7.md \
22+
pkcs8.md \
2123
pkey.md \
2224
rand.md \
2325
req.md \
2426
rsa.md \
2527
sha.md \
2628
s_client.md \
2729
verify.md \
28-
x509.md
30+
x509.md \
31+
base64.md
2932

3033
ifeq ($(DOC_LANG),JA)
3134
PDF = wolfCLU-Manual-jp.pdf

wolfCLU/src/base64.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
### BASE64 Command
2+
3+
Encodes or decodes data using base64 encoding. By default, data is encoded to base64. Use the -d option to decode base64 data.
4+
5+
- [-in] input file to read from (default stdin)
6+
- [-out] output file to write to (default stdout)
7+
- [-d] decode the input data instead of encoding
8+
9+
Example for encoding:
10+
11+
```
12+
wolfssl base64 -in plain_file.txt -out encoded_file.txt
13+
```
14+
15+
Example for decoding:
16+
17+
```
18+
wolfssl base64 -d -in encoded_file.txt -out decoded_file.txt
19+
```

wolfCLU/src/command_list.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
## List Of Commands:
2+
- base64
23
- bench
34
- ca
45
- crl
@@ -10,6 +11,8 @@
1011
- hash
1112
- md5
1213
- pkcs12
14+
- pkcs7
15+
- pkcs8
1316
- pkey
1417
- rand
1518
- req

wolfCLU/src/pkcs7.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
### PKCS7 Command
2+
3+
Processes PKCS#7 data, allowing operations such as extracting certificates from PKCS#7 files. PKCS#7 is a standard for cryptographically signed and/or encrypted data.
4+
5+
- [-in] input file containing PKCS#7 data (required)
6+
- [-out] output file to write results to (default stdout)
7+
- [-inform] input format (PEM or DER, default PEM)
8+
- [-outform] output format (PEM or DER, default PEM)
9+
- [-print_certs] extract and output certificates from the PKCS#7 file
10+
11+
Example for extracting certificates from a PKCS#7 file:
12+
13+
```
14+
wolfssl pkcs7 -in pkcs7.pem -print_certs
15+
```
16+
17+
Example for converting PKCS#7 data from PEM to DER format:
18+
19+
```
20+
wolfssl pkcs7 -in pkcs7.pem -outform DER -out pkcs7.der
21+
```

wolfCLU/src/pkcs8.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
### PKCS8 Command
2+
3+
Processes PKCS#8 private key files. Allows conversion between different formats (PEM/DER) and decryption of private keys. Encrypting PKCS#8 keys is not yet supported.
4+
5+
- [-in] input file containing the private key (required)
6+
- [-out] output file to write the processed key to (default stdout)
7+
- [-inform] input format (PEM or DER, default PEM)
8+
- [-outform] output format (PEM or DER, default PEM)
9+
- [-passin] password source for encrypted input key
10+
- [-traditional] output key in traditional (non-PKCS#8) format
11+
- [-topk8] convert input to PKCS#8 format
12+
- [-nocrypt] don't encrypt the output key (no password)
13+
14+
Example for converting an encrypted PEM key to DER format:
15+
16+
```
17+
wolfssl pkcs8 -in server-keyEnc.pem -passin pass:mypassword -outform DER -out key.der
18+
```
19+
20+
Example for converting a key to traditional format:
21+
22+
```
23+
wolfssl pkcs8 -in server-key.pem -traditional -out traditional-key.pem
24+
```

wolfCLU/src/verify.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@ Verifies an X509 certificate given a CA. The last argument passed into the comma
33

44
- [-CAfile] file name for CA to be used with verify
55
- [-crl_check] if CRL checking should be used
6+
- [-untrusted] file name for intermediate certificate to be used in verification (only one -untrusted cert is currently supported)
67

78
Example:
89

910
```
1011
wolfssl verify -CAfile ./certs/ca-cert.pem ./certs/server-cert.pem
11-
```
12+
```

0 commit comments

Comments
 (0)