Copy Protection

How I can protect my application against copying?

May be exist many ways. One of theme is using HD serial number.

1. Read volume serial number of hard disk(s) of your customer. ( Apply this procedure while installation, once only one and preferably manually.  Of course you can obtain this info by online accessing to system of your customer. )

2. Record this info ( after crypt ) anywhere you like in the customer system: in a .MEM file, a .dbf / dbt, in registry, even directly into your application as a literal constant.

3. Your application will begin to run by reading this recorded data and compare it with actual HD serial number of customer; if match continue working, else …

Here an example to get  HD serial number.

Volum Info

* Harbour Example lists the volume serial numbers 
* and volum labels of all drives in the system ( PC ) 
*
* Build :
*
*          c:\harbour\bin\hbmk2 VolInfo -lhbct -lxhb -run
*
PROCEDURE Main()
   LOCAL nDrive, cDrive, nSerial, cSerial
   SetMode( 25, 80 )  
   CLS
   SETPOS( 5, 0 )
   FOR nDrive := 1 TO 26
      cDrive  := CHR( 64 + nDrive ) + ":\"
      nSerial := VolSerial( cDrive )
      IF nSerial # -1
         cSerial := NTOC( nSerial, 16 )
         ? cDrive, STUFF( cSerial, 5, 0, ":" ) + " " + GetVolInfo( cDrive )
      ENDIF
   NEXT
   @ MAXROW(), 0
   WAIT "EOF VolInfo.prg"
RETURN