Release Notes – WannaClone

Goodness dear reader, it’s been a very long time since the last C64CD demo release so here’s a new one for the C64 called WannaClone. There are a couple of inspirations for this release, with the primary one being a thread at the Atari Age forums called “screwing with pirates” where the initial post from user 2600problems features a BASIC-driven password protection for the C64 which… well, let’s charitably say it wouldn’t work, in part because the password can be found or overridden simply by looking through the program.

But the subject of encryption came up in said discussion and, since your correspondent has experimented with this a little in the past, that seemed like a good enough excuse to write a little practical example. The text for the scrolling message in WannaClone has actually been encrypted in a reasonably loose sense of the term; each character is exclusive ORed with a byte from the first 256 in the music routine before a “seed” value is added to it, neatly turning plain text into guacamole when looked at in memory. The result from each pass is then used as the seed value for the next one, so changing the encrypted text itself, the initial seed value or that block of the music being used will completely garble things. The text is stored as raw data in the binary directory for those wanting to examine it further, there might even be something extra in there…

WannaClone (C64)This exercise shouldn’t be taken anywhere near seriously of course because it wouldn’t require ridiculous amounts of work to circumvent the encryption (especially since the source code containing the “magic number” $6A which is used to set things rolling is readily available[1]) but the principle could at least be expanded to perhaps using the characters of a password as initial seed values instead.

We haven’t even approached the question of why such a “protection” would actually be required on 8- or 16-bit software and, although your correspondent asked within the thread, he didn’t receive an answer so will instead leave it to the reader to ponder. This demo does at least serve as a questionable excuse to do the WannaCrypt joke again and a couple of small but potentially useful Windows-based tools for processing data were written so that’s… something?

[1] The number $6A wasn’t chosen at random, it’s 106 in decimal and your correspondent is a fan of Jeff Minter’s 8-bit games; shooting a camel in some of those titles would award the player with 106 points, a reference to an American radio station.

This entry was posted in Programming and tagged , , , , , , , , , , , , . Bookmark the permalink.