Skip to content

__digest

JMeter __digest function reference: syntax, parameters, and practical examples for parameterizing test plans with dynamic values.

Difficulty
intermediate
Guide type
reference
Estimated read time
1 min read
Last verified version
Verified JMeter 5.6

Also documented in context in the full Functions and Variables reference.

The digest function returns an encrypted value in the specific hash algorithm with the optional salt, upper case and variable name.

NameRequiredDescription
AlgorithmYesThe algorithm to be used to encrypt For possible algorithms See MessageDigest in StandardNames - MD2 - MD5 - SHA-1 - SHA-224 - SHA-256 - SHA-384 - SHA-512 :::note Spaces are taken into account for Salt to add and String to encode :::
String to encodeYesThe String that will be encrypted
Salt to addNoSalt to be added to string (after it)
Upper Case valueNoResult will be in lower case by default. Choose true to upper case results.
Name of variableNoThe name of the variable to set.

Examples:

Terminal window
\${__digest(MD5,Errare humanum est,,,)}

returns c49f00b92667a35c63708933384dad52

Terminal window
\${__digest(SHA-256,Felix qui potuit rerum cognoscere causas,mysalt,,)}

returns a3bc6900fe2b2fc5fa8a601a4a84e27a079bf2c581d485009bc5c00516729ac7

On this page