# GenerateHash

Required Frends version: 5.5+

Required .NET version: 6.0

Compatible Agents: Crossplatform

Source code: <https://github.com/FrendsPlatform/Frends.Cryptography>

{% tabs %}
{% tab title="Parameter: Input" %}

| Name                      | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| ------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| HashFunction : `Function` | <p>Generates input string to chosen HashAlgorithm type.</p><p>Possible values:</p><ul><li><code>MD5</code>:</li></ul><p>Generates input string to chosen HashAlgorithm type.</p><ul><li><code>SHA1</code>:</li></ul><p>Generates input string to chosen HashAlgorithm type.</p><ul><li><code>SHA256</code>:</li></ul><p>Generates input string to chosen HashAlgorithm type.</p><ul><li><code>SHA384</code>:</li></ul><p>Generates input string to chosen HashAlgorithm type.</p><ul><li><code>SHA512</code>:</li></ul><p>Generates input string to chosen HashAlgorithm type.</p><ul><li><code>HMACSHA256</code>:</li></ul><p>Generates input string to chosen HashAlgorithm type.</p><ul><li><code>HMACSHA512</code>:</li></ul><p>Generates input string to chosen HashAlgorithm type.</p><p><br>Default: <code>0</code><br>Example: <code>MD5</code></p> |
| InputString : `String`    | <p>Input string to be hashed.</p><p><br>Default: <code>-</code><br>Example: <code>foo</code></p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| 🗝HashKey : `String`      | <p>HashKey when using HMACSHA256 or HMACSHA512 HashAlgorithm type.</p><p><br>Default: <code>-</code><br>Example: <code>foobar</code></p>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| {% endtab %}              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |

{% tab title="Result: Result" %}

| Name            | Description                                                                          |
| --------------- | ------------------------------------------------------------------------------------ |
| Hash : `String` | <p>HashResult.<br>Example: <code>8843d7f92416611de9ebb963fy4ce281v5932878</code></p> |
| {% endtab %}    |                                                                                      |

{% tab title="Changelog" %}

## Changelog

### \[1.0.0] - 2022-08-11

#### Added

* Initial implementation
  {% endtab %}
  {% endtabs %}
