this is appalling. And of course we can only find out about it from overseas media because our own media is quaking in their boots :(
nice clear data there
I was in the middle of writing a breakdown of what went wrong, but you’ve beat me to it. Basically, they have a LinuxSecureRandom class that’s supposed to override the standard SecureRandom. This class reads from /dev/urandom and should provide cryptographically secure random values. They also seed the generator using SecureRandom#setSeed with data pulled from random.org. With their custom SecureRandom, this is safe because it mixes the entropy using XOR, so even if the random.org data is dodgy it won’t reduce security. It’s just an added bonus. BUT! On some devices under some circumstances, the LinuxSecureRandom class doesn’t get registered. This is likely because /dev/urandom doesn’t exist or can’t be accessed for some reason. Instead of screaming bloody murder like any sensible implementation would, they just ignore that and fall back to using the standard SecureRandom. If the above happens, there’s a problem because the default implementation of SecureRandom#setSeed doesn’t mix. If you set the seed, it replaces the entropy entirely. So now the entropy is coming solely from random.org. And the final mistake: They were using HTTP instead of HTTPS to make the webservice call to random.org. On Jan 4, random.org started enforcing HTTPS and returning a 301 Permanently Moved error for HTTP – see https://www.random.org/news/. So since that date, the entropy has actually been the error message (turned into bytes) instead of the expected 256-bit number. Using that seed, SecureRandom will generate the private key for address 1Bn9ReEocMG1WEW1qYjuDrdFzEFFDCq43F 100% of the time. Ouch. This is around the time that address first appears, so the timeline matches. I haven’t had a thorough look at what they’ve replaced it with in the latest version, but initial impressions are that it’s not ideal. Not disastrous, but not good.Always check return values; always check HTTP status codes.
A strongly specified, highly compatible implementation of Markdown
‘A Decentralized GitHub’. nifty
Links for 2015-05-29
permalink. Both comments and trackbacks are currently closed.. Bookmark the