MCPcopy Create free account
hub / github.com/WireGuard/wgctrl-go / GenerateKey

Function GenerateKey

wgtypes/types.go:84–91  ·  view source on GitHub ↗

GenerateKey generates a Key suitable for use as a pre-shared secret key from a cryptographically safe source. The output Key should not be used as a private key; use GeneratePrivateKey instead.

()

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 2

MustPresharedKeyFunction · 0.92
GeneratePrivateKeyFunction · 0.85

Calls 1

NewKeyFunction · 0.85

Tested by

no test coverage detected