Hey there, >> ~= 5.1E-57 > > Bah. My math is wrong. I was never very good at P&S. I'll ask someone at > work tomorrow to look at it and show me the folly. Wikipedia has it right, > but I can't evaluate numbers to the few-hundredth power in any calculator > that I have handy.
bc -l <<EOF scale=150 define bday(n, h) { return 1 - e(-(n^2)/(2*h)); } bday(2^35, 2^256) bday(2^35, 2^256) * 10^57 EOF Basically, ~5.1 * 10^-57. Seems your number was correct, although I am not sure how you arrived at it. It appears that number is ~ consistent with the tables on Wikipedia article on birthday attack (http://en.wikipedia.org/wiki/Birthday_attack): p=10^−15 for 256-bit hash collision requires 1.5*10^31 (O(2^103)) hashes, assuming the hashes are randomly distributed. That's definitely improbable. For anecdotal evidence to the contrary, we once had apps using GUIDs. We did believe collisions would be extremely improbable. Yet GUID conflicts turned into recurring events, at worst several collisions a week. It may or may not be related - in our case it turned out the GUIDs weren't anywhere near as random as people thought they would or should be. In retrospect we clearly used a flawed GUID generator which rendered our assumptions about randomness invalid. SHA256 on (even non-random) data is different, but do be careful about what you assume. Regards, Lassi _______________________________________________ zfs-discuss mailing list zfs-discuss@opensolaris.org http://mail.opensolaris.org/mailman/listinfo/zfs-discuss