Page 1 of 2

PureVALID library : check an EXE integrity at runtime

Posted: Thu Mar 11, 2004 10:44 am
by gnozal
PureVALID library

What for ?

PureValid is a library with one function : PureValid_CheckFile(Key.s)

It is intended to check an EXE integrity at runtime, by calculating a fingerprint and comparing it to a validation info located at the end of the EXE.
This validation info is generated by PureValid.exe (included) or PureUPX.

How ?

1. In your application YourApp.pb, only add one line :

  PureValid_CheckFile("YourEncryptionKey")
   or
   Valid = PureValid_CheckFile("YourEncryptionKey")
   ; Valid = 1 if EXE is valid,
   ; 0 if EXE is corrupt (program stops)

2. Compile your application as usual

3. Validate your application with PureValid.exe :

   PureValid YourApp.exe "YourEncryptionKey"

4. It's done. Now if something / someone changes your application, it does not run anymore. Try to change it's name or patch it, and see the result.

Note (1): you can also use PureUPX to validate your application after compressing (+/- scrambling). If the PureValid library is installed, you will see an extra PureValid section when you start PureUPX.

Note (2): it's only an integrity check, without any anti-debugging tricks, so it's a very lame protection against hackers...


Download library:
Only available for Purebasic Windows x86
PB3.94 : http://gnozal.ucoz.com/PureValid.zip
PB4.00-4.10 : http://gnozal.ucoz.com/PureValid_.zip
PB4.20 : http://gnozal.ucoz.com/PureValid___.zip
PB4.3x : http://gnozal.ucoz.com/PureValid_430.zip
PB4.4x : http://gnozal.ucoz.com/PureValid_440.zip
PB4.5x : http://gnozal.ucoz.com/PureValid_450.zip
PB4.6x : http://gnozal.ucoz.com/PureValid_460.zip
PB5.0x : http://gnozal.ucoz.com/PureValid_500.zip

PureUPX :
http://gnozal.ucoz.com/PureUPX.zip
(see viewtopic.php?t=9030)

Other libs and tools at http://gnozal.ucoz.com/

Posted: Mon Apr 19, 2004 7:43 am
by gnozal
Update

What's new : works with PB3.90

(see first post of thread)

Posted: Thu Oct 28, 2004 7:55 am
by gnozal
Update

Changed dynamic array to static array to work with PB3.92

Posted: Mon Nov 15, 2004 11:25 pm
by GeoTrail
Cool, great addition to my lib arsenal ;)

Posted: Tue Nov 16, 2004 1:17 am
by griz
Thanks gnozal!

It would be nice if the help file was a .chm so that Pure Basic would link to it in the IDE... :)

Posted: Sat Nov 27, 2004 11:13 am
by gnozal
griz wrote:It would be nice if the help file was a .chm so that Pure Basic would link to it in the IDE... :)
Well, yes, but the HTML help files work great with jaPBe !

Posted: Tue Oct 23, 2007 8:58 am
by gnozal
Update

Changes :
- added threadsafe version [PB4]
- updated help file

Posted: Tue Oct 23, 2007 1:58 pm
by jpd
Hi Gnozal,

if I'm use purevalid_check on me program is possible to check the integrity of the file (on the disk) or is possible to create a thread that check all "x second" if the loaded-file in memory integer?

sorry for me english, I hope you understand what I mean.

Thanks
jpd

Posted: Tue Oct 23, 2007 2:14 pm
by gnozal
jpd wrote:Hi Gnozal,
if I'm use purevalid_check on me program is possible to check the integrity of the file (on the disk) or is possible to create a thread that check all "x second" if the loaded-file in memory integer?
sorry for me english, I hope you understand what I mean.
PureVALID checks the EXE integrity (on the disk) by calculating a fingerprint and comparing it to a validation info located at the end of the EXE. It does not check the memory.
You can call the function PureValid_CheckFile() whenever you want.

Posted: Tue Oct 23, 2007 2:19 pm
by jpd
Ok,

Thanks Gnozal,


and Thanks for all your nice libraries!

Best
jpd

Posted: Tue Oct 23, 2007 3:03 pm
by Brice Manuel
I appreciate the 3.94 support, as I am still using it for most stuff :wink:

Posted: Thu May 22, 2008 1:15 pm
by gnozal
Update

(PB 4.2x version only)

Changes :
- recompiled with PB 4.20 final and latest tailbite

< EDIT JUN 6 2008 >

Posted: Tue Oct 14, 2008 7:23 pm
by Gansta93
Hello,

It doesn't work on PB 4.30... missing string-extention. :?

Thank you for this lib.

Posted: Wed Oct 15, 2008 7:41 am
by gnozal
Gansta93 wrote:It doesn't work on PB 4.30... missing string-extention. :?
http://www.purebasic.fr/english/viewtopic.php?t=34534

PureValid_500.zip missing...

Posted: Thu Nov 08, 2012 2:19 am
by akee