Παρασκευή 27 Ιανουαρίου 2012

Hacking Games in Linux (flash and other)

By hacking games, I mean changing things like your score, your ammo, your lives and thousands other parameters a computer game might have in order to have more fun playing the game or post a cool high score. I will show you a quick and easy way to achieve this. This technique can be used on offline games such as a Minesweeper but can also be used for online games, especially flash-based, java or silverlight games. Online casino games such as poker or games where players can profit from winning the game cannot normally be hacked because the company that created the game makes sure that parameters such as money and scores are saved and calculated in their website's server so that whatever you do, you cannot change them.

So, let's say that you are playing a flash game that uploads your high score to a website when you lose. You would probably like to upload a cool high score so that you can have fun showing it to your friends. There is a number of different ways you could achieve this, such as tampering into the high-score data the game sends to the website after you finish playing the game or tampering with the game's code using a live debugger. But that's not what we will do. We will do something much simpler that requires absolutely no knowledge of programming.

A little explanation: Every game we play in our computer uses the ram memory to store it's parameters such as score, lives etc. So, why not use a program to change these values while we are playing the game? In linux such a program exists and it's called scanmem, but it is a command-line utility and since I told you that we will hack the game in a simple way, we will not use this utility. Instead, we will use the GameConqueror program, which is a very easy to use program that has a graphical user interface which in fact is a wrapper for the scanmem utility.

So, install the GameConqueror to your linux machine and start hacking! After you install this program, run it. It will ask you to enter your root password because it needs to have access to other programs' ram memory. Also, start the game you want to hack. Now, through the GameConqueror you need to gain access to the game's parameters in ram. Press the button "Select a process" located in the GameConqueror window. You need to select the game's process from the process list that appears. Usually for non-flash games that is pretty easy, because the name of the process is usually the same as the game's name. For flash games this is more tricky. Let's say you play the flash game with Firefox. This means that firefox loads the game but the correct process to choose is NOT Firefox, but plugin-container. Plugin-container "contains" the flash game. If you have more than one plugin-container processes you can restart Firefox and open only the website containing the game or you could try each plugin-container process one-by-one until you find the right one. After you choose the correct process, start playing the game. If you want to upload a high score from a flash game, then your score parameter is what you need to change. So, play the game for a few seconds in order to make a low score, let's say 15 and pause it (you don't have to pause it if you are sure you won't lose after a few seconds of inactivity). So, let's say you now have score = 15. Go to GameConqueror and enter 15 in the "Value" field, make sure the data type is int32 and press scan. After a while, the program will find some variables with value 15. If the results are too many, GameConqueror will not even bother to show them to you. If it finds a few results it will show them to you. Now, what we need to do is find which one of all these results is the "score" parameter. How about we increase our score a little more and then scan again but this time scan only inside the previous results? Sounds like a good idea, so play a little more the game and pause again. This time let's say our score is 30. Without resetting our previous search, replace the value 15 in GameConqueror with 30 and press "Scan" again. This time the results are fewer. Repeat these actions until you end up with only one result (usually after 3-4 tries). When that happens, we are ready to hack the score. Double click on the result so that it appears on the bottom-half of the GameConqueror window. Change the value by double-clicking on it and typing whatever number you want (well, do not enter an extremely high number because it might not fit in the space reserved for the score by the game) after you change the value make sure you check the "lock" option for this value. Return to the game, play a little and you will see your score to magically change to the one you typed!

There are a lot of ways you can use GameConqueror to change a lot of things in almost every game imaginable. Sometimes you might not select the correct process, or you might need to use a different data type that int32 or you might even notice that a game's score is saved a little differently than what you expected. For example, if your score is 130 the game might save the score as 13 (130 divided by 10). Anyway, practice makes perfect! If you are using a machine with Windows you can use a program called Cheatengine to do the same things you did in Linux and other cool stuff since this program has more features than GameConqueror. Have fun playing games!

Δεν υπάρχουν σχόλια:

Δημοσίευση σχολίου