D-Bug & Automation Forum
D-Bug & Automation Forum >> Coding >> Hidden messages in code
http://d-bug.mooo.com/dbugforums/cgi-bin/yabb2/YaBB.pl?num=1257011785

Message started by ggn on 31.10.09 at 17:56:24

Title: Re: Hidden messages in code
Post by ggn on 31.10.09 at 18:06:04
APB


Quote:
To protect a program using a Copylock Key Disk:

1. INCBIN the binary file KEYDISK.OBJ, or INCLUDE the source file KEYDISK.S

   into the program code to be protected. When called from supervisor mode

   the serial number of the Key Disk will be returned in register D0.L and

   in the trace vector, address $00000024.

2. Copy all files onto the Key Disk, using the normal file copy method.

   If specific sectors of the Key Disk are to be written to do not over-

   write any sectors on track 0, with the exception of the boot sector.

   Do not re-format any of the tracks, doing so would render the disk

   useless as a Key Disk.

*-------------------------------------------------------------------------*


filename: KEYDISK.OBJ

filetype: relocatable 68000 binary code. It contains no header, relocation

          or symbol information.

purpose:

To check for the presence of a Key Disk and return the Key Disk's serial

number. The Key Disk is assumed to be in drive A:. The file can be included

in the assembly of source code files. Use the directive INCBIN, when

assembling with HiSoft's DEVPAC. The code should not be called as a sub-

routine, as no RTS is performed on exit.

Usage:

on entry,
     
     DISK DRIVE HEAD MUST BE OVER TRACK 0

     processor must be in supervisor mode

on exit,

        d0.l contains the 32 bit serial number of the Key Disk

        d0.l returns 0 if no Key Disk is found.

        all other registers preserved

Example
-------

* must be in supervisor mode
     INCBIN      keydisk.obj            returns serial no. in d0.l
     move.l      d0,serialno            .. or 0 if not a Key Disk
* rest of program


After calling the code, program control continues at the address after the

binary code. An RTS is not performed. The code may be called as often as

required.


*-------------------------------------------------------------------------*
*           Copylock ST - Disk Protection System for the Atari ST         *
*                                                                         *
*                 Documentation for KeyDisk.obj, 7 June 1989               *
*                                                                         *
*       (C)Copyright 1989 Rob Northen Computing. All Rights Reserved.     * 
*---------------------------------------------;

dc.l $60720000,$00000000,$00000000,$00000000,$00000000,$00000000,$00000000,$00000000
           dc.l $00000000,$00000000,$00000000,$00000000,$00000000,$00000000,$00000000,$00000000
           dc.l $00000000,$00000000,$00000000,$00000000,$00000000,$00000000,$00000000,$00000000
           dc.l $00000000,$FFFFFFFF,$00000000,$00000000,$00000000,$2F0E4DFA,$FF8A48D6,$FFFF4DEE
           dc.l $00402D5F,$FFF82039,$00000010,$487A000A,$23DF0000,$00104AFC,$23C00000,$00104CF9
           dc.l $00FF0000,$000848D6,$00FF41FA,$008423C8,$00000010,$41FAFFB6,$20884AFC,$D503DF79
           dc.l $40862ADA,$B525BF1B,$20E44AF0,$D50FDF31,$40CE2AF6,$B509BF2B,$20D44AD8,$D527DF6D
           dc.l $40922AF2,$B50DBF7B,$20844AE4,$D51BDFD3,$402C2AFA,$B505403D,$DFC24AC8,$D537DFFF
           dc.l $4000D51A,$4AE54025,$DFDAB50C,$2AF3DF9F,$4060D50A,$4AF54031,$DFCE4ABC,$D543DFD7
           dc.l $4028D506,$4AF94039,$DFC64AC4,$D53BDFD7,$48E780C0,$41FA0034,$23C80000,$002441FA
           dc.l $057C23C8,$00000020,$06AF0000,$0002000E,$002F0007,$000C086F,$0007000C,$43FAFF0E
           dc.l $671A2051,$20A90004,$6026027C,$F8FF48E7,$80C043˜

FA,$FEF82051,$20A90004,$206F000E
           dc.l $22882350,$00042028,$FFFC4680,$4840B190,$4CDF0301,$4E739275,$FCFE0004,$0000007C
           dc.l $BE79FFE1,$22624186,$0008B60D,$40B1CF49,$42B68F51,$A2227F1C,$D12BA22B,$3DD42EC6
           dc.l $06C80688,$00BC0708,$07480648,$06E800F6,$F330F9ED,$0000013D,$98D054D3,$9E3C0000
           dc.l $007CDC7F,$FFFF001F,$0000013C,$BF39FD31,$63CE4150,$CAA94556,$E92B718A,$FE74608B
           dc.l $8E17161A,$C6E5491C,$D7E33942,$A1557CB5,$13CB87D6,$B8D5EC50,$936EDCAD,$13AD8184
           dc.l $0C7E8381,$70EEA1EE,$6220FB15,$0842D3B0,$72740004,$993B6A6C,$979E6E20,$00089941
           dc.l $6A16BC98,$6D70000C,$995FB638,$AE5F0069,$B63D0838,$0278DCC7,$F7DB6924,$225CBDA3
           dc.l $94F523ED,$321CACE3,$DC0269BD,$F1407CBF,$A3411061,$814E30C4,$FCC77E35,$00FF8606
           dc.l $4A39FFFF,$860459F3,$B5CC7904,$860D997A,$7545790D,$860B997C,$7543790B,$86094A0A
           dc.l $866400FF,$86064A05,$FE9000FF,$86064A05,$FF9000FF,$86064A05,$FF1600FF,$86044A07
           dc.l $FF8000FF,$86063A00,$FFFF860B,$0BF4D003,$09C0F40D,$1A80AF83,$33FC0080,$00FF8604
           dc.l $53836732,$01090000,$B44067F4,$06820000,$02005281,$01090000,$B44066F6,$53836716
           dc.l $08390005,$00FFFA01,$66F24AFC,$D4039869,$65D62BEC,$9A660499,$D5515A51,$EBDB27D8
           dc.l $A52800FF,$86064A3B,$FFFF8604,$49C70014,$9EEBB6C2,$222DEDE8,$B417A8A0,$16A5B6CE
           dc.l $78B3E95A,$66A5D72F,$5A84C47B,$29DEDE21,$3B86A269,$2DF6B309,$5D42C9B9,$65C7FCD6
           dc.l $73D6C25C,$49F72289,$ED4C4AF0,$5687E882,$49FBF474,$177DDB7E,$0B0900FF,$860609F9
           dc.l $C5C67906,$8604378E,$8096997B,$277E83B5,$4CF3D881,$043EAB38,$277E043E,$C83DD803
           dc.l $00FF8606,$4DC0FFFF,$86043801,$FCBC33C1,$AD3E036F,$8C90126F,$FCE44FC4,$EC975D1D
           dc.l $EA05F3E8,$382DE958,$77A73886,$A679881C,$4419A51E,$0000043E,$B71EFEF8,$4F7280B7
           dc.l $FD85507A,$4C8DB332,$AF855A7A,$4CCAB135,$A5821081,$13FC000E,$00FF8800,$123900FF
           dc.l $88000201,$00F88200,$13C100FF,$88024AFC,$FB764C6E,$7503BAC0,$890917F6,$4553AA90
           dc.l $E80E76F1,$AAA11981,$890D3887,$C73876F1,$BAF23847,$00FF8606,$4A39FFFF,$860459C7
           dc.l $00060000,$F7C6FFFC,$00FFFA01,$62DACEA5,$57A8C957,$315CBE5C,$0FD6C3D5,$


D-Bug & Automation Forum » Powered by YaBB 2.6.0!
YaBB Forum Software © 2000-2024. All Rights Reserved.