https://github.com/niklasb/ub-to-rce
https://github.com/niklasb/ub-to-rce
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/niklasb/ub-to-rce
- Owner: niklasb
- Created: 2018-06-14T14:17:07.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-06-14T14:23:11.000Z (about 8 years ago)
- Last Synced: 2025-04-04T10:47:08.188Z (over 1 year ago)
- Language: C
- Size: 840 KB
- Stars: 7
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Exploit-Demo zum Vortrag "Von UB zu RCE"
## Starten
```
LD_LIBRARY_PATH="$(pwd)" socat tcp4-l:4444,bind=127.0.0.1,reuseaddr,fork exec:./animals
```
Wenn es crasht unter Arch Linux versuchen, libc und ELF loader muessen
einigermassen zusammenpassen.
Mit
```
nc localhost 4444
```
verbinden.
## Debugging
Ich habe https://github.com/niklasb/gdbinit benutzt. `./setup.sh` installiert
eine Reihe von GDB scripts. Danach dann mit
```
export LD_LIBRARY_PATH="$(pwd)"
gdb -ex peda -ex 'tcp 4444 ./animals' -ex c
```
starten.
## Exploit
Exploit benutzt https://github.com/niklasb/ctf-tools/tree/master/pwnlib:
```
git clone https://github.com/niklasb/ctf-tools
ln -s ctf-tools/pwnlib .
./pwn.py --dbg
```