News for hackers. Stuff that matters.
Re:Google Drive flags file only containing “1” for copyright... by Sharlin on Monday January 24, 2022 @07:20PM (#30066126)
h(1) == h(some_real_data) does not have to happen at some point. Collisions are unavoidable, but the point of a cryptographically secure hash algorithm is to ensure that for all h(x) == h(some_real_data), there are no values of x that can be found by brute force, or by cleverness either for that matter.

Of course, it’s always possible that the particular hash function used could be hilariously broken…

Re:Google Drive flags file only containing “1” for copyright... by pertique on Wednesday January 26, 2022 @12:44PM (#30088812)
Perhaps I'm misunderstanding you, but doesn't the existence of collisions guarantee that h(1)== h(some_real_data) unless the hash function is hilariously broken?

Cryptographically secure hash functions state that it's unlikely to occur, but the fact that you can take data a greater size than the output will guarantee that you'll have collisions. If you have collisions and the hash function is generating output that is uniformly distributed across the possible output space, you will hit h(1)==h(some_real_data) at some point (edit: given that "some point" is a mathematical concept, not an actual point in time. Of course, there's no guarantee that we'll ever get collisions for hash functions with massive output spaces. But I'd argue that's a limit of computing, not of the math behind the functions themselves)