示例#1
0
        internal void AddTableEntryPointers(ELFFileTableEntry entry)
        {
            // There are cases (like .NET single-file modules) where the first NT_FILE entry isn't the ELF
            // or PE header (i.e the base address). The header is the first entry with PageOffset == 0. For
            // ELF modules there should only be one PageOffset == 0 entry but with the memory mapped PE
            // assemblies, there can be more than one PageOffset == 0 entry and the first one is the base
            // address.
            if (_loadAddress == 0 && entry.PageOffset == 0)
            {
                _loadAddress = entry.LoadAddress;
            }

            // If no load address was found, will use the lowest start address. There has to be at least one
            // entry. This fixes the .NET 5.0 MacOS ELF dumps which have modules with no PageOffset == 0 entries.
            _minimumPointer = Math.Min(entry.LoadAddress, _minimumPointer);
        }
示例#2
0
 public ELFLoadedImage(ELFFile image, ELFFileTableEntry entry)
 {
     Image  = image;
     _entry = entry;
 }
示例#3
0
 public ELFLoadedImage(ELFFile image, ELFFileTableEntry entry)
 {
     Image        = image;
     Path         = entry.Path;
     _loadAddress = entry.LoadAddress;
 }