Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit aa1e0bc

Browse filesBrowse files
panvaaduh95
authored andcommitted
doc: fix typos and inconsistencies in crypto.md and webcrypto.md
Signed-off-by: Filip Skokan <panva.ip@gmail.com> PR-URL: #62828 Backport-PR-URL: #63173 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
1 parent 341947e commit aa1e0bc
Copy full SHA for aa1e0bc

2 files changed

+20-20Lines changed: 20 additions & 20 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎doc/api/crypto.md‎

Copy file name to clipboardExpand all lines: doc/api/crypto.md
+4-4Lines changed: 4 additions & 4 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -1172,7 +1172,7 @@ changes:
11721172
* `options` {Object} [`stream.transform` options][]
11731173
* `plaintextLength` {number}
11741174
* `encoding` {string} String encoding to use when `buffer` is a string.
1175-
* Returns: {Decipheriv} The same Decipher for method chaining.
1175+
* Returns: {Decipheriv} The same `Decipheriv` instance for method chaining.
11761176

11771177
When using an authenticated encryption mode (`GCM`, `CCM`, `OCB`, and
11781178
`chacha20-poly1305` are
@@ -1214,7 +1214,7 @@ changes:
12141214

12151215
* `buffer` {string|Buffer|ArrayBuffer|TypedArray|DataView}
12161216
* `encoding` {string} String encoding to use when `buffer` is a string.
1217-
* Returns: {Decipheriv} The same Decipher for method chaining.
1217+
* Returns: {Decipheriv} The same `Decipheriv` instance for method chaining.
12181218

12191219
When using an authenticated encryption mode (`GCM`, `CCM`, `OCB`, and
12201220
`chacha20-poly1305` are
@@ -1249,7 +1249,7 @@ added: v0.7.1
12491249
-->
12501250

12511251
* `autoPadding` {boolean} **Default:** `true`
1252-
* Returns: {Decipheriv} The same Decipher for method chaining.
1252+
* Returns: {Decipheriv} The same `Decipheriv` instance for method chaining.
12531253

12541254
When data has been encrypted without standard block padding, calling
12551255
`decipher.setAutoPadding(false)` will disable automatic padding to prevent
@@ -5305,7 +5305,7 @@ changes:
53055305

53065306
<!--lint enable maximum-line-length remark-lint-->
53075307

5308-
Decrypts `buffer` with `key`.`buffer` was previously encrypted using
5308+
Decrypts `buffer` with `key`. `buffer` was previously encrypted using
53095309
the corresponding private key, for example using [`crypto.privateEncrypt()`][].
53105310

53115311
If `key` is not a [`KeyObject`][], this function behaves as if
Collapse file

‎doc/api/webcrypto.md‎

Copy file name to clipboardExpand all lines: doc/api/webcrypto.md
+16-16Lines changed: 16 additions & 16 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -504,8 +504,8 @@ const decrypted = new TextDecoder().decode(await crypto.subtle.decrypt(
504504
505505
## Algorithm matrix
506506
507-
The tables details the algorithms supported by the Node.js Web Crypto API
508-
implementation and the APIs supported for each:
507+
The following tables detail the algorithms supported by the Node.js Web
508+
Crypto API implementation and the APIs supported for each:
509509
510510
### Key Management APIs
511511
@@ -742,7 +742,7 @@ Valid key usages depend on the key algorithm (identified by
742742
| `'ECDSA'` | | ✔ | | | |
743743
| `'Ed25519'` | | ✔ | | | |
744744
| `'Ed448'`[^secure-curves] | | ✔ | | | |
745-
| `'HDKF'` | | | ✔ | | |
745+
| `'HKDF'` | | | ✔ | | |
746746
| `'HMAC'` | | ✔ | | | |
747747
| `'KMAC128'`[^modern-algos] | | ✔ | | | |
748748
| `'KMAC256'`[^modern-algos] | | ✔ | | | |
@@ -979,7 +979,7 @@ a new {CryptoKey} based on the method and parameters in `derivedKeyAlgorithm`.
979979
980980
Calling this method is equivalent to calling [`subtle.deriveBits()`][] to
981981
generate raw keying material, then passing the result into the
982-
[`subtle.importKey()`][] method using the `deriveKeyAlgorithm`, `extractable`, and
982+
[`subtle.importKey()`][] method using the `derivedKeyAlgorithm`, `extractable`, and
983983
`keyUsages` parameters as input.
984984
985985
The algorithms currently supported include:
@@ -1325,7 +1325,7 @@ The algorithms currently supported include:
13251325
| `'ECDSA'` | ✔ | ✔ | ✔ | ✔ | | ✔ | |
13261326
| `'Ed25519'` | ✔ | ✔ | ✔ | ✔ | | ✔ | |
13271327
| `'Ed448'`[^secure-curves] | ✔ | ✔ | ✔ | ✔ | | ✔ | |
1328-
| `'HDKF'` | | | | ✔ | ✔ | | |
1328+
| `'HKDF'` | | | | ✔ | ✔ | | |
13291329
| `'HMAC'` | | | ✔ | ✔ | ✔ | | |
13301330
| `'KMAC128'`[^modern-algos] | | | ✔ | | ✔ | | |
13311331
| `'KMAC256'`[^modern-algos] | | | ✔ | | ✔ | | |
@@ -1449,14 +1449,14 @@ The unwrapped key algorithms supported include:
14491449
* `'Ed25519'`
14501450
* `'Ed448'`[^secure-curves]
14511451
* `'HMAC'`
1452-
* `'KMAC128'`[^secure-curves]
1453-
* `'KMAC256'`[^secure-curves]
1452+
* `'KMAC128'`[^modern-algos]
1453+
* `'KMAC256'`[^modern-algos]
14541454
* `'ML-DSA-44'`[^modern-algos]
14551455
* `'ML-DSA-65'`[^modern-algos]
14561456
* `'ML-DSA-87'`[^modern-algos]
14571457
* `'ML-KEM-512'`[^modern-algos]
14581458
* `'ML-KEM-768'`[^modern-algos]
1459-
* `'ML-KEM-1024'`[^modern-algos]v
1459+
* `'ML-KEM-1024'`[^modern-algos]
14601460
* `'RSA-OAEP'`
14611461
* `'RSA-PSS'`
14621462
* `'RSASSA-PKCS1-v1_5'`
@@ -1502,8 +1502,8 @@ The algorithms currently supported include:
15021502
* `'Ed25519'`
15031503
* `'Ed448'`[^secure-curves]
15041504
* `'HMAC'`
1505-
* `'KMAC128'`[^secure-curves]
1506-
* `'KMAC256'`[^secure-curves]
1505+
* `'KMAC128'`[^modern-algos]
1506+
* `'KMAC256'`[^modern-algos]
15071507
* `'ML-DSA-44'`[^modern-algos]
15081508
* `'ML-DSA-65'`[^modern-algos]
15091509
* `'ML-DSA-87'`[^modern-algos]
@@ -1850,7 +1850,7 @@ added: v24.7.0
18501850
added: v24.7.0
18511851
-->
18521852
1853-
* Type: {string} Must be `Ed448`[^secure-curves], `'ML-DSA-44'`[^modern-algos],
1853+
* Type: {string} Must be `'Ed448'`[^secure-curves], `'ML-DSA-44'`[^modern-algos],
18541854
`'ML-DSA-65'`[^modern-algos], or `'ML-DSA-87'`[^modern-algos].
18551855
18561856
#### `contextParams.context`
@@ -1884,7 +1884,7 @@ changes:
18841884
added: v24.7.0
18851885
-->
18861886
1887-
* Type: {string} Must be `'cSHAKE128'`[^modern-algos] or `'cSHAKE256'`[^modern-algos]
1887+
* Type: {string} Must be `'cSHAKE128'`[^modern-algos] or `'cSHAKE256'`[^modern-algos].
18881888
18891889
#### `cShakeParams.outputLength`
18901890
@@ -1902,7 +1902,7 @@ added: v24.7.0
19021902
19031903
* Type: {ArrayBuffer|TypedArray|DataView|Buffer|undefined}
19041904
1905-
The `functionName` member represents represents the function name, used by NIST to define
1905+
The `functionName` member represents the function name, used by NIST to define
19061906
functions based on cSHAKE.
19071907
The Node.js Web Crypto API implementation only supports zero-length functionName
19081908
which is equivalent to not providing functionName at all.
@@ -1941,9 +1941,9 @@ added: v15.0.0
19411941
19421942
* Type: {CryptoKey}
19431943
1944-
ECDH key derivation operates by taking as input one parties private key and
1945-
another parties public key -- using both to generate a common shared secret.
1946-
The `ecdhKeyDeriveParams.public` property is set to the other parties public
1944+
ECDH key derivation operates by taking as input one party's private key and
1945+
another party's public key -- using both to generate a common shared secret.
1946+
The `ecdhKeyDeriveParams.public` property is set to the other party's public
19471947
key.
19481948
19491949
### Class: `EcdsaParams`

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.