FileForums

FileForums (https://fileforums.com/index.php)
-   Game Coders (https://fileforums.com/forumdisplay.php?f=36)
-   -   How does it work ? (https://fileforums.com/showthread.php?t=76051)

Petrol king 24-03-2006 10:34

How does it work ?
 
Hello,

First, sorry if my english isn't good it is because i' m french and i' m still at school.

If i post here it is to know how a Crack No Cd or an other crack works.

My intentions are not cracking or hacking, i don ' t want to know exactly
how it works, it should be very complicated, i just wanna know how it works globaly.

thx,


++

Petrol king,

DABhand 24-03-2006 23:03

Basically its called Reverse Engineering, where you take the game code and rewrite it so that it functions differently.

Petrol king 25-03-2006 02:17

I thought it was something like that and i tryed to get the asm code of a exe, it is enormous, never seen something like that, nothing understandable.
It is why i asked the question, i believed there was a other way to do that.

I thought of doing a copy of the cd on the computer and make the program read on the copy .I' d like to have your opinion on it, do you think this way is easier ?

thx

++
sn00bino

TippeX 25-03-2006 05:52

Quote:

Originally Posted by Petrol king
I thought of doing a copy of the cd on the computer and make the program read on the copy .I' d like to have your opinion on it, do you think this way is easier ?

of course its easier (especially if you dont know asm/cant crack), but you are simply bypassing the protection checks with the image/burned backup, the protection code is NOT magically removed

Petrol king 25-03-2006 06:57

It is real that my knowledge in asm is limited.But can ' t i do a transformer from exe to a language who ' s not far from c++ ?

By exemple if i do that :

1 Create a prog with nothing in it.
2 Create a other prog like the first exept i add an if instruction
3 Create a prog which compare the 2 programs and return the differences.

So the third program returns me an instruction if.

And if i do that for all the basic instruction,and if i do a fourth program wich knows all this instructions.Won' t i be able to retrieve a almost-cpp source code ?

There is a other thing, if i want to delete the need of the cd, i must know when the program need it.So, Do you have an idea of the way to do that ?

thx,
++

PS: if you can 't understand something or if i do syntax or other fault don' t hesitate to tell me.

TippeX 25-03-2006 08:13

c, delphi etc are all high level languages, they are compiled to assembly language by the compiler, so having experience in c can help but you really also need to know assembly so that you can change the instructions in the compiled exe.. a cdcheck can be done via various methods, the most simple being a call to GetDriveTypeA which returns 05 if the device passed in the parameters is a cdrom drive, so you then find the procedure that does the cdcheck and 'help' it so it returns 'hey there is a cd present, all is ok' back to the code, which then continues on... thats an example of a simplistic cdcheck, there are far far harder ones like on securom, starforce, safedisc etc... which most people can not 'bypass' as easily

in your examples, the 'differences' will probably be huge, and will be caused by the compiler, they will also be hex bytes which 'translate' to asm code, you won t see the 'code' you changed in a human readable form (like your c code)...

Petrol king 25-03-2006 10:02

Could you tell me more about GetDriveTypeA ? Because i didn't found lots of thing on it on internet.

And how could i find the procedure ?

I' m sorry if you ' ve told that already in your message but i didn't understand it all.

TippeX 25-03-2006 10:27

www.msdn.com

information is also in the win32api that comes with most compilers, and can be found relatively easily with google - its size varies from 12mb upwards, and is also included in some of the microsoft sdk's etc..

Searching for 'GetDriveType' might have also helped, most win32 api's have an A at the end (signifying Ansi 'version' of the code) or a W (signifying unicode/widechar 'version' of the code)

The GetDriveType function determines whether a disk drive is a removable, fixed, CD-ROM, RAM disk, or network drive.

UINT GetDriveType(

LPCTSTR lpRootPathName // address of root path
);
Parameters

lpRootPathName

Points to a null-terminated string that specifies the root directory of the disk to return information about. If lpRootPathName is NULL, the function uses the root of the current directory.

Return Values

The return value specifies the type of drive. It can be one of the following values:

Value Meaning
0 The drive type cannot be determined.
1 The root directory does not exist.
DRIVE_REMOVABLE The drive can be removed from the drive.
DRIVE_FIXED The disk cannot be removed from the drive.
DRIVE_REMOTE The drive is a remote (network) drive.
DRIVE_CDROM The drive is a CD-ROM drive.
DRIVE_RAMDISK The drive is a RAM disk.

the DRIVE_* are equates.. and its really 0,1,2,3,4,5,6 (5 being cdrom, dvd is also 'cdrom')

hope that helps, happy googling :)

Petrol king 25-03-2006 12:45

So if i understand, this function tell me if a cd is present or not ?

caki 25-03-2006 14:14

Well, no.

For GetDriveTypeA, you give as input the name of a drive, and then it tells you what type of drive it is (i.e CD Drive, Hard Drive etc...)

Petrol king 26-03-2006 04:22

ok, i understood, thanks.

So now i need to know when the program call this fonction,how could i do that ?

I thought lots of thing but i didn't find something makable.

DABhand 26-03-2006 07:26

Any language has a way of calling API's like for example GetDriveTypeA.


If your using C/C++ look on how to include dll's into the program or how to call API's from dll files.

Joe Forster/STA 27-03-2006 04:38

Also, see http://sta.c64.org/docs.html#win32api for a help file on the 32-bit Windows API.

princcce 06-04-2006 08:42

Forbidden !!
 
Reverse Engineering is forbidden by law. I don´t know how hard it´s gonna be punished but u should know before starting.;)

Joe Forster/STA 06-04-2006 08:50

Thank heavens, it isn't forbidden in all countries. ;)


All times are GMT -7. The time now is 02:41.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
FileForums @ https://fileforums.com