Skip to content

Commit 23fe6b4

Browse files
authored
clarify key length parameter (#11246)
1 parent 214d7b9 commit 23fe6b4

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

xml/System.Security.Cryptography/Rfc2898DeriveBytes.xml

+6-10
Original file line numberDiff line numberDiff line change
@@ -1039,7 +1039,7 @@ For more information about PBKDF2, see [RFC 2898](https://www.rfc-editor.org/inf
10391039
<param name="salt">The key salt used to derive the key.</param>
10401040
<param name="iterations">The number of iterations for the operation.</param>
10411041
<param name="hashAlgorithm">The hash algorithm to use to derive the key.</param>
1042-
<param name="outputLength">The size of key to derive.</param>
1042+
<param name="outputLength">The size of the key to derive, in bytes.</param>
10431043
<summary>Creates a PBKDF2 derived key from password bytes.</summary>
10441044
<returns>A byte array containing the created PBKDF2 derived key.</returns>
10451045
<remarks>To be added.</remarks>
@@ -1100,7 +1100,7 @@ For more information about PBKDF2, see [RFC 2898](https://www.rfc-editor.org/inf
11001100
<param name="salt">The key salt used to derive the key.</param>
11011101
<param name="iterations">The number of iterations for the operation.</param>
11021102
<param name="hashAlgorithm">The hash algorithm to use to derive the key.</param>
1103-
<param name="outputLength">The size of key to derive.</param>
1103+
<param name="outputLength">The size of the key to derive, in bytes.</param>
11041104
<summary>Creates a PBKDF2 derived key from password bytes.</summary>
11051105
<returns>A byte array containing the created PBKDF2 derived key.</returns>
11061106
<remarks>To be added.</remarks>
@@ -1207,17 +1207,15 @@ For more information about PBKDF2, see [RFC 2898](https://www.rfc-editor.org/inf
12071207
<param name="salt">The key salt used to derive the key.</param>
12081208
<param name="iterations">The number of iterations for the operation.</param>
12091209
<param name="hashAlgorithm">The hash algorithm to use to derive the key.</param>
1210-
<param name="outputLength">The size of key to derive.</param>
1210+
<param name="outputLength">The size of the key to derive, in bytes.</param>
12111211
<summary>Creates a PBKDF2 derived key from a password.</summary>
12121212
<returns>A byte array of length <paramref name="outputLength" /> that is filled with pseudo-random key bytes.</returns>
12131213
<remarks>
12141214
<format type="text/markdown"><![CDATA[
12151215
12161216
## Remarks
12171217
1218-
The `password` will be converted to bytes using the UTF8 encoding. For
1219-
other encodings, convert the password string to bytes using the appropriate <xref:System.Text.Encoding>
1220-
and use <xref:System.Security.Cryptography.Rfc2898DeriveBytes.Pbkdf2(System.ReadOnlySpan{System.Byte},System.ReadOnlySpan{System.Byte},System.Int32,System.Security.Cryptography.HashAlgorithmName,System.Int32)>.
1218+
The `password` is converted to bytes using the UTF8 encoding. For other encodings, convert the password string to bytes using the appropriate <xref:System.Text.Encoding> and use <xref:System.Security.Cryptography.Rfc2898DeriveBytes.Pbkdf2(System.ReadOnlySpan{System.Byte},System.ReadOnlySpan{System.Byte},System.Int32,System.Security.Cryptography.HashAlgorithmName,System.Int32)>.
12211219
12221220
]]></format>
12231221
</remarks>
@@ -1332,17 +1330,15 @@ The `password` will be converted to bytes using the UTF8 encoding. For
13321330
<param name="salt">The key salt used to derive the key.</param>
13331331
<param name="iterations">The number of iterations for the operation.</param>
13341332
<param name="hashAlgorithm">The hash algorithm to use to derive the key.</param>
1335-
<param name="outputLength">The size of key to derive.</param>
1333+
<param name="outputLength">The size of the key to derive, in bytes.</param>
13361334
<summary>Creates a PBKDF2 derived key from a password.</summary>
13371335
<returns>A byte array of length <paramref name="outputLength" /> that is filled with pseudo-random key bytes.</returns>
13381336
<remarks>
13391337
<format type="text/markdown"><![CDATA[
13401338
13411339
## Remarks
13421340
1343-
The `password` will be converted to bytes using the UTF8 encoding. For
1344-
other encodings, convert the password string to bytes using the appropriate <xref:System.Text.Encoding>
1345-
and use <xref:System.Security.Cryptography.Rfc2898DeriveBytes.Pbkdf2(System.Byte[],System.Byte[],System.Int32,System.Security.Cryptography.HashAlgorithmName,System.Int32)>.
1341+
The `password` is converted to bytes using the UTF8 encoding. For other encodings, convert the password string to bytes using the appropriate <xref:System.Text.Encoding> and use <xref:System.Security.Cryptography.Rfc2898DeriveBytes.Pbkdf2(System.Byte[],System.Byte[],System.Int32,System.Security.Cryptography.HashAlgorithmName,System.Int32)>.
13461342
13471343
]]></format>
13481344
</remarks>

0 commit comments

Comments
 (0)