How To Recover Your Starcraft Anthology CD Key

I recently ran into an issue where a buddy of mine was unable to find his original Starcraft disc and the CD case, but he had his Broodwar disc, which meant that he was without a CD key.  Hoping to help him, I tried to use a  few recovery tools, but they all failed to work, or were horribly outdated.  I was later determined to figure it out non-the-less, and with a few minutes of your time, you can too.  There is one tool we will need however, and that’s going to be a hex editor.  In this example, I’m using the CD key of “9999-99999-9999”.

Requirements:

  • Frhed (Hex Editor, FOSS)
  • Working Starcraft Installation (which uses the CD key you lost)
  • Starcraft / Broodwar CD (to load up the game)
  • Windows Vista/7/8/8.1

Instructions:

  1. Make sure Starcraft is fully up to date.  (At the time of this writing, it’s at 1.16.1.)
  2. Open Starcraft, and get to the Battle.net Login Screen but do _not_ log in.
  3. Hit Alt+Tab on your keyboard to get back to your Desktop.
  4. Hit Ctrl+Shift+Esc on your keyboard to open up the Windows Task Manager.
  5. Select the “Processes” tab, and find “StarCraft.exe” in the list.
  6. Right click on “StarCraft.exe” in the list and select “Create Dump File”.
  7. Take special note of where it saved the dump to and navigate to that directory.  (Usually, it’s in the current user Temp folder, which you can get to by entering “%TEMP%” into the location bar of any Explorer window.)
  8. Copy the dump file to your desktop.  It should be named “StarCraft.DMP”.
  9. Open up Frhed, and select File > Open to open the Starcraft dump file on your desktop.
  10. Select Edit > Find and Replace > Find… from the menu.
  11. In the Find What box, enter “Starcraft\SWAR\lang\grid.cpp” and hit Find.  (This should bring you to the first result.)
  12. Hit F4 two (2) times.  (This should bring you to approximately the point where you’ll find your key.)
  13. On the right side, look for a string starting with “mo” proceeded by some random numbers.  (The image below shows you what you should be looking for.)
  14. Those random numbers are your CD key. (The area in the image highlighted in yellow is the CD key.)

Starcraft Hex Dump

For those that have a history with hex editors, in my quick tests, the CD key was not at the same offset, so I can’t really give a specific offset to try.

Switching to Viostor: QEMU/KVM after Windows (XP) installation

This process is not as hard as one would expect. Once it’s completed, there is a big performance increase. (At least in my case there was.) I did this in XP, but I see no reason why it won’t work in Windows 2003, Vista, 7, etc.

A requirement is to have the Viostor drivers on your virtual machine before you continue. They can be downloaded on the KVM Driver Download page.

Before I explain anything, my configuration in the beginning looks as follows…
qemu-kvm \
-drive file="./WindowsXP.qcow2",if=ide,boot=on \
-m 1024M \
-smp 1 \
-soundhw ac97 \
-vga std \
-name "Windows XP Professional" \
-net nic,model=virtio \
-net user \
-usb

  1. To start off, we need to create an empty disk image file, or temporarily link an existing one to the XP virtual machine. That can be done by adding -drive file="./temp.qcow2",if=virtio,boot=off \ to the configuration.
  2. Launch the VM with that configuration option added, and once Windows XP loads, it will ask for the drivers for the SCSI controller, which is Viostor. Point it to the directory that you extracted the drivers to, and it should install.
  3. After Windows XP installs the drivers, shut down Windows XP.
  4. Remove that temporary line that you added in Step 1 and change your real drive to say “if=virtio” instead of “if=ide”.
  5. After making that change, startup Windows XP again, and when Windows loads, it will reinstall the Viostor driver for that hard drive.
  6. Reboot, and you are finished.

In the end, my configuration looks like:
qemu-kvm \
-drive file="./WindowsXP.qcow2",if=virtio,boot=on \
-m 1024M \
-smp 1 \
-soundhw ac97 \
-vga std \
-name "Windows XP Professional" \
-net nic,model=virtio \
-net user \
-usb

Tunneling with SSH and Firefox

This guide will explain how to create a SSH tunnel to use with Firefox. Creating an SSH tunnel will create an encrypted connection to an outside machine to visit websites that may be inaccessible from a specific location. (Work, School, etc.) If my web site gets blocked at some point, it will probably be because of this article. The idea of this is not exactly to circumvent filters, but it works perfectly for that too.

Part 1: Create an SSH Tunnel
Unix / Linux / OS X:

  1. In the terminal type: $ ssh <SERVER> -D <PORTNUMBER> -l <USERNAME> -C

With the above command, <SERVER> is the remote server running the SSH service you will be using to create the tunnel. <PORTNUMBER> is any number between 1025 and 65535, and <USERNAME> is the username you will be using to connect to the remote server. After issuing that command, if you don’t get any errors, jump to Part 2.

Windows:

  1. Download PuTTY.
  2. Launch PuTTY. On the initial screen, enter the remote address of the server you will be connecting to in the “Host Name (or IP address)” field.
  3. In the ‘Category’ list, expand the ‘SSH’ option, and select ‘Tunnels’.
  4. In the ‘Source port’ field, type in any number between 1025 and 65535. Select ‘Dynamic’ under the ‘Destination’ field, and click on the ‘Add’ button.
  5. Click ‘Open’ at the bottom of the window to start the connection.
  6. A new window will open up and prompt you for your user credentials. Enter your username and password. While entering your password, nothing will show up on the screen.
  7. After submitting your credentials, if you don’t get any errors, you should be successfully connected to the remote SSH server.

Part 2: Configure Firefox

  1. First of all, if you don’t have Firefox, go to GetFirefox.com and download yourself a copy of it. If you are on a Windows machine that is not your own, consider grabbing yourself a copy of Portable Firefox for this guide and throwing it on a flash drive.
  2. After your copy of Firefox is up and running, whether it be Firefox or Portable Firefox, it’s time to install FoxyProxy. Add the add-on to Firefox, and restart Firefox when asked.
  3. Launch the FoxyProxy options. From the ‘Tools’ menu, hover over FoxyProxy and jump down to ‘Options’. From the status bar, right click on the FoxyProxy icon, and select ‘Options.’
  4. Click the “Add New Proxy” button.
  5. A new window will appear. “Proxy Details” will be the tab initially selected. If not already selected, select “Manual Proxy Configuration”. In the “Host or IP Address” field, enter ‘127.0.0.1’ and in the ‘Port’ field, enter the port number you used in Part 1. Make sure the check box for “SOCKS proxy” is checked. We will be using “SOCKS v5,” so select that.
  6. Click on the ‘General’ tab, and in the “Proxy Name” field, give the proxy a name that summarizes what this proxy will do for you, or where it will connect you to. You could even keep it as generic as “SSH Tunnel.”
  7. Click the “OK” button in the “Proxy Settings” window. You will be prompted with a message about not adding any web addresses to the domain white-list. That’s fine, just click “OK” again. Once back on the main “FoxyProxy Options” window, just click the ‘Close’ button to close it.
  8. Time to activate the proxy. From the ‘Tools’ menu, hover over FoxyProxy and select “Use Proxy <PROXYNAME> for all URLs.” From the status bar, right click on the FoxyProxy icon, and select “Use Proxy <PROXYNAME> for all URLs.”
  9. At this point, any web site you visit will be proxied through your SSH tunnel. If something is not working for you, go back and check all of your settings from Part 1 and 2.
  10. When you are finished using your proxy, be sure to disable FoxyProxy. If you don’t disable FoxyProxy and your connection from Part 1 is not running in the background, your connection to the internet is going to appear dead. To do so, from the ‘Tools’ menu, hover over FoxyProxy and select “Completely disable FoxyProxy.” From the status bar, right click on the FoxyProxy icon, and select “Completely disable FoxyProxy.”

Possible gnome-cups-manager README file improvement

A realistic ending to the gnome-cups-manager README file, courtesy of Kevin Warns. Somebody should submit this back to Gnome SVN…

New (sad, morbid, realistic) ending:

43 The little girl looked up at him. “What are you?” she asked.
44
45 “I’m a printer!” said the printer.
46
47 “A what?” asked the little girl.
48
49 “A printer! Surely you’ve heard of me. I make paper copies of things
50 on your computer!”, replied the printer.
51
52 “In today’s all-digital world, there is no reason for you to exist!” said
53 the little girl.
54
55 The printer was devastated. He spent the rest of the day slitting his cables
56 and praying for the cold darkness to overcome him and take away his pain.