7 #ifndef RETDEC_LOADER_RETDEC_LOADER_ELF_ELF_IMAGE_H
8 #define RETDEC_LOADER_RETDEC_LOADER_ELF_ELF_IMAGE_H
11 #include <unordered_map>
41 using SectionList = std::vector<const retdec::fileformat::ElfSection*>;
45 ElfImage(
const std::shared_ptr<retdec::fileformat::FileFormat>& fileFormat);
47 virtual bool load()
override;
57 bool canLoadSections(
const std::vector<retdec::fileformat::Section*>& sections)
const;
Definition: elf_image.h:20
void fixBssSegments()
Definition: elf_image.cpp:502
ElfImage(const std::shared_ptr< retdec::fileformat::FileFormat > &fileFormat)
Definition: elf_image.cpp:30
retdec::fileformat::ElfSegment _extern_segment
Definition: elf_image.h:68
std::vector< const retdec::fileformat::ElfSection * > SectionList
Definition: elf_image.h:41
virtual bool load() override
Definition: elf_image.cpp:40
void createExternSegment()
Definition: elf_image.cpp:76
SegmentToSectionsTable createSegmentToSectionsTable()
Definition: elf_image.cpp:284
std::unordered_map< const retdec::fileformat::ElfSegment *, SectionList > SegmentToSectionsTable
Definition: elf_image.h:42
const Segment * addSegment(const retdec::fileformat::SecSeg *secSeg, std::uint64_t address, std::uint64_t memSize)
Definition: elf_image.cpp:382
bool loadExecutableFile()
Definition: elf_image.cpp:147
std::vector< std::uint8_t > _externFncData
Definition: elf_image.h:69
bool loadRelocatableFile()
Definition: elf_image.cpp:208
std::unordered_map< std::string, std::uint64_t > _externFncTable
Definition: elf_image.h:71
void resolveRelocation(const retdec::fileformat::Relocation &rel, const retdec::fileformat::Symbol &sym)
Definition: elf_image.cpp:598
bool canLoadSections(const std::vector< retdec::fileformat::Section * > §ions) const
Definition: elf_image.cpp:473
void applyRelocations()
Definition: elf_image.cpp:567
const std::unordered_map< std::string, std::uint64_t > & getExternFncTable() const
Definition: elf_image.h:49
Declaration of loadable image class.
Definition: archive_wrapper.h:19
Definition: elf_image.h:29
std::uint64_t size
Definition: elf_image.h:38
const retdec::fileformat::Section * section
Definition: elf_image.h:36
SectionMapInfo(const SectionMapInfo &mapInfo)
Definition: elf_image.h:33
SectionMapInfo(const retdec::fileformat::Section *section_, std::uint64_t offset_, std::uint64_t size_)
Definition: elf_image.h:30
std::uint64_t offset
Definition: elf_image.h:37