Skip to content

mysql_argon2_costs

imshooter edited this page Dec 1, 2026 · 2 revisions

Set the costs of the Argon2id hashes started after it.

native bool:mysql_argon2_costs(
    memory = MYSQL_ARGON2_MEMORY,
    iterations = MYSQL_ARGON2_ITERATIONS,
    parallelism = MYSQL_ARGON2_PARALLELISM
);

With open.mp names, from the same include:

native bool:MySQL_SetArgon2Costs(
    memory = MYSQL_ARGON2_MEMORY,
    iterations = MYSQL_ARGON2_ITERATIONS,
    parallelism = MYSQL_ARGON2_PARALLELISM
);

Parameters

Parameter Description
memory = MYSQL_ARGON2_MEMORY Memory, in KiB, from 8192 to 1048576.
iterations = MYSQL_ARGON2_ITERATIONS Passes, from 1 to 16.
parallelism = MYSQL_ARGON2_PARALLELISM Lanes, from 1 to 8.

Returns

  • true when they were set.
  • false when a cost is out of range.

Home

Guides

Reference

Functions

Connections
Queries
Cache
JSON cells
ORM
Queries built in pieces
Prepared statements
Batches
Transactions
Passwords
Callbacks

Clone this wiki locally