tank's CON fuzed

Tut by Crudd [CrEaM]



Ok, here we go with a great new and fun reverseme by tank. I had a blast with this hope you do too. Now, on with the show.

Tools:
IDA 
HIEW
Resource editor (i used Resource Hacker)
Some beer

Step 1: Fixing the buttons
Ok, fire up IDA and disassemble our program. Go drink a beer or two and watch some porn.
Now that the disassembly is done, click on the Show function button, and all the way at the bottom of the list is '_TForm1_Button1Click'. Double click on this and it will take use to our procedure:
0043F8B0 
0043F8B0 _TForm1_Button1Click proc near          ; DATA XREF: CODE:0043F29Ao
0043F8B0                 mov     al, 2
0043F8B2                 call    sub_43F308
0043F8B7                 retn
0043F8B7 _TForm1_Button1Click endp
0043F8B7 
0043F8B8 
0043F8B8 ; ¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦ S U B R O U T I N E ¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦
0043F8B8 
0043F8B8 
0043F8B8 _TForm1_Button2Click proc near          ; DATA XREF: CODE:0043F2ADo
0043F8B8                 mov     al, 3
0043F8BA                 call    sub_43F308
0043F8BF                 retn
0043F8BF _TForm1_Button2Click endp
0043F8BF 
0043F8C0 
0043F8C0 ; ¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦ S U B R O U T I N E ¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦
0043F8C0 
0043F8C0 
0043F8C0 _TForm1_Button3Click proc near          ; DATA XREF: CODE:0043F2C0o
0043F8C0                 mov     al, 1
0043F8C2                 call    sub_43F308
0043F8C7                 retn
0043F8C7 _TForm1_Button3Click endp
0043F8C7 
0043F8C8 
So whut does this mean? It means the 'Exit' button set bl to 1, the 'First Message' button sets it to 2 and the 'Second Message' to 3. So just rearrage them to be whut we wunt. Set Button1 to 1, the Button2 to 2, and Button3 to 3. So load CON fuzed into HIEW, and chage these bytes:
offset     Origanal     Changed to
0003ECB0   mov al,2     mov al,1
0003ECB8   mov al,3     mov al,2
0003ECC0   mov al,1     mov al,3
Now we're done with that. Easy enough, huh?

Step 2: Fixing the CON fuzed Menu Item
So we will now fix the CON fuzed menu item under the About menu. So go and click _TForm1_CONfuzed1Click and you'll end up at 0043F374. I think whut this is doing is conconating all of those strings together to get the long message, so just skip down to 0043F4CB. This is where it starts pushing the parameters for the message box.
So first lets make the message we wunt it to display, so find us a cave. I used one at 0003EEE0. So type our message in, whutever you wunt. Now lets plug in the offsets into messagebox. First change the push at 0003E8CD to 'push 0043FAC9' this pushes the Title of the message box. And the next line should be 'push 0043FAE0', this is our new message. Then 4 nop's to get us to our next push and that part is finished.
Now all we need to do is jump over the second message box so change 0003E8E2 to 'jmp 0003E8F5'. Now on to the other menu items.

Step 3: Fixing the Other Menu Items
All you got to do for this part is fire up your trusty resource editor, double click RCData. Double click TFORM1. Scroll down till you see the menu objects and under the menu's add 'OnClick = Button1Click' to the '&First' menu and 'OnClick = Button2Click' to the '&Second' and finally 'OnClick = Button3Click' for the '&Exit' and now we're done.

Final Words:
Well, this was another excellent reverse me reversed. I wish i could've fixed the last menu items without the ResEditor, but i couldn't figure it out. I hope you all had as much fun as i did and learned something also.

Greets: tank for his wonderful reme, Sheep140 and all of [CrEaM], Optical, extasy, all of the Immortal Descendants for thier great work, anyone who has helped me along the way, L!m!t and all of [TeX], anyone i forgot (sorry) and anyone who reads this.

Thanks to: Beer, my girlfriend and other random drunk sluts, your sister, and of course you.

Mail me at: Crudd@DrunkenBastards.com