Skip to main content

Posts

Showing posts from March, 2020

A demonstration to Stack Overflow attack using exploiting the vulnerability

What if you write some piece of code that consist of VULNERABILITIES , that could lead to undesirable behavior of the flow of execution, if exploited by the hacker. One of the most common attack or exploit that is used today is a Stack Overflow type attack. Stack Overflow is an undesirable situation when the program tends to use more memory space then the call stack available. If we take a simple C program, that copies the memory from source to destination using memcpy function: #define STRING "I LOVE HACKING" char buffer[10]; memcpy(buffer, STRING, strlen(STRING)); In the above program, the actual size of buffer is 10, while memcpy will tend to copy 14 bytes of data to buffer. This will lead to overwrite some stack area that don't belong to the  buffer . In simple word, this is a vulnerability in the program, that can be exploited and which might lead to change the actual behavior of the program. Now let's see how the stacks are organized in an actual p...

Setting my Yocto qemu environment for reverse engineering experimental purpose

In this post I have discussed about, how I set my ARM reverse engineering platform in Yocto Qemu. Generally when we are talking about reverse engineering then we need a target platform where we could exercise our experiments. We Can choose Raspberry pi, Beagle Bone etc. for these kind of experimentation. But what we can do in these platforms, can also be performed in some virtual environments. Only for experimenting on some kind of side channel attacks, we would need the actual hardware. For making the setup, you would need some PC with very good configuration likely atleast 4 GB of RAM, 100 GB of free space, and with atleast Quad Core Processor. I have installed VMWare (non-commercial version) which is running Ubuntu 18.04. If you have ubuntu installed in your PC itself then it is well and good. I have followed this link to install Ubuntu. The following steps would help: 1. First clone the source code of Yocto. You might also require some dependencies to get it installed: $ c...