empserver/include
Markus Armbruster 9102ecce54 Fix PRNG seeding to resist guessing
We seed it with value of time().  It's the traditional way, but it
provides only a few bits of effective entropy when an attacker has a
rough idea when the program started.

Instead, seed with a kernel random number.  If we can't get one, fall
back to a hash of gettimeofday() and getpid().  This should happen
only on old systems or Windows.  Far worse than a kernel random
number, but far better than using time().

Note that fairland used to seed with time() + getpid() until commit
331aac2a (v4.2.20) dropped the getpid(), claiming it didn't improve
the randomness.  Perhaps it didn't under Windows then, but it
certainly did elsewhere, so it was a regression.
2013-05-08 06:55:21 +02:00
..
budg.h Update copyright notice 2013-01-12 17:45:01 +01:00
chance.h Fix PRNG seeding to resist guessing 2013-05-08 06:55:21 +02:00
com.h Update copyright notice 2013-01-12 17:45:01 +01:00
combat.h Update copyright notice 2013-01-12 17:45:01 +01:00
commands.h Update copyright notice 2013-01-12 17:45:01 +01:00
commodity.h Update copyright notice 2013-01-12 17:45:01 +01:00
damage.h Replace "roll0(N) + M" by "roll(N) + M-1" 2013-05-08 06:55:20 +02:00
distribute.h Update copyright notice 2013-01-12 17:45:01 +01:00
econfig-spec.h Update copyright notice 2013-01-12 17:45:01 +01:00
empio.h Update copyright notice 2013-01-12 17:45:01 +01:00
empobj.h Update copyright notice 2013-01-12 17:45:01 +01:00
empthread.h Update copyright notice 2013-01-12 17:45:01 +01:00
file.h Update copyright notice 2013-01-12 17:45:01 +01:00
game.h Update copyright notice 2013-01-12 17:45:01 +01:00
ioqueue.h Update copyright notice 2013-01-12 17:45:01 +01:00
item.h Update copyright notice 2013-01-12 17:45:01 +01:00
journal.h Update copyright notice 2013-01-12 17:45:01 +01:00
land.h Update copyright notice 2013-01-12 17:45:01 +01:00
loan.h Update copyright notice 2013-01-12 17:45:01 +01:00
lost.h Update copyright notice 2013-01-12 17:45:01 +01:00
lwp.h Update copyright notice 2013-01-12 17:45:01 +01:00
map.h Update copyright notice 2013-01-12 17:45:01 +01:00
match.h Update copyright notice 2013-01-12 17:45:01 +01:00
misc.h Update copyright notice 2013-01-12 17:45:01 +01:00
mission.h Update copyright notice 2013-01-12 17:45:01 +01:00
nat.h Really fix accepting connections from "long" IPv6 address 2013-01-12 17:56:39 +01:00
news.h Update copyright notice 2013-01-12 17:45:01 +01:00
nsc.h Update copyright notice 2013-01-12 17:45:01 +01:00
nuke.h Update copyright notice 2013-01-12 17:45:01 +01:00
optlist.h Update copyright notice 2013-01-12 17:45:01 +01:00
path.h Update copyright notice 2013-01-12 17:45:01 +01:00
plague.h Update copyright notice 2013-01-12 17:45:01 +01:00
plane.h Update copyright notice 2013-01-12 17:45:01 +01:00
player.h Update copyright notice 2013-01-12 17:45:01 +01:00
power.h Update copyright notice 2013-01-12 17:45:01 +01:00
product.h Update copyright notice 2013-01-12 17:45:01 +01:00
proto.h Update copyright notice 2013-01-12 17:45:01 +01:00
prototypes.h Move declarations for chance.c to new chance.h 2013-05-08 06:55:20 +02:00
queue.h Update copyright notice 2013-01-12 17:45:01 +01:00
retreat.h Update copyright notice 2013-01-12 17:45:01 +01:00
sect.h Update copyright notice 2013-01-12 17:45:01 +01:00
server.h Update copyright notice 2013-01-12 17:45:01 +01:00
service.h Update copyright notice 2013-01-12 17:45:01 +01:00
ship.h Update copyright notice 2013-01-12 17:45:01 +01:00
tel.h Update copyright notice 2013-01-12 17:45:01 +01:00
trade.h Update copyright notice 2013-01-12 17:45:01 +01:00
treaty.h Update copyright notice 2013-01-12 17:45:01 +01:00
types.h Update copyright notice 2013-01-12 17:45:01 +01:00
unit.h Update copyright notice 2013-01-12 17:45:01 +01:00
update.h Update copyright notice 2013-01-12 17:45:01 +01:00
version.h Update copyright notice 2013-01-12 17:45:01 +01:00
xdump.h Update copyright notice 2013-01-12 17:45:01 +01:00
xy.h Update copyright notice 2013-01-12 17:45:01 +01:00