question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Crash upon loading libc

See original GitHub issue

hi there, this is my first time using ropper, I am following the steps in exploit development training.

I installed ropper using: sudo pip install ropper -no-cache-dir I am getting the below error when I load libc in ropper:

(ropper)> file libc-2.27.so
[INFO] Load gadgets for section: LOAD
[ERROR] Please report this error on https://github.com/sashs/ropper
[ERROR] Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 62, in cmd
    func(self, text)
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 649, in do_file
    self.__loadFile(text)
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 211, in __loadFile
    self.__loadGadgets()
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 302, in __loadGadgets
    self.__searchGadgetsFor(self.currentFileName)
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 306, in __searchGadgetsFor
    self.__rs.loadGadgetsFor(binary)
  File "/usr/local/lib/python2.7/dist-packages/ropper/service.py", line 652, in loadGadgetsFor
    load_gadgets(fc)
  File "/usr/local/lib/python2.7/dist-packages/ropper/service.py", line 637, in load_gadgets
    f.allGadgets = self.__ropper.searchGadgets(f.loader, instructionCount=self.options.inst_count, gtype=gtype,multiprocessing=self.options.multiprocessing)
  File "/usr/local/lib/python2.7/dist-packages/ropper/rop.py", line 289, in searchGadgets
    if mp.get_start_method() != 'fork':
AttributeError: 'module' object has no attribute 'get_start_method'

Am I missing something? Thanks

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
sashscommented, Aug 31, 2022

ropper --file <binary> --single Then the gadgets are loaded within a single process, which is much slower.

make python3 default on your system and use pip3 to install ropper

0reactions
init5-SFcommented, Aug 31, 2022

No, it breaks when I use --console

dev@ubuntu:~/Desktop/exp$ ropper --file libc-2.27.so --console
[INFO] Load gadgets for section: LOAD
Traceback (most recent call last):
  File "/usr/local/bin/ropper", line 11, in <module>
    load_entry_point('ropper==1.13.8', 'console_scripts', 'ropper')()
  File "/usr/local/lib/python2.7/dist-packages/ropper/__main__.py", line 36, in main
    ropper.start(sys.argv[1:])
  File "/usr/local/lib/python2.7/dist-packages/ropper/__init__.py", line 52, in start
    Console(app_options).start()
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 184, in start
    self.__loadFile(file)
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 211, in __loadFile
    self.__loadGadgets()
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 302, in __loadGadgets
    self.__searchGadgetsFor(self.currentFileName)
  File "/usr/local/lib/python2.7/dist-packages/ropper/console.py", line 306, in __searchGadgetsFor
    self.__rs.loadGadgetsFor(binary)
  File "/usr/local/lib/python2.7/dist-packages/ropper/service.py", line 652, in loadGadgetsFor
    load_gadgets(fc)
  File "/usr/local/lib/python2.7/dist-packages/ropper/service.py", line 637, in load_gadgets
    f.allGadgets = self.__ropper.searchGadgets(f.loader, instructionCo
![Screenshot 2022-08-31 180513](https://user-images.githubusercontent.com/10214861/187725834-14cd97e6-2142-430a-a017-b4650e136758.png)
unt=self.options.inst_count, gtype=gtype,multiprocessing=self.options.multiprocessing)
  File "/usr/local/lib/python2.7/dist-packages/ropper/rop.py", line 289, in searchGadgets
    if mp.get_start_method() != 'fork':
AttributeError: 'module' object has no attribute 'get_start_method'

but the syntax I used earlier works Screenshot 2022-08-31 180513

Read more comments on GitHub >

github_iconTop Results From Across the Web

1887974 – crash running libc while loading libdl
When libc.so.6 is run as the binary it is forced into a delayed position in the initialization order during ELF startup. The preloaded...
Read more >
CRASH when libc tries to load libnss in a client #3754 - GitHub
The following client produces a segmentation fault when run, due to some loading issue: #include #include #include #include #include ...
Read more >
Crash in the application in the libc - Stack Overflow
My application is receiving the data from the socket (from server)which is EVRC encoded and decoding that data. And unfortunately i dont have...
Read more >
application crashes when trying loadLibrary(), issue with ...
I am trying to debug a crash with trying to load a library that I cross-compiled using ... It seems to crash when...
Read more >
Firefox on FreeBSD crashes due to loading libc.so.6
File implementation for UNIX, it loads libc.so.6 if that is available, and then uses libffi to call into it. However, the system C...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found