Introduction to format string vulnerabilities

  Рет қаралды 26,195

Pico Cetef

Pico Cetef

Күн бұрын

Пікірлер: 7
@InglesPilipino
@InglesPilipino 7 жыл бұрын
Very helpful and clear guide
@bobmarley8644
@bobmarley8644 10 жыл бұрын
Really cool vid but can you clearout why 'sh;#\x04\xa0\x04\x08\x06\xa0\x04\x08'? is 'sh' gonna be passed as an argument to system()? why the two addresses after sh? and what is the second address of?
@incertia
@incertia 10 жыл бұрын
this is extremely late but here's a brief explanation. the function call we want to exploit is strdup(argv[1]). We want to change this call to system(argv[1]) because we can control argv[1] and if argv[1] = "sh;#...", it will be the equivalent of system("sh;#...") which will execute /bin/sh hopefully and then ignore the rest because # designates a shell script comment. what most printf vulnerabilities make use of is the %hn feature, which writes the current number of bytes emitted to the variable at the address pointed to by the next argument in printf. We can specify exactly what address with some x$hn where x is the argument number we want to write to, 42 and 43 in this case. Given that we walk up the stack further enough, we will find our format string stored in memory and that is why we include the addresses right after sh;#. Because writing an entire 32 bit number's worth of bytes takes a long time and is very messy, we can do it by writing two 16 bit numbers, which is why we write to 0x0804a004 and then 0x0804a006, to write the low and high parts of the address of system(). note that this is significantly harder to do when the address you want to write to contains a null byte, because printf stops after it encounters a null byte.
@nikmil6804
@nikmil6804 Жыл бұрын
god bless you!
@abrarshariare5835
@abrarshariare5835 2 жыл бұрын
precise
@MercuryTheWhite
@MercuryTheWhite 7 жыл бұрын
terrible narration
Format String Exploits - Writing Data
17:05
pwn.college
Рет қаралды 6 М.
Format String printf Vulnerabilities (PicoCTF 2022 #46 'flag-leak')
19:44
«Жат бауыр» телехикаясы І 30 - бөлім | Соңғы бөлім
52:59
Qazaqstan TV / Қазақстан Ұлттық Арнасы
Рет қаралды 340 М.
How to have fun with a child 🤣 Food wrap frame! #shorts
0:21
BadaBOOM!
Рет қаралды 17 МЛН
Format String Vulnerabilities
6:42
Software Security
Рет қаралды 644
Introduction to return oriented programming (ROP)
6:34
Pico Cetef
Рет қаралды 38 М.
why do hackers love strings?
5:42
Low Level
Рет қаралды 432 М.
pico2024 format string 1
14:26
Martin Carlisle
Рет қаралды 2,5 М.
A simple Format String exploit example - bin 0x11
10:01
LiveOverflow
Рет қаралды 173 М.
understanding ft_printf
11:23
nikito
Рет қаралды 16 М.
How They Hack: Buffer Overflow & GDB Analysis - James Lyne
16:06
you will never ask about pointers again after watching this video
8:03
the TRUTH about C++ (is it worth your time?)
3:17
Low Level
Рет қаралды 824 М.
«Жат бауыр» телехикаясы І 30 - бөлім | Соңғы бөлім
52:59
Qazaqstan TV / Қазақстан Ұлттық Арнасы
Рет қаралды 340 М.