Path: utzoo!attcan!uunet!digibd!steve From: steve@digibd.com (Steve Wahl) Newsgroups: comp.sys.amiga Subject: Re: Populous for all Amigas! Message-ID: <1990Oct18.172121.878@digibd.com> Date: 18 Oct 90 17:21:21 GMT References: <32943@nigel.ee.udel.edu> <7814@ucdavis.ucdavis.edu> Organization: Digiboard Incorporated, St. Louis Park, MN Lines: 42 In article <7814@ucdavis.ucdavis.edu> zerkle@iris.ucdavis.edu (Dan Zerkle) writes: >In article <32943@nigel.ee.udel.edu> lawsonse@vttcf.cc.vt.edu (Shannon Lawson) writes: >> >> [ Populous copy protection code fails on {680x0|x>0} ] > >In the beginning of the RKM Libraries and Devices, there is a note that >says to never use self-modifying code. In order to make copy >protection harder to remove, loaders often encrypt those parts of the >code which deal with the copy protection, then decrypt it right before >execution. This is practically an automatic lose for any CPU that has >an instruction cache but no coherency scheme. The MC68020 and 030 both >have instruction caches built-in. These caches are not written to when >the memory to which they correspond is modified, so coherency is lost >when modifying code in the instruction cache. Since whatever is >remaining in the caches has not been decrypted, the CPU is basically >executing garbage, and the machine crashes. Ok. Does anyone care to explain to me how the ENCRYPTED version of the code got into the INSTRUCTION-ONLY cache? I don't think this argument works, because the encrypted stuff would have to be executed to be in the cache. Hmm.. I guess it could be that the first few instructions immediately follow the decrypting routine, so that some prefetched instructions get into the cache. If only they could keep the encrypted code some distance from the decryption code! I'd bet that software timing loops cause most of the problems, however. Any copy-protection crackers out there want to comment on this? C'mon, I'm willing to believe that you crack copy protection only for the challenge, or because you wanted to get that program onto the hard disk (lord knows I've got some of these!) or to get rid of the key disk or... > Dan Zerkle zerkle@iris.ucdavis.edu (916) 754-0240 > Amiga... Because life is too short for boring computers. --> Steve -- Steve Wahl steve@digibd.com DigiBoard Inc. St. Louis Park, MN (612) 922-8055