Ke$ha to the hackathon!

” Wake up in the morning
feeling like p-diddy
grab my glasses
I’m out the door
I’m gonna hit the city
before I leave brush my teeth with a bottle of jack
’cause when I leave for the night I ain’t coming back “

Yeah I know, this isn’t really a politzer winning poem, or a healthy style of living,
It is however a lot like how a computer think!

A computer program usually comes to solve some sort of problem or simulate a situation.
In order to do that, one has to break down the tasks to perform into basic instructions so that the computer won’t miss any detail, and that my friends – requires some planning.

Imagine you’re to build a house. If you won’t use a well planned architecture you’ll probably
have a lot of issues building that house. The foundations have to be strong, the walls straight and the roof has to be 100% water proof for example.
It’s the same with computers.

A programmer has to follow a few steps before even writing th first line of code:
#define the_problem
#define tools_targets_backupPlan
break (easy_problems(hard_problems));
//and figure out the sequence of events!
/*Probably some I/O operations as well but we’re not gonna be talking
about them just yet */

Those of you who noticed I used a bit of C/C++ syntax there – well done! Though it’s just cosmetics within the scope of this post.

So I believe with just a little effort even Ke$ha can become a programmer. Actually, let’s have a bit of fun and show Ke$ha how exactly we can turn the “tik tok” lyrics into a computer program flow if we only change the order of the lines a bit:



I know I know, It’s not exactly intuitive, oh you didn’t care about that and thought I don’t have a life?  Rude. True, but rude!


Seriously though, you should really follow these guidelines if you wish to write code that works and runs without any unexpected behaviors (more on that later) every time you run it! I know enough programmers (or hacker wannabes) who don’t go through this procedure when designing their code and let me tell you this – it shows. The outcomes are just not good; programs crush, causing memory leaks and even crushing the system and expose the computer to security breaches (don’t worry we’ll get there).

DON’T BE LAZY! Walk the extra mile! That’s what differentiate between the mediocre and the expert.
Also, don’t think you’re super smart and talented you can jump straight to writing code – always plan ahead, even if it’s just a simple recursive file infecting virus program (academic, naturally).

Developing a Plan

I’m off to do something useful with my life.
Nope, probably not,



A new dawn – an old OS

So on the previous post I promised I would give some background on reverse engineering so here it comes –

Reverse engineering, also called back engineering, is the processes of extracting knowledge or design information from anything man-made and re-producing it or re-producing anything based on the extracted information. The process often involves disassembling something (a mechanical device, electronic component, computer program, or biological, chemical, or organic matter) and analyzing its components and workings in detail. – Wikipedia

Software reverse engineering is the art (yes, ART!) of disassembling a program of any sort (game, utility, OS, malware etc) in order to gain a deep understanding of what it does, it’s architecture and design so the reverser (the reverse engineer, from now and on -the reverser) could recreate the source code, manipulate the software to his needs and wills and research for vulnerabilities within the target program.

Today, software engineers of any background, avoid developing software using technologies that are easy for the machine to understand and use a “high-level” programming (and scripting) languages. I’ll explain:

The more the language is close to human language, the more stages the code has to pass in order to become a machine-readable language aka “assembly instructions” or machine code. It’s a bit more complicated than that and there are entire courses about this matter in universities (for those of you who want to get a deeper understanding I recommend on reading about software compilation and interpretation in high level and low level programming languages) but for us this would do for now.

Since programmers of today mainly use high-level languages (Java, C# etc) and scripting languages (python, js, php etc) and though it has it’s benefits (which are beyond the scope of this post, most of the programmers are just dumb and lazy),  most of them lack the knowledge on how the easy-to-read code becomes machine instructions, how the computer executes these instructions and how everything works beneath the surface basically (that’s the dumb and lazy part).

This is where hackers join in.

With a deep understanding of code compilation, CPU functionality and memory management, a hacker can gain a full access to a machine, exploiting vulnerabilities in all stages of compilation and interpretation and interfere with software’s execution.

Reverse engineering skills are very important for hackers and security researchers (the “good” hackers) since vulnerabilities aren’t always so transparent, one has to look behind the scenes in order to find them! And not all vulnerabilities are exploitable or worth exploiting.. more on that later.

So after this long introduction on reverse engineering I assume you understand why I am interested in becoming a reverser. But how can one become a reverser you ask?

A reverse engineer has to know the ins and outs of software, therefore one has to practice “low level” programming languages. I’ll focus on intel x86 assembler (32 bit) architecture since it is easier to understand and is much more “academic” than its successor the x64 architecture. But before that I will practice some C/C++ which are high level languages (since it is more human readable than machine readable haha) since these languages are the base of all software. Operating systems cores are developed mainly in C and some assembly and C++ for example.

I do not have to be a brilliant coder (that is not ma’ job!) but I do need some programming abilities to understand the goings of the software I wish to reverse. Does it make sense? no? deal with it.

I advised my mentor, Cru5d3r and he suggested the following:

  • Learn to code
  • Practice
  • Understand you have no clue what you’re doing
  • Go back to square one


The binary-auditor suggested practicing C++ and Assembly x86 as I wrote in previous post.

I am not going to teach any of these languages here, if you find it disappointing – sorry I’m not sorry. I will however share with you the exercises I’ll do (from the binary-auditing kit, duh!) and walk you through them.

But first things first.

Set up a Windows 7 (32 bit) workstation, it is recommended to use a VM (virtual machine) since we will run malware there eventually, and quite honestly – who the hell wants to use win (any version) on the host anyway!?

I like Oracle’s VM VirtualBox but you may use whatever you like.

After done installing the OS we’re gonna have to install some utilities such as google chrome (not gonna use IE whatsoever) and IDA Pro. The binary-auditor was kind to include a free version of IDA in the kit but you can get a better one if you know where to look or willing to spend some money.

Then we’re gonna need an IDE (Integrated Development Environment). This doesn’t have to be installed on the VM, not for now at least since we’re gonna need it mainly for practicing C/C++ and not for the “real thing” – I have it installed on the host computer. Binary-auditor recommends using code::blocks, I do too. It’s easy to use, very practical and it is cross-platform (to some extent). Make sure you set code::blocks to use the right compiler or you won’t be able to execute the programs you write on the host (ELF on linux and EXE on win are two different executable file formats).

For assembly we will need some other software but we’ll get to it.

I have downloaded an app to my mobile, called Learn C++ by solo learn and I also work with several books and tutorials. If this is going to be your first programming language I suggest you get someone to teach you in like a course or something, I do not recommend starting to learn coding from books, tutorials, youtube vids or even lynda. It will just mess you up. Luckily enough this isn’t my first language so for me it’s ok to use the free resources lol!

That’s it for now!

On the next post we will get our hands dirty – I will demonstrate and walk you through the first real C++ exercise! How exciting is that??? What? No? Fuck off.



“And on the third day, God created the Remington bolt-action rifle, so that Man could fight the dinosaurs. And the homosexuals.”

Hello everyone, I am ar3p0, a 16yo cyber geek from IL.

Now that we’re done with introductions it’s time to start talking process. No, not computer processes (well not just yet) but the process of learning! Isn’t it fun? no not really but this is my blog so I make the rules.

I have a basic background in C and OSs (especially linux since I have no friends) and some x86 skills. I tried to learn by myself and become a super-mega-l33t h4x0r (jk) using books, blogs, YouTube – u name it, and though I gained a lot of knowledge I still lack the practical experience, so after a year (or more) break I decided to clean the dust off my laptop (wasn’t that dusty, I do watch porn after all) and start looking for a better path for me.

I came across this site called binary-auditing where a university professor (don’t know who’s the man and where does he teach, it doesn’t say) published a complete guide for the absolute beginners. This guide is forcing you to take a practical approach and get your hands dirty so results are guaranteed for the ones who follow his instructions.

The guide opens with exercises in C++ and in x86 Assembly language, however it does not give you the information needed to complete the exercises so off to a C++ learning website/book whatever gets you going and then it is possible to keep enjoying the guide. The instructor, calling himself “binary-auditor”, does say it is not a requirement to be a C++ nor x86 Assembly expert but some knowledge in these languages could get you very far in the world of reverse engineering; So this time I’m gonna be a good boy and follow the instructions provided by the expert and who knows, maybe someday I’ll be one myself!




On the next post you should expect the following topics:

  • What is reverse engineering and why do I find it interesting?
  • Getting started with C++!


till then,