Skip to main content

Posts

Showing posts with the label arm_buffer_overflow

Azeria Labs ARM challenge ROP Exploitation (day 90) ಠ_ಠ

When I was scrolling through my twitter feed 2 weeks ago I noticed that azeria just release new material on her website and it's about ROP in ARM. As you know we talk a lot about ROP in several posts on ARM buffer overflow thus I think this could be a good opportunity for me to learn the basic again about ROP again and without a second thought, I took my favorite notebook, click the link and start learning(check it out in link ). The author also put some challenges about how to construct ROP exploitation in an ARM architecture to test our skills and in this post, I will show you how I approach these challenges. When you boot up the qemu emulator you can find the two binary in the challenges directory Note: Before you continue this post make sure you turn off ASLR mode in the QEMU emulator Challenge1: 1st approach(Without ROP)    At the first challenge, we got 32 bit ARM binary, not stripped and the PIE protection is on. Basically, PIE enables the program ...

ARM buffer overflow: chapter 8 ಠ-ಠ (day 83) (from heap to shellcode)

  Previously in the arm exploitation series, we take a look at how we can perform buffer overflow and format string attack in ARM binary, both of them prove to be powerful enough to take control of program execution if it correctly utilizes, furthermore it can also bypass anti-exploit mechanism. But both of the attack methods are conducted in stack region of memory and today lets try to explore the other attack mechanism in ARM binary which is heap exploit. I already introduced how to get a start in the heap exploitation binary, in this post and this post so I will not cover it again. This post is meant to give an idea of how heap exploitation happens in arm binary and how we can leverage this exploit to be able to take control of the program workflow and drop a shell. For the POC, I will take the source code from protostar heap0 challenge, compiled it in raspberry pi qemu and try to exploit it source: https://exploit.education/protostar/heap-zero/ just like in t...

ARM buffer overflow: chapter 7 ಠ-ಠ (day 77) (writing ARM shellcode)

In the last post of learning shellcode, we are taking a look at how to create our own simple shellcode in 32-bit intel architecture but this time let's switch to ARM architecture so we have a better understanding of how the program works in more low level. note: this post is heavily based on Azeria labs you guys can check the corresponding post in here . All I do is just reiterating the concept and probably explain a little bit more detail about it Let's start from the beginning "Hello world" in this section, we are going to just create a really simple hello world program from scratch using arm assembly. Type the following code below and save it as "hello_world.s" let's break it down in detail what is this code really doing: 1. ".data" section used to initialized data or constant in memory and remember this section cannot be changed during runtime by default. In the source code, we declare two variable which is "string...