0

IDA pro is able to display the data contained in the read only data section of ELF files, but the section is defined as type SHT_PROGBITS.

To my knowledge, we cannot parse sections of this type to resolve information such as constant data/variable names.

So my question is how do tools such as IDA actually get the information in .rodata or other SHT_PROGBITS sections such as .PLT.

Thanks

1 Answer 1

1

According to ELF-format SHT_PROGBITS meens only that

The section holds information defined by the program, whose format and meaning are determined solely by the program.

But ELF-section's type is not the only (and not main) attribute for parsing data from file. There are also section's name and attributes.

Sections like .text and .data also have SHT_PROGBITS-type, but their names are special.

Generally (and very simply) the process of ELF-parsing is so:

  1. Read File header
  2. Read Section Headers table
  3. Read Symbol table
  4. Make Relocations

More info you can take from IDA's ELF-loader (IDA_Dir\loaders\elf.ldw (or dll)) or from a tools like readelf.

2
  • could you elaborate on names being special? Thanks Mar 6, 2018 at 20:09
  • Special names are .bss, .comment, .data .debug, .dynamic, .dynstr, .dynsym, .fini, .got, .hash, .init, .interp, .line, .note, .plt, .rel<name>, .rodata, .shstrtab, .strtab, .symtab, .text
    – prusanov
    Mar 7, 2018 at 6:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.