@@ -21,7 +21,7 @@ Private keys can be generated in multiple ways. The example below illustrates
21
21
use of the OpenSSL command-line interface to generate a 2048-bit RSA private
22
22
key:
23
23
24
- ``` sh
24
+ ``` bash
25
25
openssl genrsa -out ryans-key.pem 2048
26
26
```
27
27
@@ -35,7 +35,7 @@ step to obtaining a certificate is to create a *Certificate Signing Request*
35
35
The OpenSSL command-line interface can be used to generate a CSR for a private
36
36
key:
37
37
38
- ``` sh
38
+ ``` bash
39
39
openssl req -new -sha256 -key ryans-key.pem -out ryans-csr.pem
40
40
```
41
41
@@ -45,14 +45,14 @@ Authority for signing or used to generate a self-signed certificate.
45
45
Creating a self-signed certificate using the OpenSSL command-line interface
46
46
is illustrated in the example below:
47
47
48
- ``` sh
48
+ ``` bash
49
49
openssl x509 -req -in ryans-csr.pem -signkey ryans-key.pem -out ryans-cert.pem
50
50
```
51
51
52
52
Once the certificate is generated, it can be used to generate a ` .pfx ` or
53
53
` .p12 ` file:
54
54
55
- ``` sh
55
+ ``` bash
56
56
openssl pkcs12 -export -in ryans-cert.pem -inkey ryans-key.pem \
57
57
-certfile ca-cert.pem -out ryans.pfx
58
58
```
@@ -95,7 +95,7 @@ to generate Diffie-Hellman parameters and specify them with the `dhparam`
95
95
option to [ ` tls.createSecureContext() ` ] [ ] . The following illustrates the use of
96
96
the OpenSSL command-line interface to generate such parameters:
97
97
98
- ``` sh
98
+ ``` bash
99
99
openssl dhparam -outform PEM -out dhparam.pem 2048
100
100
```
101
101
@@ -250,7 +250,7 @@ failures, it is easy to not notice unnecessarily poor TLS performance. The
250
250
OpenSSL CLI can be used to verify that servers are resuming sessions. Use the
251
251
` -reconnect ` option to ` openssl s_client ` , for example:
252
252
253
- ``` sh
253
+ ``` console
254
254
$ openssl s_client -connect localhost:443 -reconnect
255
255
```
256
256
@@ -304,7 +304,7 @@ line switch (directly, or via the [`NODE_OPTIONS`][] environment variable). For
304
304
instance, the following makes ` ECDHE-RSA-AES128-GCM-SHA256:!RC4 ` the default TLS
305
305
cipher suite:
306
306
307
- ``` sh
307
+ ``` bash
308
308
node --tls-cipher-list=" ECDHE-RSA-AES128-GCM-SHA256:!RC4" server.js
309
309
310
310
export NODE_OPTIONS=--tls-cipher-list=" ECDHE-RSA-AES128-GCM-SHA256:!RC4"
0 commit comments