summaryrefslogtreecommitdiff
path: root/docs/reference/src/util/nng_random.md
diff options
context:
space:
mode:
Diffstat (limited to 'docs/reference/src/util/nng_random.md')
-rw-r--r--docs/reference/src/util/nng_random.md28
1 files changed, 28 insertions, 0 deletions
diff --git a/docs/reference/src/util/nng_random.md b/docs/reference/src/util/nng_random.md
new file mode 100644
index 00000000..e4f6f52a
--- /dev/null
+++ b/docs/reference/src/util/nng_random.md
@@ -0,0 +1,28 @@
+# nng_random
+
+## NAME
+
+nng_random --- get random number
+
+## SYNOPSIS
+
+```c
+#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
+
+Returns a random 32-bit value.
+
+{{#include ../refs.md}}