-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Add missing, and update existing, documentation on the HashAlgorithm classes. #3617
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -346,9 +346,20 @@ | |||||
<Parameter Name="source" Type="System.ReadOnlySpan<System.Byte>" Index="0" FrameworkAlternate="netcore-2.1;netcore-2.2;netcore-3.0;netstandard-2.1" /> | ||||||
</Parameters> | ||||||
<Docs> | ||||||
<param name="source">To be added.</param> | ||||||
<summary>To be added.</summary> | ||||||
<remarks>To be added.</remarks> | ||||||
<param name="source">The input to compute the HMAC code for.</param> | ||||||
<summary>Routes data written to the object into the HMAC algorithm for computing the HMAC.</summary> | ||||||
<remarks> | ||||||
<format type="text/markdown"><![CDATA[ | ||||||
|
||||||
## Remarks | ||||||
The default implementation of this method throws a <xref:System.PlatformNotSupportedException> | ||||||
because there is no managed implementation of HMAC. | ||||||
|
||||||
Derived types must override this method. | ||||||
|
||||||
]]></format> | ||||||
</remarks> | ||||||
<exception cref="T:System.PlatformNotSupportedException">In all cases.</exception> | ||||||
</Docs> | ||||||
</Member> | ||||||
<Member MemberName="HashCore"> | ||||||
|
@@ -388,15 +399,13 @@ | |||||
<param name="rgb">The input data.</param> | ||||||
<param name="ib">The offset into the byte array from which to begin using data.</param> | ||||||
<param name="cb">The number of bytes in the array to use as data.</param> | ||||||
<summary>When overridden in a derived class, routes data written to the object into the default <see cref="T:System.Security.Cryptography.HMAC" /> hash algorithm for computing the hash value.</summary> | ||||||
<summary>When overridden in a derived class, routes data written to the object into the HMAC algorithm for computing the HMAC value.</summary> | ||||||
<remarks> | ||||||
<format type="text/markdown"><![CDATA[ | ||||||
|
||||||
## Remarks | ||||||
This method is not called by application code. | ||||||
|
||||||
This abstract method performs the hash computation. Every write to the cryptographic stream object passes the data through this method. For each block of data, this method updates the state of the hash object so that a correct hash value is returned at the end of the data stream. | ||||||
|
||||||
]]></format> | ||||||
</remarks> | ||||||
<altmember cref="T:System.Security.Cryptography.HashAlgorithm" /> | ||||||
|
@@ -433,8 +442,8 @@ | |||||
</ReturnValue> | ||||||
<Parameters /> | ||||||
<Docs> | ||||||
<summary>When overridden in a derived class, finalizes the hash computation after the last data is processed by the cryptographic stream object.</summary> | ||||||
<returns>The computed hash code in a byte array.</returns> | ||||||
<summary>When overridden in a derived class, finalizes the HMAC computation after the last data is processed by the algorithm.</summary> | ||||||
<returns>The computed HMAC value in a byte array.</returns> | ||||||
<remarks> | ||||||
<format type="text/markdown"><![CDATA[ | ||||||
|
||||||
|
@@ -562,8 +571,8 @@ | |||||
<ReturnType>System.Byte[]</ReturnType> | ||||||
</ReturnValue> | ||||||
<Docs> | ||||||
<summary>Gets or sets the key to use in the hash algorithm.</summary> | ||||||
<value>The key to use in the hash algorithm.</value> | ||||||
<summary>Gets or sets the key to use in the HMAC calculation.</summary> | ||||||
<value>The key to use in the HMAC calculation.</value> | ||||||
<remarks> | ||||||
<format type="text/markdown"><![CDATA[ | ||||||
|
||||||
|
@@ -611,11 +620,23 @@ | |||||
<Parameter Name="bytesWritten" Type="System.Int32" RefType="out" Index="1" FrameworkAlternate="netcore-2.1;netcore-2.2;netcore-3.0;netstandard-2.1" /> | ||||||
</Parameters> | ||||||
<Docs> | ||||||
<param name="destination">To be added.</param> | ||||||
<param name="bytesWritten">To be added.</param> | ||||||
<summary>To be added.</summary> | ||||||
<returns>To be added.</returns> | ||||||
<remarks>To be added.</remarks> | ||||||
<param name="destination">The buffer to receive the HMAC value.</param> | ||||||
<param name="bytesWritten">When this method returns, the total number of bytes written into <paramref name="destination"/>. This parameter is treated as uninitialized.</param> | ||||||
<summary>Attempts to finalize the HMAC computation after the last data is processed by the HMAC algorithm.</summary> | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
<returns> | ||||||
<see langword="true"/> if <paramref name="destination"/> is long enough to receive the HMAC value; otherwise, <see langword="false"/>.</returns> | ||||||
<remarks> | ||||||
<format type="text/markdown"><![CDATA[ | ||||||
|
||||||
## Remarks | ||||||
The default implementation of this method throws a <xref:System.PlatformNotSupportedException> | ||||||
because there is no managed implementation of HMAC. | ||||||
|
||||||
Derived types must override this method. | ||||||
|
||||||
]]></format> | ||||||
</remarks> | ||||||
<exception cref="T:System.PlatformNotSupportedException">The method is not overriden in the derived type.</exception> | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think this suggestion is accurate. The method will not throw if the derived class implements it. |
||||||
</Docs> | ||||||
</Member> | ||||||
</Members> | ||||||
|
Uh oh!
There was an error while loading. Please reload this page.