81be797065
change here is to ensure that when a process forks after arc4random is seeded, the parent and child don't observe the same random sequence. OpenBSD's fix introduces some additional overhead in the form of a getpid() call. This could be improved upon, e.g., by setting a flag in fork(), if it proves to be a problem. This was discussed with secteam (simon, csjp, rwatson) in 2008, shortly prior to my going out of town and forgetting all about it. The conclusion was that the problem with forks is worrisome, but it doesn't appear to have introduced an actual vulnerability for any known programs. The only significant remaining difference between our arc4random and OpenBSD's is in how we seed the generator in arc4_stir().