You can use the \(\text{TRNG32}\) function to obtain a cryptographically secure random 32-bit unsigned integer.

You can use the \trng32 backslash command to insert this function.

The following variants of this function are available:

  • \(\text{integer } \text{TRNG32} \left ( \text{<any value>} \right )\)

The \(\text{TRNG32}\) function requires an arbitrary parameter that will be ignored.

The function returns a cryptographically secure random number over the range [0, 4294967295].

The \(\text{TRNG32}\) function uses the operating system’s cryptographic source of entropy. Note that the OS cyptographic entropy sources may be slow due to the underlying algorithms and available entropy.

\[a = \text{TRNG32 } 0 \;\;\;\;\; \text{a = 979359194}\]