[io64][smashthestack] level2: Divide and conquer (or not…)

For this level, and for all next levels, we’ll always be provided the source code, the goal here is not really to reverse but to “exploit” the binary.

One could first try dividing  0x1064deadbeef4601 by 0xd1038d2e07b42569, let’s try it with bc:

Of course that didn’t work, the result is not an integer, we need to overflow a multiplication and obtain a 128 bit value who’s 64 LSB are equal to 0xd1038d2e07b42569. But how ?

We have to construct 0xd1038d2e07b42569 from right to left, In this case we are quiet helped because the lsb of the multiplier is 0x01:

Multiplying 0x1064DEADBEEF4601 with 0x7373617034366F69 we managed to generate a 128 bit integer who’s lsb is exactly 0xD1038D2E07B42569

let’s try that number.

worked like a charm 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *