plasma-disassembler / plasma

Plasma is an interactive disassembler for x86/ARM/MIPS. It can generates indented pseudo-code with colored syntax.
GNU General Public License v3.0
3.05k stars 275 forks source link

AttributeError: 'str' object has no attribute 'decode' #72

Closed gipi closed 8 years ago

gipi commented 8 years ago

Fresh install from master (the same using the Dockerfile). Every ELF file I try to open I receive the following error

$ ./run_plasma.py /bin/ls -x main
Traceback (most recent call last):
  File "/plasma/run_plasma.py", line 23, in <module>
    console_entry()
  File "/plasma/plasma/main.py", line 36, in console_entry
    if not gctx.load_file():
  File "/plasma/plasma/lib/__init__.py", line 196, in load_file
    self.db)
  File "/plasma/plasma/lib/disassembler.py", line 102, in __init__
    self.load_symbols()
  File "/plasma/plasma/lib/disassembler.py", line 167, in load_symbols
    self.binary.load_dyn_sym()
  File "/plasma/plasma/lib/fileformat/elf.py", line 276, in load_dyn_sym
    self.__register_relocs(reloc_sec)
  File "/plasma/plasma/lib/fileformat/elf.py", line 413, in __register_relocs
    self.__save_symbol(reloc, reloc.symbol.entry.st_value)
  File "/plasma/plasma/lib/fileformat/elf.py", line 345, in __save_symbol
    name = rel.symbol.name.decode()
AttributeError: 'str' object has no attribute 'decode'

I'm trying this on an Ubuntu

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.5 LTS
Release:    14.04
Codename:   trusty
ghost commented 8 years ago

Thanks !

gipi commented 8 years ago

thanks!