0
$\begingroup$

An administrator is testing the collision resistance of different hashing algorithms. Which of the following is the strongest collision resistance test?

A. Find two identical messages with different hashes

B. Find two identical messages with the same hash

C. Find a common hash between two specific messages

D. Find a common hash between a specific message and a random message

I am studying for Security+ and I find this question repeated with the same answer: A without explanation which I believe wrong.

I thought pre-image resistance is when given a hash output h, it is difficult to find the input m such that h(m) is irreversible.

While a weak collision test is when given a specific m1, it is difficult to find a random m2 such that h(m1) = h(m2)

And a strong collision test is when given a random m1 and a random m2, it is difficult to output the same hash digest such that h(m1) = h(m2)

So I believe the answer is not even listed. Since that A does not correspond to any of the collision tests definitions and B is typically the characteristic of a hash function, C implies identical messages which also a paraphrase of B and lastly, D closely refers to a weak collision test a specific m1 and random m2.

How could possibly the answer be A? Is this question missing something or am I misguided somehow? Can someone explain to me please.

I believe the answer should be E. Find a common hash between two random messages

$\endgroup$
  • 1
    $\begingroup$ Hint: look for weak collision and strong collision resistance. $\endgroup$ – kelalaka Aug 5 at 16:13
  • 5
    $\begingroup$ Those are some very weird options. $\endgroup$ – Maeher Aug 5 at 20:15
  • 1
    $\begingroup$ A is literally impossible because hash functions are deterministic (unless you're talking about MACs but this doesn't seem to be the case here). $\endgroup$ – SEJPM Aug 6 at 6:07
  • 2
    $\begingroup$ @SEJPM And B is nonsensical. $\endgroup$ – Maeher Aug 6 at 15:01
  • 1
    $\begingroup$ It's absolutely impossible for an identical pair of messages to not have an identical hash. There is no such scenario that would make that possible for an (unkeyed) hash to spit out different outputs for the same input. Now, an implementation might screw something up in edge cases, and the stray gamma photon might flip a bit or two in memory, but those are all incorrect evaluations of a hash (i.e. not the hash). $\endgroup$ – forest Aug 7 at 5:42
2
$\begingroup$

A. Find two identical messages with different hashes

This is fundamentally impossible, assuming you're talking about a regular hash and not a keyed hash (like HMAC). As hashes are deterministic, two identical messages will always result in an identical hash.

B. Find two identical messages with the same hash

This is not only possible, but guaranteed. Two identical messages will always have the same hash.

C. Find a common hash between two specific messages

Assuming "specific message" refers to a message that you generate, this would be a collision attack. Such attacks are done against the hash function itself, not any existing message. A collision attack generates two messages which differ but which result in the exact same hash output.

D. Find a common hash between a specific message and a random message

This implies a preimage attack, which is similar to a collision, but you only get to control one message. It's also far harder to exploit than a collision attack because you do not have as much freedom.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.