Tuesday, November 28, 2006

Making Unsafe Saves Safer

If you've ever worried about losing your Xbox, Xbox 360 or PS2 game saves (to an accident, mistake, hardware failure or small child), then you may have tried to make backups of your saves, only to find that you can't copy some of them. In this article I'll describe the problem, guess at the reasons for it, present some advice for game makers, and finally pass on what workarounds I know of to make backups of these 'uncopyable' game saves.

The Problem

A few months after I bought an Xbox and a PS2, I realized I had hours of progress on some games that I'd be unhappy about losing.

So I set out to save my saves. I have purchased memory cards for all my systems to backup saves onto, and tried to copy my saves to the cards.

The first system I had trouble with was the Xbox. Ordinarily when a save is selected, the Xbox dashboard offers options to copy or delete. But on some of my games, only the delete option was offered. Some web research revealed that Microsoft offers developers the ability to mark saves so that the dashboard won't copy them.

What the-???!!!

Out of my library of 79 Xbox titles, 15 have save games that are uncopyable either explicitly, or practically (Fatal Frame's saves are five times the size of an Xbox memory card). That's about one out of five. The titles from my collection with the problem are:

  • Black
  • Burnout 2: Point of Impact
  • Burnout 3: Takedown
  • Call of Cthulhu: Dark Corners of the Earth
  • Darkwatch
  • Driver 3
  • Fatal Frame
  • Fatal Frame II: Crimson Butterfly: Director's Cut
  • FlatOut
  • Forza Motorsport
  • Half-Life 2
  • Jade Empire Limited Edition
  • Psychonauts
  • Silent Hill 4: The Room
  • Star Wars Knights of the Old Republic II The Sith Lords

I checked my PS2 saves, and there was a property on each save called "file protection" that made me nervous. Just this year I picked up two titles that turned out to have uncopyable saves:

  • TOCA Race Driver 2
  • TOCA Race Driver 3
Sure enough, the 'file protection' save property was on. So Sony offers the same kind of game save copy protection to developers that Microsoft does. It seems to get used far less often, though; only those two out of the 28 PS2 titles I've tested have uncopyable saves.

Just recently I started backing up my Xbox 360 saves, and two out of the 10 titles I own won't allow copying of save files:

  • Perfect Dark Zero
  • Gears of War

The Reasons

After the surprise and outrage over not being able to copy some of my game saves subsided, I began to see the reasons why a console maker might offer such a thing, and why game publishers might use it. The purpose is not, despite how it may appear, to prevent players from using their saves on a friend's system, nor to make players restart their games from scratch in the event of a hard drive or memory card failure. Those are just side effects.

Nor is the intent to stop the hardcore hackers, those who are willing to modify the console hardware to get what they want. With hardware mods all bets are off. Legal tactics are the method of choice for suppressing hardware mods.

No, the intent of the manufacturer, the game publishers, and the game developers is to stop casual activities they don't want. I think there are four main reasons why some game saves are uncopyable: online cheating, piracy, homebrew, and offline cheating.

Online Cheating: The idea here is that a game that gets a reputation as a playground for cheaters will sell less. This also applies to games which are single-player only but which have online leaderboards. The easiest way to cheat online is with a hacked gamesave. The cheater transfers the save to a PC, applies a hacking tool, and transfers it back. Some forms of cheating don't even require a hack; if a game stores online progress in offline saves, then merely having a backup of a save is a kind of cheating. Wins can be copied to the backup, while losses can be erased by restoring from it. Making game saves uncopyable closes this particular avenue for cheating, though of course it still leaves open hardware mods and net hacks (and does nothing to stop save hacking on systems where there's no built-in hard drive).

Piracy: This affects the manufacturer's bottom line as well as the publisher's, as the manufacturer gets a percentage of game sales revenue. Not every pirated copy of a game represents a lost sale, but some number of copies do. In order to reduce the amount of this going on, the manufacturers have taken steps to prevent burned copies of games from running on the console. These include [a] Microsoft using a DVD-ROM drive that has trouble reading writable media (or in more recent hardware revisions, is deliberately configured to reject DVD-Rs), [b] Microsoft using an unusual disk format that can't be read by PC DVD readers, [c] Microsoft writing into the disk loading program a check to see if the game disk has been cryptographically signed by Microsoft, and [d] Sony writing their loader to check the disk media type to make sure it's a commercially pressed game disk rather than a burned copy.

One of the more convenient ways pirates use to get DVD-R copies of games to run is hacked saves. Some games contain bugs that can be exploited to make part of a game save's data executed as code, thus enabling the pirate to run a game loader that doesn't check for the cryptographic signature or media code. Making the game saves uncopyable closes this opening for casual pirates, at least on the Xbox where the only way to get the save onto a PC is to first get it off the Xbox hard drive and onto a memory card. Serious pirates can still use hardware mods in order to play their downloads, but this requires skill and money, thus greatly reducing the number of people playing burned copies.

Homebrew: Many game consoles are sold at a loss. This is true in particular of the P52, the Xbox, and the Xbox 360, at least for the first year or two after their introduction. The way the manufacturer makes money is through licensing fees on games. In return for the licensing fee (and other conditions such as certification), Microsoft adds the cryptographic signature that will allow the game to run on the console, and both console makers press the disks on commercial media. If people could easily make games run on the console without the cryptographic signature or correct media code, then there'd be no reason for anyone to pay the licensing fee. Then instead of losing money on the console and making it back on the games, the console manufacturers would just be losing money. Not only that, but the quality of games would be completely uncontrolled and there could be a repeat of the Atari 2600 fiasco from the 80s. Not an attractive proposition.

As mentioned before, the easy way to get unsigned code and burned disks to run is to exploit a game bug with a hacked save. Again, not being able to copy saves for that game closes that loophole (on the Xbox). Hardware modders can still run homebrew games, but that's a tiny fraction of the financial exposure that would come from everyone being able to run unlicensed games.

Offline Cheating: I don't see a financial reason to stop cheats in offline games, so I'm going to chalk this one up to pure anal-retentiveness. I know for sure that there are developers who wish to force a particular game experience on the player. For instance, in the case of Call of Cthulhu: Dark Corners of the Earth, the developers had the option to create a save-anywhere feature, but--quite deliberately--chose to have savepoints instead, so that the player could not (for instance) choose to save during a frightening and deadly action scene. The designers wanted the player to feel the fear of having to do the entire scene over again, in addition to fearing the things trying to kill the player's character.

With this sort of high-handed attitude, the player must experience the form of enjoyment intended by the game designer and no other. Given that, I can understand if not approve of attempts to stop single-player offline cheating. Even something as simple as loading an earlier (backed-up) save in order to get out of the corner the player has painted himself into, rather than having to start the game over from the beginning, can circumvent the designer's intended experience. And cheating via hacked saves? That completely demolishes it. Making the saves uncopyable prevents debasement of the designer's work by the casual cheater.

Or I could give the benefit of the doubt and suppose that the saves are actually uncopyable in order to prevent online cheating, piracy hacks and homebrew hacks.

So... With all these reasons why console manufacturers and game makers would want uncopyable Xbox saves, why are any saves copyable at all? I think it's due to a combination of factors, including a lack of anal-retentiveness, an evaluation that the losses stopped by preventing game save backups are less than the losses created by angering customers, and having other less onerous methods of achieving the same results. It's telling, I think, that Microsoft thought these problems serious enough that they deliberately removed from the Xbox 360 a function to copy Xbox saves for backward compatible games, and also prevented those saves, once created on the 360, from being copied onto memory cards. That's right; no original Xbox game saves can be copied from the Xbox 360 hard drive onto a memory card.

Some of these copy/no copy decisions, however, appear to defy logic, leaving the above explanations in doubt. For instance, take Burnout 3: Takedown. The saves on the PS2 version can be freely copied, but the ones on the Xbox are locked. Yet the saves for Burnout: Revenge can be copied on both platforms. One could argue that the problems with copyable saves on Burnout 3 were fixed with Revenge, and that there's not much point in protecting saves on the PS2 as it has no internal hard drive. But then there's TOCA Race Driver 3, which has saves copyable on the Xbox but not on the PS2! Try to make sense of that one.

Advice for Game Makers

Though using game save copy protection may stop abuses like casual softmodding for piracy or homebrew, and casual savehacking for online or offline cheating, it also stops legitimate players from from safeguarding their progress. Game makers may come to the conclusion that hindering the abuses is worth more to them than the goodwill of their legitimate customers, but what if they didn't have to choose one or the other? What if there were ways to stop the abuses without angering the customers?

Let's go through the reasons mentioned above for uncopyable saves, and see if there aren't other solutions. I will begin by stipulating that these other solutions are ineffective against modchips and other hardware hacks; but then, so are 'uncopyable' saves.

Online Cheating: If all online progress is stored on the server rather than the console, then online cheating by hacking the save becomes impossible, as the player doesnt have an offline save to hack. Some material, such as downloaded multiplayer expansion maps, has to be stored on the console, as broadband comnections are not yet fast enough to make on-demand maps practical. However, this kind of static content can incorporate cryptographic signatures that are validated at load time, making savehacked maps useless.

But what about games that use offline single-player progress to unlock online bonuses, or that keep online leaderboards of single-player achievements? The first of these is a bad idea for game design reasons, and both can be handled by a fairly simple technique.

With the exception of co-op story mode, multiplayer and single-player modes in games tend to be very different experiences. In fact, they're usually different enough to be like completely separate games, appealing to players with opposite tastes and skills. Single-player content draws those who prefer to be told a story and progress through the content to its end, beating the game, while multiplayer draws those who want pick-up-and-play action where they're competing against or teaming with other people. Skills that are necessary to dominate one mode are often useless in the other. Even players who enjoy both kinds of experience tend to play them as separate games; I know I do.

Worlds apart as the two play modes are, it doesn't make sense to tie progress in one to the other; most multiplayer enthusiasts I've heard from are uninterested in single-player game modes. Requiring single-player progress in order to unlock multiplayer bonuses makes a game a chore rather than fun. If there's going to be online multiplayer progress, it should be tied to online multiplayer achievements.

That said, if the game designer is going to insist on tyeing mutliplayer features to single-player achievement, or if an online leaderboard of single-player scores is wanted, then the way to do it is to provide a separate online single-player mode. Such a mode would be playable only online, with all save data being stored on the server. This eliminates savehack cheating, so that the save data on the console can be freely copied.

Piracty and Homebrew: The solution to this one is basic software quality control. Treat save data as input and validate it before using it. Array bounds checking, offset range validation, and other input verification techniques are basic tools for safe programming, as are automated unit tests that check for such vulnerabilities. If buffers can't overflow, then executable code can't be altered to give an attacker access.

Offline Cheating: Oh come on. This isn't a problem that needs solving. Really. In fact, leaving this vulnerability open may increase sales and will certainly increase the game's enjoyability for those with lesser skills.

Workarounds

For original Xbox games, the only workaround I can offer is for the one game that prevents copying to memory card by being too big: Fatal Frame. For the others, nothing short of running Xbox Linux or an alternative dashboard will give the ability to copy the protected saves. And both of those require a modchip or (for older machines not connected to Xbox Live) a savehack. Here's the workaround for Fatal Frame:

  • Get an Xbox USB adapter. This is a device that plugs into a controller port and provides a USB socket.
  • Get a USB flash drive that's compatible with the Xbox and big enough to hold the save (64MB or larger). You can find lists of these drives by searching the Web. I use a Lexar Jumpdrive Secure 128MB.
  • Plug the flash drive into the adapter, the adapter into a controller port, and format the drive.
  • Copy your Fatal Frame save to the flash drive.

For PS2 and Xbox 360 games, the general strategy for backing up saves is this:

  • Start the game with the original memory device inserted, as well as the backup.
  • Load the save from the original device.
  • Remove the original memory device.
  • Switch the game's save location to the backup device.
  • Make the game save itself to the backup device (usually by tweaking some game setting, then tweaking it back).
The reason for removing the first memory device is because some games will attempt to delete the old save when you change which memory device you're using.

The above strategy will work for both TOCA Race Driver 2 and TOCA Race Driver 3 on the PS2. You can drop the removal step, as neither game tries to delete the old save.

For the Xbox 360 game Perfect Dark Zero, the above strategy works when the original save is on a memory card. Just drop the settings change step, as the game saves itself the moment you change the save location. But when the original save is on the hard drive, a variation on the technique is necessary, as I think it unwise to remove the hard drive while the console is running! To copy your save from the hard drive to a memory card, do this:

  • Insert the memory card.
  • Start the game and proceed to the main menu.
  • Change the save location to the memory card.
  • Remove the memory card.
  • Change the save location to the hard drive.

For the Xbox 360 game Gears of War the above strategy will not work, and a different technique is necessary. A Gears save cannot be copied to an empty memory device; the 360 complains that it can't copy the save to a new profile. However, an existing save tied to the same profile can be overwritten. So:

  • Start the game with both memory devices inserted.
  • Change the save location to the backup memory device.
  • Start a new single-player game.
  • Skip cutscenes as much as possible and play until the first checkpoint is passed.
  • Quit the game.
  • Exit to the dashboard.
  • Copy the game save from the original device to the backup device, overwriting the save just created.
  • After this, the save can be copied from the original device to the backup device without a problem.

1 comment:

supergg2k said...

Excellent post. I followed the link from your Level Up comment.