golang / go

The Go programming language
https://go.dev
BSD 3-Clause "New" or "Revised" License
124.22k stars 17.7k forks source link

runtime: use .openbsd.randomdata for startupRand #69781

Open FiloSottile opened 1 month ago

FiloSottile commented 1 month ago

OpenBSD has its version of AT_RANDOM, the .openbsd.randomdata ELF section documented at SPECS.randomdata. We should use that instead of reading from /dev/urandom.

jharshman commented 1 month ago

Looking at this, just want to make sure this is the documentation you're referring to: https://github.com/openbsd/src/blob/master/libexec/ld.so/SPECS.randomdata

gopherbot commented 1 month ago

Change https://go.dev/cl/618155 mentions this issue: runtime: Use OpenBSD AT_RANDOM for startupRand