| View previous topic :: View next topic |
| Author |
Message |
tim6389 Professional Member


Joined: 01 Aug 2002 Posts: 790
|
Posted: Mon Jan 12, 2004 7:36 am Post subject: hello all checksum question :) |
|
|
hello all (yes i'am still around)
hi all long time no talk yes its me!!! question to ask -
maybe i don't understand the checksum like i thought i did here is what i'am doing.
it i make a exe then uses a packer on the exe THEN i check the checksum lets say it saids 875092988 now if i go back to my source code and edit my checksum varible to this 875092988 then re-compile and repack it.. this should pass the checksum right???? well it don't why? what i'am doing wrong?
thanks
p.s i hope i explain this well _________________ Have a nice day  |
|
| Back to top |
|
 |
Serge Professional Member


Joined: 04 Mar 2002 Posts: 1480 Location: Australia
|
Posted: Mon Jan 12, 2004 8:35 am Post subject: |
|
|
hi tim,
i'm not sure about this but i suspect that the checksum of a file is determined by its contents...hence changing an "a" to a "b" in a file could change its checksum
perhaps a google search will help or someone more knowledgeable
serge _________________
|
|
| Back to top |
|
 |
tim6389 Professional Member


Joined: 01 Aug 2002 Posts: 790
|
Posted: Mon Jan 12, 2004 8:48 am Post subject: hummm |
|
|
what you say does make sence
also to i can't even have it check file size cuase the packer packs it diff each time you run it (even tho i have the same compress rate set the same every time) some times when i pack it it will make file size 22,180 then next time it makes it 22,280 bytes grrrrrrr there has to be a way to do this...
well i will do some checking on the net , if any of ya have any ideas please post
thanks _________________ Have a nice day  |
|
| Back to top |
|
 |
Vic D'Elfant Past Contributor


Joined: 26 Jun 2002 Posts: 673 Location: The Netherlands
|
Posted: Mon Jan 12, 2004 9:05 am Post subject: |
|
|
You could use a ini file to store the checksum of you program (encrypted, if you want), and then let your program compare the saved checksum in the ini file to his own.
This way, the checksum doesn't change when you save it to the inifile
Regards,
Vic _________________ phpBB Development Team |
|
| Back to top |
|
 |
Skit3000 Admin Team

Joined: 11 May 2002 Posts: 2166 Location: The Netherlands
|
Posted: Mon Jan 12, 2004 3:20 pm Post subject: |
|
|
Or, if you can, make a little DLL which can be called from your program. That way, you only have to change the checksum in the DLL if you re-compile your program. You can also let it check other things like size, creation date, etc...  |
|
| Back to top |
|
 |
tim6389 Professional Member


Joined: 01 Aug 2002 Posts: 790
|
Posted: Mon Jan 12, 2004 5:19 pm Post subject: yup |
|
|
the ini file is one thing i was things about last night and for a dll that is other good idea...hummm
i will play with some ideas
thanks all _________________ Have a nice day  |
|
| Back to top |
|
 |
vdsalchemist Admin Team

Joined: 23 Oct 2001 Posts: 1448 Location: Florida, USA
|
Posted: Mon Jan 12, 2004 5:33 pm Post subject: |
|
|
Hi Tim,
There is already a DLL that can do checksums on a file. Take a look at my Guardian.dll it can do either a standard checksum or an encrypted checksum. You can get the DLL as part of my Gadget download. _________________ Home of
Give VDS a new purpose!
 |
|
| Back to top |
|
 |
tim6389 Professional Member


Joined: 01 Aug 2002 Posts: 790
|
Posted: Mon Jan 12, 2004 6:35 pm Post subject: ok |
|
|
mindpower - thanks will check it out but the problem i'am having is not how to do a checksum it is how to store it WITHOUT using a ini file. but for the way it looks i will have to uses a ini file
thanks _________________ Have a nice day  |
|
| Back to top |
|
 |
Hortalonus Valued Contributor


Joined: 15 Mar 2002 Posts: 344 Location: Western USA
|
Posted: Mon Jan 12, 2004 7:19 pm Post subject: Re: ok |
|
|
| tim6389 wrote: | | the problem i'am having is not how to do a checksum it is how to store it WITHOUT using a ini file. |
Ummm... how about the registry?  _________________ "ah, come take my hand... we're ridin' out tonight to face the promised land"
Get a free iPod mp3 player... |
|
| Back to top |
|
 |
FreezingFire Admin Team

Joined: 23 Jun 2002 Posts: 3508
|
Posted: Mon Jan 12, 2004 7:54 pm Post subject: |
|
|
The VDSDLL3's VDSMD5.DLL can calculate the MD5 checksum of a file. _________________ FreezingFire
VDSWORLD.com
Site Admin Team |
|
| Back to top |
|
 |
tim6389 Professional Member


Joined: 01 Aug 2002 Posts: 790
|
Posted: Mon Jan 12, 2004 7:56 pm Post subject: yup that would work |
|
|
registry - would work to but i was hoping to keep it within the exe but i know that this can't be done  _________________ Have a nice day  |
|
| Back to top |
|
 |
FreezingFire Admin Team

Joined: 23 Jun 2002 Posts: 3508
|
Posted: Mon Jan 12, 2004 8:12 pm Post subject: |
|
|
You could append it to the end of the executable file  _________________ FreezingFire
VDSWORLD.com
Site Admin Team |
|
| Back to top |
|
 |
tim6389 Professional Member


Joined: 01 Aug 2002 Posts: 790
|
Posted: Tue Jan 13, 2004 2:16 am Post subject: :) |
|
|
yup i was thinking the same thing
hehehe well thanks all i have a few ideas to try  _________________ Have a nice day  |
|
| Back to top |
|
 |
Skit3000 Admin Team

Joined: 11 May 2002 Posts: 2166 Location: The Netherlands
|
Posted: Tue Jan 13, 2004 2:25 pm Post subject: |
|
|
Please note that if you append it to the of the exe file, you have to remove it right after loading, so that the checksum is right. If you don't remove it, the checksum probably will give another value...  |
|
| Back to top |
|
 |
tim6389 Professional Member


Joined: 01 Aug 2002 Posts: 790
|
Posted: Tue Jan 13, 2004 5:16 pm Post subject: hummm |
|
|
Skit3000 - you have a good piont there. i would like to know is how they do it in diff programming like vb,c+ cuase you would think they would have the same problem i'am having. without having to uses a ini file.
like i say before i can't even have it check file size cuase when you pack it. its diff every time  _________________ Have a nice day  |
|
| Back to top |
|
 |
|