Ejemplo n.º 1
0
        protected internal ImportAddressTableBase(PortableExecutableImage image, uint rva, ulong[] entries, ImportDirectoryEntryBase directoryEntry, bool isDelayed)
        {
            var calc      = image.GetCalculator();
            var imageBase = image.NTHeaders.OptionalHeader.ImageBase;
            var va        = imageBase + rva;
            var offset    = calc.RVAToOffset(rva);
            var size      = (entries.Length * (image.Is64Bit ? sizeof(ulong) : sizeof(uint))).ToUInt64();
            var section   = calc.RVAToSection(rva);

            _image   = image;
            _entries = BuildEntries(image, offset, entries);

            Location       = new Location(image, offset, rva, va, size, size, section);
            Count          = _entries.Length;
            DirectoryEntry = directoryEntry;
            IsDelayed      = isDelayed;
        }
Ejemplo n.º 2
0
 internal ImportAddressTable(PortableExecutableImage image, uint rva, ulong[] entries, ImportDirectoryEntryBase directoryEntry) : base(image, rva, entries, directoryEntry, false)
 {
 }