Version: v0.0.0-...-70c92dc Latest Latest

This package is not in the latest version of its module.

Go to latest
Published: Sep 10, 2021 License: MIT Imports: 10 Imported by: 0




This section is empty.


View Source
var MAC [6]byte = getMAC() // One MAC of this machine; Particular case, it is a random bytes.


func Int31

func Int31() int32

Int31 returns a non-negative random 31-bit integer as an int32.

func Int63

func Int63() int64

Int63 returns a non-negative random 63-bit integer as an int64.

func New

func New() (rd [16]byte)

New returns 16-byte raw random bytes. It is not printable, you can use encoding/hex or encoding/base64 to print it.

func NewHex

func NewHex() (rd []byte)

NewHex returns 32-byte hex-encoded bytes.

func Read

func Read(p []byte)

Read reads len(p)-byte raw random bytes to p.

func Uint32

func Uint32() uint32

Uint32 returns a random 32-bit integer as a uint32.

func Uint64

func Uint64() uint64

Uint64 returns a random 64-bit integer as a uint64.


This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL