Questions tagged [pwntools]

pwntools is a CTF framework and exploit development library.

pwntools is a CTF framework and exploit development library.

77 questions
13
votes
1 answer

Installing pwntools on macOS

I am trying to install pwntools on macOS. Whenever I try pip3 install pwntools, it pauses for a while on Running setup.py bdist_wheel for capstone ... and then prints Failed building wheel for capstone (I assume ‘capstone’ is some dependency)…
Zack
  • 1,585
  • 1
  • 18
  • 29
8
votes
0 answers

How can I get a corefile for a PE in Python like I can with pwntools for an ELF?

If any of you are familiar with the basics of exploit development, you know that when you exploit a potential buffer overflow, normally to find the offset of your buffer that "clobbered" a specific register you want to modify, you send an input like…
J.Todd
  • 707
  • 1
  • 12
  • 34
4
votes
2 answers

Module Six has no attribute ensure_text

Out of the blue, my python installation seems to have broken. When trying to run a python script, I get the following... [michael@arch ~/Code/CTF/aero/house]$ ./solve.py Traceback (most recent call last): File…
Michael Hoefler
  • 105
  • 2
  • 9
4
votes
1 answer

LD_preload for using other versions of libc, isn't working in pwntools

I want to use other versions of library for my pwn study in pwntools, but EOF error occurred. I tried to solve this issue , changed ubuntu versions 3 times (18.04 desktop -> 14.04 desktop -> 18.04.0 server), reinstall python and pwntools 4…
synod2
  • 45
  • 1
  • 5
4
votes
1 answer

Can't create process in pwntools

I am trying to use python's pwntools. I want to start a process using from pwn import * s = process('./step1') When I do this I receive the following error message: Traceback (most recent call last): File "", line 1, in File…
Rincewind
  • 197
  • 1
  • 1
  • 9
3
votes
1 answer

Debugging a program that is opened by pwntools

I am trying to do a stackoverflow for a course at university. The binary I am to exploit has a canary, however, there is a way to leak that canary to stdout. The canary of course consists of some random bytes so I can't just read them from the…
krise
  • 485
  • 1
  • 10
  • 22
3
votes
1 answer

How to specify the process in python pwntools?

Cant set the process in Python 2.7.17 pwntools. Source code: from pwn import * s=process('/root/Dokumente/Scripts/example_program') I tried from pwn import *: root@bitpc:~# python pwn.py Traceback (most recent call last): File "pwn.py", line 1,…
BitFriends
  • 379
  • 5
  • 18
3
votes
3 answers

Pycharm - using pwntools with remote interpreter on WSL

I am using remote interpreter on pycharm on WSL (configured it with this tutorial: https://www.jetbrains.com/help/pycharm/using-wsl-as-a-remote-interpreter.html) I was able to run everything I needed successfully, but when I tried to use pwntools…
2
votes
1 answer

How to get the value from a variable with pwntools?

I'm using both pwntools and gdb to explore an ELF program and my question is how can I get the value of a variable like I do with "p " in gdb but in pwntools. I have searched but can't find nothing.
2
votes
1 answer

conda-forge can't install pwntools due to UnsatisfiableError

I created a new Conda Env with: conda create -n my_env pip python=3.8.8 then, activate my env with conda activate my_env then, as stated in anaconda docs (here) tried to install pwntools with: conda install -c conda-forge pwntools I got this…
Carlo
  • 444
  • 4
  • 12
2
votes
0 answers

Pwntools Coredump | ValueError: cannot mmap an empty file

Using pwntools, I'm trying to use the Coredump method as per this part of the pwntools docs: https://docs.pwntools.com/en/latest/elf/corefile.html?highlight=using%20corefiles#using-corefiles-to-automate-exploitation For testing purposes, I copy and…
Nick Pfeiffer
  • 151
  • 2
  • 9
2
votes
2 answers

p64() from pwntools not working correctly

I want to send input to a process which includes unprintable characters like "\x90". I when I try to send it like this: p.sendline(p64(0x414190)), my programm which prints it back, returns AA\x90. It took the "\x90" as a string, not as a byte. Can…
BitFriends
  • 379
  • 5
  • 18
2
votes
0 answers

Carriage return '\r' stops working when pwntools are imported in python3

I have this little method to print overlapping strings of 80 characters: def print80(s): pad = ' '*(80-len(s)) print((s+pad)[:80], end='\r') It works well, but if I import pwntools, for example with import pwn, it stops working: the \r…
xevous
  • 31
  • 2
2
votes
2 answers

What does pwn mean in server exploitation (in CTFs)?

Pwn - I know that this is a category in CTFs in which you exploit a server to find the flag. there is a library called pwntools, it's a CTF framework and exploit development library in python. What I can't understand is why is it called "PWN" and…
snatchysquid
  • 1,283
  • 9
  • 24
2
votes
2 answers

PwnTools recv() on output that expects input directly after

Hi I have a problem that I cannot seem to find any solution for. (Maybe i'm just horrible at phrasing searches correctly in english) I'm trying to execute a binary from python using pwntools and reading its output completely before sending some…
Arwez
  • 134
  • 1
  • 2
  • 8
1
2 3 4 5 6