mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-10-23 07:29:39 +00:00
19 lines
278 B
Go
19 lines
278 B
Go
package dhcp4client
|
|
|
|
import (
|
|
cryptorand "crypto/rand"
|
|
mathrand "math/rand"
|
|
)
|
|
|
|
func CryptoGenerateXID(b []byte) {
|
|
if _, err := cryptorand.Read(b); err != nil {
|
|
panic(err)
|
|
}
|
|
}
|
|
|
|
func MathGenerateXID(b []byte) {
|
|
if _, err := mathrand.Read(b); err != nil {
|
|
panic(err)
|
|
}
|
|
}
|