CapyKit/Documentation/Help/Methods_T_CapyKit_Helpers_KeyHelper.md

77 lines
4.6 KiB
Markdown
Raw Normal View History

2025-02-14 04:52:55 -06:00
# KeyHelper Methods
## Methods
<table>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_BytesToHex.md">BytesToHex</a></td>
<td>Converts a byte array to a hex string.</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_ComputeSignature.md">ComputeSignature</a></td>
<td>Computes an HMAC-SHA256 over the salt using the master key and truncates it to the same number of bytes as the salt.</td></tr>
<tr>
<td><a href="https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object)" target="_blank" rel="noopener noreferrer">Equals</a></td>
<td>Determines whether the specified object is equal to the current object.<br />(Inherited from <a href="https://learn.microsoft.com/dotnet/api/system.object" target="_blank" rel="noopener noreferrer">Object</a>)</td></tr>
<tr>
<td><a href="https://learn.microsoft.com/dotnet/api/system.object.finalize" target="_blank" rel="noopener noreferrer">Finalize</a></td>
<td>Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.<br />(Inherited from <a href="https://learn.microsoft.com/dotnet/api/system.object" target="_blank" rel="noopener noreferrer">Object</a>)</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_FormatKey.md">FormatKey</a></td>
<td>Formats the given hex string into the desired number of parts (separated by dashes).</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_GenerateKey.md">GenerateKey</a></td>
<td>Generates a random key.</td></tr>
<tr>
<td><a href="https://learn.microsoft.com/dotnet/api/system.object.gethashcode" target="_blank" rel="noopener noreferrer">GetHashCode</a></td>
<td>Serves as the default hash function.<br />(Inherited from <a href="https://learn.microsoft.com/dotnet/api/system.object" target="_blank" rel="noopener noreferrer">Object</a>)</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_GetMasterKey.md">GetMasterKey</a></td>
<td>Gets the master key.</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_GetNumParts.md">GetNumParts</a></td>
<td>Gets the number parts.</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_GetSaltSize.md">GetSaltSize</a></td>
<td>Gets the salt size.</td></tr>
<tr>
<td><a href="https://learn.microsoft.com/dotnet/api/system.object.gettype" target="_blank" rel="noopener noreferrer">GetType</a></td>
<td>Gets the <a href="https://learn.microsoft.com/dotnet/api/system.type" target="_blank" rel="noopener noreferrer">Type</a> of the current instance.<br />(Inherited from <a href="https://learn.microsoft.com/dotnet/api/system.object" target="_blank" rel="noopener noreferrer">Object</a>)</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_HexToBytes.md">HexToBytes</a></td>
<td>Converts a hex string back to a byte array.</td></tr>
<tr>
<td><a href="https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone" target="_blank" rel="noopener noreferrer">MemberwiseClone</a></td>
<td>Creates a shallow copy of the current <a href="https://learn.microsoft.com/dotnet/api/system.object" target="_blank" rel="noopener noreferrer">Object</a>.<br />(Inherited from <a href="https://learn.microsoft.com/dotnet/api/system.object" target="_blank" rel="noopener noreferrer">Object</a>)</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_SetMasterKeyAccessor.md">SetMasterKeyAccessor</a></td>
<td>Sets the master key.</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_SetNumPartsAccessor.md">SetNumPartsAccessor</a></td>
<td>Set and get the number of parts for the formatted key. Default is 2.</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_SetSaltSizeAccessor.md">SetSaltSizeAccessor</a></td>
<td>Sets the salt size (in bytes). Default is 4.</td></tr>
<tr>
<td><a href="https://learn.microsoft.com/dotnet/api/system.object.tostring" target="_blank" rel="noopener noreferrer">ToString</a></td>
<td>Returns a string that represents the current object.<br />(Inherited from <a href="https://learn.microsoft.com/dotnet/api/system.object" target="_blank" rel="noopener noreferrer">Object</a>)</td></tr>
<tr>
<td><a href="M_CapyKit_Helpers_KeyHelper_ValidateKey.md">ValidateKey</a></td>
<td>Validates the provided key.</td></tr>
</table>
## Extension Methods
<table>
<tr>
<td><a href="M_CapyKit_Extensions_ObjectExtensions_UpdateProperties.md">UpdateProperties</a></td>
<td>An object extension method that updates the properties of a given <em>target</em> object with the values from a given <em>source</em> object.<br />(Defined by <a href="T_CapyKit_Extensions_ObjectExtensions.md">ObjectExtensions</a>)</td></tr>
</table>
## See Also
#### Reference
<a href="T_CapyKit_Helpers_KeyHelper.md">KeyHelper Class</a>
<a href="N_CapyKit_Helpers.md">CapyKit.Helpers Namespace</a>