My hash function is as follows:
- Cut the string in half (assume even length of 2m)
- XOR's the two halves together
- Take the result of the XOR and pass it to a function (a one-to-one and "onto" function) that simply does:
$f: \{0, 1\}^m \rightarrow \{0, 1\}^m$
I'm being asked to prove why this hashing strategy is not second pre-image resistant (though it is pre-image resistant) but I'm getting hung up.
I know a 2nd pre-image means finding $x' \neq x$ s.t. $h(x') = h(x).$
I also know that different strings can result in the same XOR:
$1010 \oplus 1111 = 0101$ and so does $0000 \oplus 0101.$
I think I'm just lacking complete understanding of the concept. Thank you in advance for your help.