Log in

View Full Version : Keygen approach for a Delphi app


Silver
September 20th, 2004, 14:14
Hi guys,

I'm working on a little app at the moment, it's written in Delphi. Using DeDe etc I've found the "top level" serial checking code easily. I've also found a line of code that quite clearly displays the correct serial key for the registration details entered (checked by viewing it, restarting the app and pasting it in). That's fine, and so I figured that this was a prime candidate for a keygen.

I've run into a conceptual problem. Because this app was written in Delphi it is a huge mess of jumps and calls. There are 15 calls in the "top level" serial checker alone. What should be my approach here? Do I give it up as a bad job that will take a huge amount of time to cleanly rip all the serial generation code out? Stick with the usual patch of a jump-to-good-serial? Or do something else?

I'm interested to know people's approaches. Patching it is easy, I was going to do a kg for experience, but to me it doesn't seem feasible from a time perspective.

akimp3
September 20th, 2004, 15:27
Hi

This is what i do in this kind of situations.
Use the openprocessmemory and writememory API call to add a message box in the program that will display the real serial then close the program from your app and tell the user to enter the serial he has seen in the msgbox.
1-the user have to run your program
2-run the program u want to crack
3-click on the button on your program
4-now your program will do the modification to the program only in memory
5-then he will enter his name and anything he wants as the registration number
6-the real serial will be displaye in msgbox and the program will be closed

by this trick you have made a keygen without knowing the algo.
I can give you delphi source code if you need.

Good luck

Akimp3

dELTA
September 20th, 2004, 16:58
Or you could use TQN's full Delphi signature IDA pack, and most of those messy calls will quite likely be easily replaceable with the corresponding functions in your own Delphi keygen.

http://www.woodmann.com/forum/showthread.php?t=6372

JMI
September 20th, 2004, 17:48
Wouldn't that be cheating? Nah.

Regards,

TQN
September 20th, 2004, 21:36
Hi Silver !
You can also use DeDe and export the disassembly result to a Map file, and use my IDA LoadMap plugin to load that Map file to IDA. The disassembly result in IDA will be better with more name of VCL controls, properties, methods.
Sorry JMI, I have a question about English: what the meaning of BTW, LOL, Nah... I searched in my English-Vietnam dictionary and not found any words.
Best regards,
TQN

Woodmann
September 20th, 2004, 22:47
Quote:
I have a question about English: what the meaning of BTW, LOL, Nah... I searched in my English-Vietnam dictionary and not found any words.


They are abbreviations of words.

BTW="by the way". Kind of meaning "as an after thought" or maybe meaning "incase you did not know "

LOL="laugh out loud".

Nah, it is slang for "no/nevermind/forget it" in English
(depending on what region you live)

hobgoblin
September 21st, 2004, 00:23
To akimp3:

Can I get a copy of the delphi source code you're talking about? I'm currently learning to code using Delphi and I'm interested in seeing how you resolved this. You can mail me at: hobgoblin.at.chello.no

TIA,
hobgoblin

Silver
September 21st, 2004, 07:40
Thanks guys, plenty to try now