# Argon2Parameters

- [JSON representation](https://docs.cloud.google.com/identity-platform/docs/reference/rest/v1/Argon2Parameters#SCHEMA_REPRESENTATION)
- [HashType](https://docs.cloud.google.com/identity-platform/docs/reference/rest/v1/Argon2Parameters#HashType)
- [Version](https://docs.cloud.google.com/identity-platform/docs/reference/rest/v1/Argon2Parameters#Version)

The parameters for Argon2 hashing algorithm.

| JSON representation |
|---|
| ``` { "hashLengthBytes": integer, "hashType": enum (`https://docs.cloud.google.com/identity-platform/docs/reference/rest/v1/Argon2Parameters#HashType`), "parallelism": integer, "iterations": integer, "memoryCostKib": integer, "version": enum (`https://docs.cloud.google.com/identity-platform/docs/reference/rest/v1/Argon2Parameters#Version`), "associatedData": string } ``` |

| Fields ||
|---|---|
| `hashLengthBytes` | `integer` Required. The desired hash length in bytes. Minimum is 4 and maximum is 1024. |
| `hashType` | ``enum (`https://docs.cloud.google.com/identity-platform/docs/reference/rest/v1/Argon2Parameters#HashType`)`` Required. Must not be HASH_TYPE_UNSPECIFIED. |
| `parallelism` | `integer` Required. The degree of parallelism, also called threads or lanes. Minimum is 1, maximum is 16. |
| `iterations` | `integer` Required. The number of iterations to perform. Minimum is 1, maximum is 16. |
| `memoryCostKib` | `integer` Required. The memory cost in kibibytes. Maximum is 32768. |
| `version` | ``enum (`https://docs.cloud.google.com/identity-platform/docs/reference/rest/v1/Argon2Parameters#Version`)`` The version of the Argon2 algorithm. This defaults to VERSION_13 if not specified. |
| `associatedData` | `string (https://developers.google.com/discovery/v1/type-format format)` The additional associated data, if provided, is appended to the hash value to provide an additional layer of security. A base64-encoded string if specified via JSON. A base64-encoded string. |

## HashType

The types of the algorithm.

| Enums ||
|---|---|
| `HASH_TYPE_UNSPECIFIED` | The hash type is not specified. |
| `ARGON2_D` | An Argon2 variant, Argon2d. |
| `ARGON2_ID` | An Argon2 variant, Argonid. Recommended. |
| `ARGON2_I` | An Argon2 variant, Argon2i. |

## Version

The verion of the algorithm.

| Enums ||
|---|---|
| `VERSION_UNSPECIFIED` | The version is not specified. |
| `VERSION_10` | The previous version, 0x10. |
| `VERSION_13` | The current version, 0x13. The default value for version. |