WEBVTT

00:00.000 --> 00:03.900
You can bet you're behind that I am here for this talk.

00:04.040 --> 00:10.260
I actually have known a little bit more about this talk for a long time while Wes was working on this.

00:10.560 --> 00:16.220
Wes is a wonderful friend of everybody's here.

00:16.720 --> 00:24.780
Wes and I work in similar fields in digital forensics and are fairly casual about things.

00:24.780 --> 00:33.520
And I think this is gonna be a casual and fun talk that is just gonna be a blast that you bet your ass I'm gonna stay around for.

00:33.520 --> 00:38.120
So everybody give Wes a big round of applause and let's have a good time.

00:38.420 --> 00:39.180
Thank you.

00:39.660 --> 00:41.500
Thank you so much.

00:41.680 --> 00:42.920
Thank you everybody.

00:42.920 --> 00:43.680
I appreciate it.

00:43.680 --> 00:45.420
We're just gonna hop right into this.

00:45.420 --> 00:47.160
So this is Amber64.

00:47.220 --> 00:51.580
We're mining hacker history from over half a million Commodore 64 disks.

00:51.580 --> 00:53.560
It's all the ones I could find.

00:53.920 --> 01:01.080
I'm a senior cyber fellow at Martin Fed and they're very confused about why I'm giving this talk.

01:01.500 --> 01:13.900
So our agenda for this, what we're gonna talk about, we're gonna give a little background on 80s computing though it seemed like the majority of y'all raised your hands when I asked if you grew up with those things so I might not even have to do much of that.

01:14.020 --> 01:17.660
I'm gonna talk about this corpus of disks that I've collected up.

01:17.660 --> 01:19.800
This is by hash unique.

01:19.800 --> 01:27.400
And so if there is one bit difference in these disks, then it's a different disk, it goes into the data set.

01:27.400 --> 01:33.080
I don't care how many copies of Commando I have, it's a lot of copies of Commando.

01:33.240 --> 01:42.520
We're gonna talk about why you would want to do forensics across 20,000 different versions of Commando and we're gonna talk about the deep dive details of this.

01:42.520 --> 01:45.420
How many of you just played games on your Commodore 64?

01:45.420 --> 01:48.300
Okay, how many of you coded on the thing?

01:48.580 --> 01:52.340
Okay, you're gonna really love some of this deep dive stuff here.

01:52.800 --> 01:54.740
I'm gonna talk about Elasticsearch.

01:54.740 --> 01:56.380
How many of you used that?

01:56.380 --> 01:59.220
I had to get chat GPT to help me out with that part.

01:59.220 --> 02:16.620
But anyways, we're gonna push this stuff into Elasticsearch so that we can do essentially order one searches across this data set really quickly and get data back on our searches so we can continue the analysis.

02:16.620 --> 02:20.720
We're gonna talk about some weird stuff we found and what you could do from here.

02:21.160 --> 02:25.900
Computing in the 80s, this is what you did with your Commodore 64 back in the day.

02:25.900 --> 02:32.760
Hacking, freaking, gaming, pirating software, nobody had legitimate copies of any games, right?

02:32.760 --> 02:36.280
Somebody bought it, but I sure didn't.

02:36.580 --> 02:44.720
The games that we have today that have been preserved are preserved due to piracy, right?

02:44.820 --> 02:53.600
Software pirates cracked the protection on them so that it could be copied and the copies that we have today are largely those pirated copies.

02:53.760 --> 03:01.740
Hackers and freakers, people who hacked into the phone networks, it's been a while since we've had a freaking talk here, I guess.

03:01.840 --> 03:08.960
The hacking and freaking that happened on this, you could actually use your Commodore 64 for freaking.

03:08.960 --> 03:11.960
You could generate the tones that you needed to on that.

03:11.960 --> 03:16.100
We're going to talk about bulletin boards which are sort of your proto forum mailing list.

03:16.100 --> 03:27.120
You dialed into it with a modem, you had message boards, you had file trading, there were cross platforms so you could talk to all the nerds that were stuck on their TRS-80s.

03:27.560 --> 03:36.320
And we're going to talk and there was motivation there for the freaking and hacking because you wanted to be able to dial long distance into those bulletin board systems.

03:36.780 --> 03:38.960
And there's also the demo scene here.

03:38.960 --> 03:49.380
This is hacking in the sense of pushing the system to do more and more and more artistically which was a really cool beginning of that scene which continues to this day.

03:49.420 --> 03:53.760
The piracy, lots of different cracks for different software.

03:53.900 --> 04:10.720
There was a distribution mechanism by trading, by taking the software you downloaded from one bulletin board system, say you had a calling card code that you used to dial into a BBS overseas, you downloaded the latest game that got released in the UK,

04:10.720 --> 04:22.520
you uploaded it to your local BBS in the U.S., you're a distributor at that point and you got special access to other things people downloaded.

04:22.520 --> 04:28.600
There's groups surrounding the cracking and distribution of pirated software and it was mostly for bragging rights.

04:28.600 --> 04:32.760
This is not largely a for profit endeavor.

04:33.080 --> 04:41.700
And this piracy of games and software was the motivation for a lot of this other activity, this hacking and BBSs and demo scene.

04:41.700 --> 04:42.380
That's it.

04:42.380 --> 04:49.180
Because after this, pornography became what defined new technology.

04:49.180 --> 04:55.580
The internet becomes faster, new technology and video codecs and everything is meant for distributing pornography.

04:55.580 --> 04:57.820
The pornography wasn't very good yet.

04:57.820 --> 05:00.320
And so it was all pirated games.

05:01.320 --> 05:06.240
The Commodore 64 itself, you're looking at it, you used one most of y'all it seems.

05:06.240 --> 05:10.660
It held the Guinness Book World Record for the highest selling single computer model.

05:10.660 --> 05:16.880
Good old Jack Tramiel, owner of Commodore, lied his ass off about how many they sold.

05:16.880 --> 05:18.520
They were saying like 30 million.

05:18.520 --> 05:21.600
But even the conservative estimates break the record.

05:21.940 --> 05:25.780
We can figure about 12 and a half to 17 million.

05:25.940 --> 05:29.220
The production run of this, you're going to be surprised by this.

05:29.220 --> 05:33.660
August of 1982 to April of 1994.

05:34.380 --> 05:42.600
That is a huge production run for an 8 bit microprocessor computer and it's ended when Commodore ended.

05:42.640 --> 05:46.940
And that outlived every single other model a computer ever made.

05:46.940 --> 05:51.740
It lasted right up to the end, right alongside the Commodore Amiga.

05:51.960 --> 05:55.480
Keyboards built into the computer, you're looking at the computer right here.

05:55.700 --> 06:06.200
The output of it is composite video so you can hook it up to a TV, you can hook it up to a nicer Commodore branded monitor that did a good job on no color bleed and stuff.

06:06.400 --> 06:08.620
And a huge library of games.

06:08.700 --> 06:17.260
It's not like a console gaming system where you can just go download every ROM for the NES and there's an itemized list of every NES ROM.

06:17.260 --> 06:20.120
For the Commodore 64, you could write your own software.

06:21.740 --> 06:31.220
It's an uncountable number of games because some kid, like I, wrote a video game at home and traded it among five friends and it's lost forever, right?

06:31.220 --> 06:35.620
And there's a lot of lost software out there and we're going to find some of it here.

06:35.620 --> 06:50.540
It's the first computer for hackers about my age and older and it was your first opportunity to connect to modern BBS, to connect via modem to BBS's online services.

06:50.540 --> 06:53.840
Q-Link, that's the predecessor to AOL.

06:54.260 --> 06:57.460
And if you don't know what AOL is, we don't have time for that.

06:57.460 --> 07:00.620
I'll do another talk on the AOL scene sometime.

07:01.680 --> 07:13.180
The most common disk drive for this is the Commodore 1541, which is a five and a quarter inch floppy and a very interesting drive indeed.

07:13.180 --> 07:15.720
And if you're in the U.S., this is a very common thing.

07:15.720 --> 07:18.100
You probably had this disk drive.

07:18.100 --> 07:23.800
If you were overseas, in Europe, it was actually probably more common to have the tape drive.

07:24.180 --> 07:31.780
But there's a lot of work between converting tape games over to run off of single load disks and stuff like that.

07:33.340 --> 07:41.340
What you had if you had a Commodore 64 and a 1541 disk drive, you had two computers and you probably didn't even realize it.

07:41.560 --> 07:45.760
The first computer was your computer, your C64.

07:45.940 --> 07:55.820
It ran MOS 6510, which is a variant of the Commodore 64 with just some very simple memory bank add‑ins.

07:56.640 --> 07:59.460
It had 64 kilobytes of memory space.

07:59.460 --> 08:07.600
So it had a 16‑bit address bus and each address can hold a byte.

08:07.600 --> 08:09.600
So that means 64 kilobytes of memory.

08:09.600 --> 08:13.300
So they basically maxed out without paging RAM.

08:13.300 --> 08:16.480
So if you had an address, it could be mapped to RAM.

08:16.660 --> 08:26.460
You also had 20 kilobytes of ROM and you're thinking, wait, if you filled up that 64K address space with RAM, where's the ROM?

08:26.460 --> 08:29.640
It gets shadowed in on top of RAM.

08:29.640 --> 08:35.000
So there's portions of RAM you don't access normally because the kernel ‑‑ and I did not misspell that.

08:35.000 --> 08:39.440
That's how Commodore misspelled it in their original documentation.

08:39.700 --> 08:41.540
They misspelled it.

08:41.540 --> 08:42.800
They were called out on it.

08:42.800 --> 08:45.540
They're like, we meant to do that.

08:45.700 --> 08:52.800
So they committed to it and called it the kernel with an A for the rest of the existence of Commodore.

08:52.800 --> 08:57.220
They actually came out with an acronym for it just to try to cover for themselves.

08:57.520 --> 09:01.640
You had the kernel, which is sort of support routines, input, output.

09:01.640 --> 09:12.140
You had the basic interpreter and you had the ability to switch those in and out of memory so that you could take the basic interpreter out of memory and use it as RAM.

09:12.400 --> 09:23.380
And neat things, like if you wanted to write ‑‑ if you wrote to kernel memory or you wrote to basic memory, it wouldn't change the ROM, of course, but it would write to the RAM underneath it.

09:23.380 --> 09:25.720
So you could do some really clever stuff with that.

09:26.880 --> 09:31.520
This is one of the first personal computers that had coprocessors in it.

09:32.020 --> 09:33.960
The VIC‑II was for graphics.

09:33.960 --> 09:38.760
It had very good graphics for a computer, much better than any other home computer at the time.

09:38.760 --> 09:45.240
And for a while until your IBM PCs and Amigas ‑‑ like your IBM PCs start getting EGA and VGA graphics.

09:45.240 --> 09:49.780
Your Commodore Amigas, of course, came out of the gate smashing with great graphics.

09:50.740 --> 10:00.880
The real standout here is the SID chip, which if you're a synthesizer nerd, you already know what this chip is and you've probably pulled one out of a Commodore to put into a synthesizer.

10:00.980 --> 10:03.820
It's a digitally controlled analog sound.

10:03.820 --> 10:13.120
So memory mapped registers to control an analog synthesizer in a computer that's a keyboard, right?

10:13.120 --> 10:16.320
So people made guitars out of these keyboards, right?

10:16.900 --> 10:23.200
The way we communicate with other drives and stuff is over a serial IEC bus.

10:23.200 --> 10:25.120
So it's a serial bus.

10:26.440 --> 10:32.640
Instead of having multiple lines like a normal IEC bus, it only has one.

10:32.640 --> 10:35.880
So it's sending single bits at a time.

10:36.180 --> 10:38.120
And then you have your floppy drive.

10:38.120 --> 10:41.600
Your floppy drive was also a computer.

10:41.600 --> 10:44.160
It had a compatible processor.

10:44.160 --> 10:54.980
It had a 6502, which is the 6510 with some of that paging taken out of it, running at one megahertz, two kilobytes of RAM, 16 kilobytes of ROM.

10:54.980 --> 10:59.880
They didn't have to map on top of each other because it had that whole address space out across.

11:00.020 --> 11:02.140
And in ROM was Commodore DOS.

11:02.160 --> 11:13.920
That 1541 drive, when you turn it on, it's a computer, it boots up, it's doing its own thing independently, parallel of the main computer, and it talks to that main computer over a serial IEC bus.

11:14.380 --> 11:22.720
The five and a quarter inch floppies were formatted to have 170 kilobytes worth of data per floppy disk, and it was slow.

11:24.020 --> 11:34.100
And so there's a whole market of fast loaders that replaced elements of Commodore DOS, firmware replacements like Jiffy DOS and things like that.

11:34.100 --> 11:39.140
But ultimately, they were all more or less compatible and had the same sort of disk format.

11:40.240 --> 11:44.980
What happened when you bought a box of floppies for your Commodore 64?

11:44.980 --> 11:47.240
You copied stuff to them.

11:47.460 --> 11:51.200
And so you formatted the disk, and there's a cycle.

11:51.220 --> 12:02.520
You download some software from a BBS, or you copy it from a friend, and you do that until the disk fills up, or you've got a game on there that doesn't like being on there of other games, right?

12:02.720 --> 12:10.100
There wasn't any folders on these disks, and so you just kept dumping game files into the same directory until they complained, right?

12:10.220 --> 12:12.140
Or you filled up the disk.

12:12.620 --> 12:16.600
You started playing the and, you know, there's like 20,000 games.

12:16.600 --> 12:18.940
Most of them are pretty shit, honestly.

12:19.200 --> 12:20.740
And you delete the bad ones.

12:20.740 --> 12:21.720
You keep the good ones.

12:21.720 --> 12:27.120
You keep, you know, your mini golf and your Commando and everything, and you throw away the rest of them.

12:27.960 --> 12:32.320
And then when you fill up the disk, you put it in the box.

12:32.320 --> 12:35.700
You give it a name, or you don't label it at all.

12:36.200 --> 12:39.640
And you just keep on trucking with the next disk, right?

12:39.940 --> 12:41.980
But you might also have other data.

12:41.980 --> 12:47.700
You might have text files in there if you're interested in hacking and downloading text files from public BBSs.

12:47.700 --> 12:51.440
Those text files may or may not be written for the Commodore 64.

12:51.860 --> 12:55.040
You will record your BBS sessions.

12:55.040 --> 12:58.800
Remember this for the future slides in here.

12:58.980 --> 13:07.360
Because you're trying to cut down on long distance time, you will record your BBS sessions so that you'd go through them fast.

13:07.360 --> 13:18.380
You read all the messages all at once that you haven't read on that BBS since the last time you logged in, and then disconnect so you can sit there and read it and figure out what you're going to respond back in that flame war.

13:18.440 --> 13:24.900
Or you're going to get the list of files and figure out which thing you're going to download next, because you're committing to something.

13:24.900 --> 13:27.060
These are slow modems, right?

13:27.240 --> 13:34.520
And so you have these BBS logs, but then you slide back up to the top of this cycle and you download more.

13:34.560 --> 13:39.820
And you don't need that BBS log anymore, so you delete it to get the space back.

13:39.820 --> 13:47.740
And if you're into digital forensics, you're sitting here thinking, oh man, I'm really sort of leaving artifacts all over this disk, ain't I?

13:49.400 --> 13:53.820
If we start talking about disk images, here's where you get them.

13:54.020 --> 13:58.680
None of these that I acquired are anything that I imaged personally.

13:58.780 --> 14:01.000
These are all from different projects on the internet.

14:01.000 --> 14:02.840
You can get these as well.

14:02.880 --> 14:06.980
I will not be publishing the disk image set publicly.

14:06.980 --> 14:16.220
I'll provide it to researchers and such, because it's a bit of a mess and I don't want to contribute to the already included mess of stuff that's out there.

14:16.220 --> 14:24.220
But you can piece it together yourself and I can help you out with individual files or if you've got a research interest in a larger set, I can manage to get it to you.

14:24.220 --> 14:25.680
It's about 70 gigs.

14:26.280 --> 14:30.620
But the TOSEC, they're focused on games and applications.

14:30.620 --> 14:42.380
They will ‑‑ they'll get disks of every single game and every single application that's known to exist for the Commodore 64 and collect them and label them.

14:42.380 --> 14:45.660
The C64 preservation project does the same thing.

14:45.660 --> 14:48.100
Internet archive has collections.

14:48.120 --> 15:05.440
The Commodore scene database is really cool because they have like a release number, but in their forums, there's a bunch of old software piracy guys, a bunch of old software copy protection crackers there that have their old disk sets from back in the day.

15:05.520 --> 15:13.820
And they will sit around and after they pass away, it will be passed on to somebody who will do this.

15:13.820 --> 15:16.860
They will image their entire collections.

15:16.860 --> 15:19.680
So it will be thousands of disks from one person.

15:19.680 --> 15:22.060
You'll see some of these collections in TOSEC.

15:22.060 --> 15:23.560
You'll see them elsewhere.

15:23.560 --> 15:30.120
But in that thread on CSDB, you can find an FTP site that has all of these things.

15:30.120 --> 15:33.240
And so there's lots of unlabeled disks in that set.

15:33.240 --> 15:41.600
FTP sites that are just ‑‑ have always been around since the Commodore days, Zimmers, Arnold, Padua that collect disk images.

15:41.740 --> 15:46.680
There's the Lodestar magazine which I grew up reading on my Commodore 64.

15:46.680 --> 15:49.180
Learned a lot of programming from that magazine.

15:49.180 --> 15:51.100
Disk‑based magazine.

15:51.100 --> 15:55.620
About 250 issues, 260 issues, something like that.

15:55.760 --> 16:05.080
And each issue was four sides of floppy ‑‑ like two double‑sided floppy disks with articles and games and programs and things like that.

16:05.080 --> 16:07.220
It was so much fun to go through.

16:07.220 --> 16:07.900
Right?

16:07.900 --> 16:09.200
And so that's in this set.

16:09.200 --> 16:11.000
I won't provide that to you.

16:11.000 --> 16:14.920
You need to give 15 bucks to Fender Tucker who has the rights to that.

16:14.920 --> 16:15.900
He's awesome.

16:16.600 --> 16:19.060
And then just other stuff I've done.

16:19.060 --> 16:20.580
I shot 256 of them all.

16:20.580 --> 16:22.280
I deduplicate them.

16:22.680 --> 16:26.040
And it's just an overwhelming quantity of a mess of disks.

16:27.260 --> 16:30.720
And so for each disk, we got to think of it as a collection of artifacts.

16:30.720 --> 16:35.440
You have the apparent things that are on it which is the label printed on the disk, right?

16:35.440 --> 16:38.060
This disk has Frogger on it, right?

16:38.360 --> 16:42.320
This disk has a Commando on it.

16:42.320 --> 16:44.020
What's on there?

16:44.020 --> 16:47.180
Then there's what's ‑‑ the first program on the disk.

16:47.720 --> 16:53.360
The Commodore 64, your command for loading the first program off the disk is what most people know.

16:53.360 --> 16:55.000
It's like a cultural thing now.

16:55.000 --> 16:57.880
Load star comma eight comma one.

16:57.880 --> 17:00.720
Loads the first game up so that you can run it .

17:01.880 --> 17:05.960
But what you might not know is there's other files on the disk more than likely.

17:06.320 --> 17:18.420
And if you don't know any other commands for your Commodore 64 than that, you might miss that there's a directory that you can get with other mixed programs mixed into that same directory.

17:19.200 --> 17:20.640
Then there's hidden stuff.

17:20.640 --> 17:21.920
There's unlabeled disks.

17:21.920 --> 17:28.500
There's such a mass of unique unlabeled disks out there that you can't really be sure what's on them.

17:28.760 --> 17:32.580
There's extra files that have nothing to do with the games that are on the disks.

17:32.580 --> 17:35.240
And some of them are docs that people have written.

17:35.340 --> 17:36.900
There's deleted files.

17:36.900 --> 17:40.840
We know from in a modern context, if you delete a file, it's not really gone.

17:40.840 --> 17:42.120
It's just marked as deleted.

17:42.120 --> 17:44.320
It's the same thing on here.

17:45.640 --> 17:49.460
Unallocated and orphaned space where programs will just write stuff.

17:49.460 --> 17:51.340
And then general shenanigans.

17:51.980 --> 17:58.340
You could rewrite the way the drive treated disks for copy protection purposes.

17:58.340 --> 18:03.960
You could do strange things and just write things to sectors because it's not going to stop you from doing that.

18:03.960 --> 18:08.660
And so there are things that sort of violate the rules of file systems on here.

18:08.980 --> 18:16.840
If you have half a million disk images, if you think of something weird you could do of a Commodore disk, one of those disk images has.

18:16.840 --> 18:21.020
And because I had to do that when I was writing this code, I had to handle all those edge cases.

18:21.020 --> 18:31.800
And so I'd write my code, I'd run it across the entire corpus, find a disk that broke my code, and then figure out what the hell are they doing with a Commodore disk that makes my code break.

18:31.960 --> 18:33.640
Iterate, iterate, iterate.

18:34.580 --> 18:36.400
Why do I want to do this?

18:36.400 --> 18:39.280
Because it just called to me, right?

18:39.280 --> 18:43.040
Like, you know, I grew up with this system.

18:43.040 --> 18:45.360
I love tinkering around with it.

18:45.360 --> 18:48.240
And I just love playing around with this stuff.

18:48.240 --> 18:50.860
But really, there's lost media out there.

18:50.860 --> 18:58.720
There's games that are just kind of you see advertised in scans of old magazines that aren't in Tosec, right?

18:58.720 --> 19:00.360
Where did that game go?

19:00.360 --> 19:01.160
Maybe it's crap.

19:01.160 --> 19:02.600
It's probably crap.

19:02.600 --> 19:05.460
But it would be good to preserve it.

19:05.460 --> 19:07.300
There's all this work that people have done.

19:07.300 --> 19:13.000
I don't know, millions and millions of man hours of work in all of this code and everything.

19:13.760 --> 19:16.280
You know, it's a shame nobody is looking at it.

19:16.580 --> 19:22.380
There's hidden text in games that developers put there to taunt people cracking copy protection.

19:22.560 --> 19:23.600
That's fun.

19:24.340 --> 19:26.560
Cutting room floor documents a lot of that.

19:26.560 --> 19:28.800
So in a lot of known games, that stuff is known.

19:29.300 --> 19:32.880
There's multiple versions of software, some of which aren't documented.

19:33.120 --> 19:37.080
And then there's the ephemera, the communications, user generated files.

19:37.260 --> 19:40.540
And then what I like to call hacker history, which is interesting here.

19:40.540 --> 19:44.760
Things related to BBSs, freaking codes, piracy, cracks.

19:44.900 --> 19:47.760
So pirating calling card codes.

19:47.880 --> 19:58.160
Back in the day, you would get a calling card code so that if you were at a pay phone, you could charge a call to your calling card account and so you can make a long distance call from any pay phone you found.

19:58.160 --> 20:03.280
Or you could charge long distance calls to this thing or to a corporate code or something like that.

20:03.280 --> 20:06.800
You could write, you could scan for those codes and do them.

20:08.300 --> 20:11.120
So what can we apply from our modern day stuff?

20:11.120 --> 20:16.060
File system forensic analysis, parsing metadata, recovering deleted files.

20:16.160 --> 20:25.240
And what we really want to do is it takes a long time to search through half a million disks and so we want very fast search.

20:25.240 --> 20:29.660
So we needed to build an index of printable text inside of these disks.

20:30.280 --> 20:32.660
And that's complicated in this environment.

20:34.480 --> 20:40.580
Here's a little tutorial on how the 1541 lays out data onto a disk .

20:40.580 --> 20:46.700
This book, Inside Commodore DOS by Emmers and Newfield is really the source for this.

20:46.700 --> 20:51.060
And this section is called why can't I just use strings and grep on these disk images?

20:51.060 --> 20:52.900
You can a little bit.

20:52.940 --> 20:56.780
The proof of concept was strings and grep, right?

20:56.780 --> 20:59.980
But there's reasons why this won't work in the general sense.

21:00.380 --> 21:06.200
If we look at a Commodore 64 disk, it's 35 concentric tracks on a disk .

21:06.260 --> 21:11.600
Each concentric track contains a set of 256 bytes sectors.

21:11.900 --> 21:17.940
And the number of sectors per track varies per which track it's on, right?

21:17.940 --> 21:26.380
And so the inner more tracks have fewer sectors than the outer ones because there's more space on the disk on the outer tracks, right?

21:26.700 --> 21:34.360
If you were to look at the magnetic fields, and you can, there are disk images that do record all the magnetic data.

21:34.360 --> 21:43.300
You'll see like weird skewing of this and everything, but generally you have them sort of evenly spaced around like this.

21:43.300 --> 21:52.960
You have four zones, so your outer tracks have 21 sectors per track.

21:52.960 --> 21:55.800
Your innermost one has 17.

21:56.780 --> 22:00.540
And so if you're parsing these, you kind of have to pick this up.

22:00.960 --> 22:04.340
Here's what it looks like magnetically on the disk.

22:04.380 --> 22:18.920
If you were to take a magnetic flux reading of the disk, which some people have done, we're not super interested in this level because the data is in that data block.

22:19.340 --> 22:32.300
Shenanigans are made in this kind of layer here where you have a header block ahead of that data, sync marks to make sure that the disk knows where it's at, where the head knows where it's at on the disk and so on and so forth.

22:32.360 --> 22:39.880
There's information in there, but it's usually things that people have done weirdly to disks to keep them from being copied easily.

22:40.200 --> 22:42.680
And so we're not super interested in that.

22:42.680 --> 22:54.400
What I would do if I had G64 or nib files for this magnetic flux imaging, I just had a script convert them over to D64s and just have the sector data for my processing.

22:54.500 --> 22:57.900
If you really wanted to dig in, there might be some more data in this.

22:58.520 --> 23:02.120
So we're looking at this 256 data bytes.

23:03.080 --> 23:05.460
The directory track is where you start.

23:05.460 --> 23:06.920
That's track 18.

23:06.920 --> 23:11.920
Track 18 sector 0 is what we see diagrammed out here.

23:11.920 --> 23:20.840
And when we look at file systems, you go back to Brian Carrier's file system forensic analysis with the concepts of essential data and non-essential data.

23:21.120 --> 23:27.320
Something that's required to be accurate for you to parse the disk correctly and stuff that could be different, right?

23:27.320 --> 23:31.440
Stuff that can change and not required to be accurate and just still work.

23:34.220 --> 23:42.540
You have a block availability map, which is like the FAT on a FAT file system where you're basically marking sectors as used or unused.

23:42.540 --> 23:47.380
And so you can keep the operating system from using a sector that's marked as used.

23:47.940 --> 23:51.600
And this is the first example of what we call sector chaining.

23:51.600 --> 24:02.880
On each of these 256-byte sectors, the first two bytes of that sector identify the next track and sector that continues the chain, right?

24:02.880 --> 24:10.240
And so you can't just go from sector or from track 18.0 to track 18.1.

24:10.240 --> 24:19.220
You follow the sector chains to go track 18.0 and it's probably going to be track 18.4 or 6 or something like that.

24:19.220 --> 24:24.900
And there's an algorithm for this and the reason why they're not contiguous is because the disk is spinning.

24:24.900 --> 24:36.320
The disk is spinning, the head is reading it as it's spinning and so as that head is spinning, you're reading a sector, you're processing it and then you're reading another sector.

24:36.320 --> 24:42.860
If it has to wait for that next sector to come back around to read it, then that's slow.

24:42.860 --> 24:54.740
If we can say the next sector is going to be four or five sectors down the road, basically by the time you finish processing this sector, the head's already five sectors ahead.

24:54.740 --> 25:01.240
Well, the next data item that we want for this file or this directory entry is going to be there instead.

25:01.240 --> 25:11.460
And so that's why programs spread themselves out across the disk and they have these links at the beginning of each of them pointing to each other.

25:11.460 --> 25:20.040
That's another reason why you can't just run strings and grep because there's lots that are on those boundaries, lots of strings that are on those boundaries where it breaks it up.

25:22.120 --> 25:23.980
Directory entry blocks.

25:24.180 --> 25:30.340
And so the directory entry blocks have the file entries that point to the files on the disk.

25:30.480 --> 25:39.820
That just describes where the files are on the disk, just a little bit of information on the file formats.

25:40.260 --> 25:43.900
You had essentially a few different types of files.

25:44.600 --> 25:48.820
You had files that are marked as deleted, which we're interested in.

25:49.180 --> 25:58.860
You had sequential files, which are basically data files that are, as you would expect out of a normal PC file, like one byte after another.

25:59.700 --> 26:05.240
And then you had program files, which are like, this is your program binaries.

26:05.240 --> 26:12.560
And so your PE files in Windows involve like loading things into memory in the right places and setting up everything for execution.

26:12.800 --> 26:23.320
Your program files on a Commodore 64 disk, the only metadata they have is an address at the beginning of where to load the program into memory and start execution.

26:26.280 --> 26:28.440
And so that's what this diagram shows here.

26:28.440 --> 26:43.660
It's basically showing you that the PRG has a track and sector link for the next sector of the PRG file, a load low and a load high for where we're going to load the program into memory.

26:43.980 --> 26:51.040
And then the next sector doesn't have to have that load low and load high because it all follows from the first one.

26:51.260 --> 27:06.280
And then the last part of it has, since your file is not necessarily an even multiple of the 254 bytes, you have whatever was in memory on the disk drive being written to disk, right?

27:06.280 --> 27:12.340
If you didn't fill that buffer up, it had whatever was the contents of the buffer before and writes it again to disk.

27:12.340 --> 27:17.680
And sometimes that's the previous sector's data, sometimes it's something else.

27:19.260 --> 27:23.780
Sequential files are similar except they don't have the load low and load high.

27:24.780 --> 27:29.300
REL files are basically static length records that can be indexed.

27:29.300 --> 27:32.880
For our purposes, it's the same as a sequential file.

27:32.880 --> 27:36.080
We don't worry about parsing it at the record level.

27:36.440 --> 27:55.580
But it is sort of similar to modern, or not modern, but later on Mac OS 9 sort of resource forks are alternate data streams on NT file system where you can have a file of multiple types of contents because these have two sector chains, one for the data,

27:55.580 --> 27:58.560
one for the pointers to the data for the records.

27:58.700 --> 28:06.160
And each of those could hold interesting data because you could just use them in a non-standard way, and programs do.

28:06.840 --> 28:13.320
And then there's user defined ones which nobody used because they just kind of used sequential and program files however they wanted to.

28:14.180 --> 28:24.880
Other weirdness, there are 40 track disks, and there's some common formats for those and markings for detecting that you're in one.

28:25.260 --> 28:35.220
There's invalid track and sector pointers, and so maybe somebody just didn't decide decided to put right data to sectors and not use that linking format.

28:35.220 --> 28:36.400
You could do it.

28:36.400 --> 28:43.220
It would mean that nothing would read that correctly, but maybe you wrote your own code to do it and you know what you were doing.

28:43.540 --> 28:49.020
There's nothing to keep sector chains from looping in a badly behaved file, right?

28:49.020 --> 28:51.500
You could alter those pointers to make them loop.

28:51.500 --> 28:52.560
That sucks.

28:52.560 --> 28:59.080
You could have sector chains that merge into each other, and so you could have all sorts of nonsense going on here.

28:59.360 --> 29:04.900
Geos, which is a graphical user interface, had its own stuff.

29:05.540 --> 29:09.280
And then the text encoding is the weirdest thing.

29:10.260 --> 29:13.180
Commodore PETSCII isn't exactly ASCII.

29:13.220 --> 29:18.560
It has its own fonts, and so it has two fonts that it would switch between.

29:18.560 --> 29:28.200
It had graphical characters in one of them and then upper and lower case in the other, but the graphical could only have uppercase.

29:28.200 --> 29:34.220
And so there's nastiness here on where they map these PETSCII characters.

29:34.220 --> 29:39.220
Some of them are at the same sort of numbers as ASCII.

29:39.220 --> 29:40.760
Some of them aren't.

29:40.760 --> 29:51.240
And there's no way programmatically from reading a disk to know whether a program intended to use the shifted font or the unshifted font.

29:51.660 --> 29:54.200
And some things use normal ASCII.

29:54.200 --> 29:57.860
And so here we already have three different character sets that we've got to deal with.

29:57.860 --> 29:59.580
That's not all.

29:59.680 --> 30:06.980
Some people would encode text as just A is one, B is two, C is three.

30:06.980 --> 30:11.300
And that's done a lot of times with screen codes.

30:11.300 --> 30:21.200
And so if you're encoding, because the video memory, when you're blitting these characters to the screen, uses not PETSCII, not ASCII, uses screen codes.

30:21.200 --> 30:25.260
And that's an entirely separate table with two different fonts.

30:25.760 --> 30:29.020
And so that's another set of special cases that you have to case.

30:29.020 --> 30:39.040
And so basically any one byte value could be some kind of character on a Commodore 64, and you don't know when you're reading a disk.

30:39.040 --> 30:43.700
And so all I can do in my script is just parse them all.

30:43.700 --> 30:56.780
And so for each disk, I generate a larger than 170 kilobyte data set of all possible strings that could be encoded on that disk from any number of sector chains, right?

30:56.780 --> 31:15.660
So allocated files, deleted files, sector chains, orphaned sector chains that are not associated with files, other weirdness, and then I also do one of the entire disks just in case somebody decided to do something else that I didn't anticipate.

31:15.940 --> 31:20.940
I process all that into a JSON data structure per a nasty one.

31:21.220 --> 31:26.540
That's what ChatGBT helped me design so that it would be efficient in Elasticsearch.

31:27.220 --> 31:35.120
Throw that into Elasticsearch as a table, as a data entry in a table, and that's basically it.

31:35.120 --> 31:41.980
And so we have image name, SHA-256, the disk name, files, strings from chains.

31:41.980 --> 31:50.580
And so I build a list of chains as I find them, and for each chain, I walk that chain and pull out the text, right?

31:50.580 --> 32:03.120
And so that's contents, directory chains, chains that aren't associated with anything seemingly, Slack space, so at the end of sequential and relative files, sequential, relative and program files.

32:03.200 --> 32:10.540
If there's Slack at the end, I pull that out and I do my version of strings on that as well.

32:11.340 --> 32:15.020
I do a naive strings across the entire image just in case.

32:15.020 --> 32:20.280
There's a couple of disks in Tosec that are not Commodore 64 disk images at all.

32:20.300 --> 32:25.280
They're just 170 bytes, 170,000 bytes of something.

32:26.220 --> 32:28.740
And then I SHA-256 everything.

32:28.740 --> 32:42.340
So every file, every chain, I set a separate SHA-256, so if I see a file on one disk, I can search for that hash value and find that on every other possible disk in my data set.

32:42.560 --> 32:45.320
That helps you in cross-referencing and research.

32:46.860 --> 32:51.280
Load that up into, and once you start playing with this, you can dig into this.

32:51.280 --> 32:59.060
I'm not going to get into the details of loading this into Elasticsearch, but however you like to query Elasticsearch, once you get it in there, it's fast.

32:59.060 --> 33:03.700
This data set, this index is about 30 gigs, and that I'm happy to share with you.

33:03.700 --> 33:06.200
I'll probably upload it to Internet Archive.

33:06.200 --> 33:12.640
The code will be on my site, mcgrewsecurity.com, tomorrow or Monday or so.

33:13.980 --> 33:18.180
Then you can use Dirmaster to actually go through the disk on your computer.

33:18.180 --> 33:19.480
You can use emulation.

33:19.480 --> 33:20.760
You can use real hardware.

33:20.760 --> 33:24.040
You can buy a brand new Commodore 64 right now.

33:24.600 --> 33:29.020
Perifractic, the YouTuber, bought Commodore the other day.

33:29.020 --> 33:37.400
He bought all the trademarks, and they're coming out with an FPGA implementation that I pre-ordered, and it's going to be out in, I don't know, probably October or something.

33:38.520 --> 33:49.540
I have a cartridge that allows me to emulate the 1541 that can load off of networks, so I can actually query and pull stuff onto my Commodore 64 from my Commodore 64.

33:50.760 --> 33:53.060
Crazy finding times.

33:53.440 --> 33:56.500
Be warned, this is the fun part of the talk.

33:56.620 --> 33:59.500
Be warned, there's some weird shit in here.

34:02.040 --> 34:07.640
So we have logs of BBS conversations that are just sort of ephemeral.

34:07.640 --> 34:10.400
Nobody knows that this stuff was ever saved.

34:11.140 --> 34:18.920
There is PII in here that's 40 years old that, I mean, I can't do, I can't scrub this whole data set.

34:19.500 --> 34:24.060
All those cards are not real anymore, are not valid anymore.

34:24.060 --> 34:27.460
If you see phone numbers in here, do not call them.

34:28.860 --> 34:36.040
They probably, probably isn't them anymore, and if it is, they might not want to hear from you.

34:37.040 --> 34:38.800
Lost games.

34:38.800 --> 34:43.500
Charlotte Courtois, PhD candidate at the University of Montreal.

34:43.500 --> 34:47.600
I got in touch with her on the Commodore 64 subreddit.

34:47.600 --> 34:58.740
She's working on the history of pornographic video games and also modifying old pornographic video games to have more inclusive LGBT representation.

34:59.100 --> 35:02.840
She found a text-based sex quiz game for parties.

35:02.840 --> 35:05.520
This is the sort of thing that you didn't really do this at parties.

35:05.520 --> 35:07.120
Nobody threw parties for this.

35:07.880 --> 35:22.900
You just sort of sat at home and she found a copy of a pirated, she had a copy of a pirated ladies' sex quiz that she wanted to modify to be a little more sensitive about some things, right?

35:23.580 --> 35:33.840
I helped her find a copy of that that was the same game but not obfuscated in any way, so she was able to edit the basic source code and make those changes.

35:34.660 --> 35:38.260
There is a lost men's sex quiz version.

35:38.260 --> 35:47.700
There is a one that somebody hacked back in the day from the ladies' version that's even worse, that is not the official one.

35:47.700 --> 35:51.140
And this ad right here is from Compute Gazette right here.

35:51.140 --> 36:04.220
This same company, in the process of looking up stuff from this company and following the threads of all this, I was able to find Asteroid Miner which is not in any TOSEC or anything like that.

36:04.220 --> 36:09.040
It's a really crappy text adventure of mining asteroids.

36:09.740 --> 36:15.820
And it's crappy but somebody worked their tail off on it for a while and I think it deserves to be preserved, right?

36:16.960 --> 36:19.080
Codes and cards.

36:19.080 --> 36:30.660
And so they're scanning for these valid calling card codes so they can charge their BBS calls overseas to them or their long distance BBS calls to these things.

36:31.020 --> 36:36.100
And they scan for these codes using Commodore 64 software that I'll talk to you about.

36:36.100 --> 36:38.160
And they share them with each other.

36:39.680 --> 36:41.500
They talk about how to use them.

36:41.500 --> 36:44.720
They have handles, they have dates, all that sort of stuff.

36:45.800 --> 36:54.420
Here's a freaking program here where it had a war dialer which you use to scan ranges of phone numbers to find modems.

36:54.960 --> 36:57.340
It had lists of BBSs.

36:57.340 --> 37:02.160
It had the ability to scan for different codes for different long distance providers.

37:04.080 --> 37:08.200
And had documentation on how to use it so I wanted to show you that.

37:08.200 --> 37:11.580
These are screenshots from an emulator of that software.

37:11.580 --> 37:19.980
Phone freaking software generating blue box tones for simulating the hang up signal on older telephone networks.

37:19.980 --> 37:25.780
Red boxing, you know, playing the tones for inserting coins into pay phones.

37:25.780 --> 37:26.460
That sort of thing.

37:26.460 --> 37:33.320
If you want to drag your Commodore 64 out to a pay phone, I guess.

37:35.400 --> 37:37.060
But all these are in here.

37:37.060 --> 37:41.460
And the reason why this is all possible on a Commodore 64 was that SID chip.

37:41.460 --> 37:44.520
You know, I told you it was an analog synthesizer, right?

37:44.520 --> 37:51.760
You could do DTMF tones through that SID chip that were really clean and appropriate for use in freaking.

37:52.020 --> 37:54.160
And there's wiring diagrams.

37:54.160 --> 38:11.060
So if you take an old Commodore 64 modem, where do you tap into that modem such that you can send the output of your sound device on your Commodore 64, the SID chip, directly to the modem to send that sound down the line to use it for freaking purposes.

38:12.000 --> 38:14.840
And so there's instructions for how to do that on there.

38:17.920 --> 38:20.500
Probably more than I should have put in the slides.

38:21.240 --> 38:29.940
There's demos where people would do magazines of the happenings of the freaking and hacking scene back then.

38:29.940 --> 38:31.920
And these are fun to read.

38:31.920 --> 38:51.840
And this completely horrid font here, they're talking about people getting busted over hacking out MCI calling card codes, so-and-so is busted, so-and-so had a system crash, this BBS is back up, a temporary number for this BBS is this.

38:51.840 --> 39:06.800
And all these things, like if you see a handle for somebody you knew back in the day or somebody that you were back in the day, you can search this data set or I can help you search that data set for that handle and we can start cross-referencing and walking all over this data set finding stuff.

39:08.240 --> 39:17.320
All that's way past any time that you're going to get busted for anything now, probably.

39:17.700 --> 39:20.340
All right, more busted stuff.

39:21.360 --> 39:32.420
Wizard who had been a real asshole but had inspired me to start freaking recently, he got involved in really deep shit when he sold credit card numbers to an undercover secret service agent by the name of the Countess.

39:32.420 --> 39:36.180
The Wizard got busted and released on a 4500 jail bond.

39:36.180 --> 39:38.080
Don't let this throw you off, folks.

39:38.080 --> 39:40.620
He carded and that is a much different subject.

39:40.620 --> 39:47.960
Wizard knows the life of a scared and helpless life for him that got his computer snagged when he got busted along with his lame board.

39:48.720 --> 39:53.300
People were really nice to each other back then just as we are now on Twitter.

39:57.480 --> 40:00.840
Applying, you had to apply to BBSs, right?

40:00.840 --> 40:09.280
You had to say I have this software I can share, I have access to this overseas BBS and I can run that to your BBS.

40:09.280 --> 40:14.820
So there's a lot of databases in here of people's applications to join BBSs.

40:15.100 --> 40:21.260
And then a puzzling thing, a very obscure ad for 2600 Magazine.

40:21.480 --> 40:31.400
This is a disc for a railroad signals game, like a video game to help you learn railroad signals, which there's a certain market for that.

40:33.200 --> 40:49.100
Completely apart from the game as it is itself, on track 26, sector 0, as one might say 0, 0, somebody just dropped this in and it's are you a hacker or a phone freak?

40:49.100 --> 40:54.020
If so, you'll be interested in subscribing to 2600, the journal of American Hacker.

40:54.020 --> 40:58.960
Write to the correct address for subscribing to 2600 Magazine.

40:59.000 --> 41:00.700
Who put that there?

41:00.700 --> 41:02.340
At what point?

41:02.680 --> 41:04.520
If you know, let me know.

41:04.520 --> 41:12.120
And if anybody ever even saw this, like who was going through their disc with a sector editor and spotted this?

41:12.120 --> 41:16.300
I would love to hear if anybody knows because I was never able to find anything else about it.

41:16.300 --> 41:17.920
This is a very odd thing.

41:18.360 --> 41:20.060
And it's on one disc.

41:20.280 --> 41:28.680
There is an interview with Cheshire Catalyst, the late Cheshire Catalyst, famous in our scene, in Uptime, a disc magazine.

41:28.680 --> 41:32.420
He's talking about history of hacking back in the day.

41:32.420 --> 41:38.560
And I thought finding something like this that I couldn't find on the public internet now is incredible, right?

41:38.560 --> 41:42.360
We're actually finding things about our own history here.

41:43.060 --> 41:49.660
Text files that I haven't seen in modern archives like on textfiles.com, on phone company and phone freaking.

41:50.760 --> 42:03.040
But essentially this allows us to query a very large data set of vintage floppy disc images comprehensively and very quickly so that you can run that investigation.

42:03.040 --> 42:07.180
You can sort of pull the threads and find interesting things.

42:07.560 --> 42:13.560
We do it by understanding the disc layout and not treating it as just a binary blob.

42:13.560 --> 42:19.720
We normalize that into ASCII or rather Unicode to push into Elasticsearch.

42:19.860 --> 42:29.120
We create those data structures and we leverage Elasticsearch to do the hard work of doing this index search for us.

42:29.120 --> 42:44.960
And that enables us to answer interesting questions about this era of computing that by uncovering things that are not the controlled things that we chose to preserve, we can see sort of slice of life things that happened back 40 years ago.

42:44.960 --> 42:48.280
And I think that part is very interesting to me.

42:48.880 --> 42:59.320
For future work, you can contact me and I'll help you run queries on the data set so that you don't have to set it up for yourself and help you out with research on this.

42:59.320 --> 43:02.100
I'm going to publish the index so that you can get that.

43:02.100 --> 43:13.520
I don't think publishing the entire disc image set is appropriate because of polluting basically the already disorganized data that's out there and it's very large.

43:13.520 --> 43:18.660
Happy to provide portions of it as you find things in the indexes you want.

43:19.120 --> 43:24.700
We could search for other disc formats for the Commodore 64 and also other platforms.

43:24.700 --> 43:27.320
Translate this to Amiga, early PC stuff.

43:27.320 --> 43:36.840
There are discs from Microsoft that are install discs that have internal Microsoft emails stored in random sectors of them.

43:36.840 --> 43:38.860
There's documentation of that.

43:39.620 --> 43:42.720
And with that, here's my contact information.

43:42.720 --> 43:49.000
All the information about this and links to download stuff will be on mcgrewsecurity.com.

43:49.060 --> 43:51.240
And these are the other ways you can contact me.

43:51.240 --> 43:52.260
I don't do LinkedIn.

43:52.260 --> 43:53.420
Just hit me on X.

43:53.420 --> 43:54.600
I'll give you a card.

43:54.600 --> 43:55.340
You can text me.

43:55.340 --> 43:56.340
I don't care.

43:56.920 --> 43:59.440
But this is how you get in touch with me.

43:59.440 --> 44:02.440
And I really appreciate you sitting through this.

44:02.440 --> 44:08.960
And a big shout out to ST ISAC for being there for hearing me out on some of this.

44:08.980 --> 44:09.860
Thank you.

