This documentation is for the TIP (development tree) of NNG and may represent unreleased changes or functionality that is experimental, and is subject to change before release. The latest released version is v1.3.2. See the documentation for v1.3.2 for the most up-to-date information.

nng_random(3supp)

NAME

nng_random - get random number

SYNOPSIS

#include <nng/nng.h>
#include <nng/supplemental/util/platform.h>

uint32_t nng_random(void);

DESCRIPTION

The nng_random() returns a random number. The value returned is suitable for use with cryptographic functions such as key generation. The value is obtained using platform specific cryptographically strong random number facilities when available.

RETURN VALUES

Random number.

ERRORS

None.

SEE ALSO