Beispiel #1
0
 internal SectionHeader(ref PEBinaryReader reader)
 {
     _name                   = reader.ReadNullPaddedUTF8(PEFileConstants.SizeofSectionName);
     _virtualSize            = reader.ReadInt32();
     _virtualAddress         = reader.ReadInt32();
     _sizeOfRawData          = reader.ReadInt32();
     _pointerToRawData       = reader.ReadInt32();
     _pointerToRelocations   = reader.ReadInt32();
     _pointerToLineNumbers   = reader.ReadInt32();
     _numberOfRelocations    = reader.ReadUInt16();
     _numberOfLineNumbers    = reader.ReadUInt16();
     _sectionCharacteristics = (SectionCharacteristics)reader.ReadUInt32();
 }
Beispiel #2
0
            sizeof(int);    // SectionCharacteristics

        internal SectionHeader(ref PEBinaryReader reader)
        {
            Name                   = reader.ReadNullPaddedUTF8(NameSize);
            VirtualSize            = reader.ReadInt32();
            VirtualAddress         = reader.ReadInt32();
            SizeOfRawData          = reader.ReadInt32();
            PointerToRawData       = reader.ReadInt32();
            PointerToRelocations   = reader.ReadInt32();
            PointerToLineNumbers   = reader.ReadInt32();
            NumberOfRelocations    = reader.ReadUInt16();
            NumberOfLineNumbers    = reader.ReadUInt16();
            SectionCharacteristics = (SectionCharacteristics)reader.ReadUInt32();
        }
Beispiel #3
0
 internal SectionHeader(ref PEBinaryReader reader)
 {
     name = reader.ReadUTF8(PEFileConstants.SizeofSectionName);
     virtualSize = reader.ReadInt32();
     virtualAddress = reader.ReadInt32();
     sizeOfRawData = reader.ReadInt32();
     pointerToRawData = reader.ReadInt32();
     pointerToRelocations = reader.ReadInt32();
     pointerToLineNumbers = reader.ReadInt32();
     numberOfRelocations = reader.ReadUInt16();
     numberOfLineNumbers = reader.ReadUInt16();
     sectionCharacteristics = (SectionCharacteristics)reader.ReadUInt32();
 }
Beispiel #4
0
        internal CorHeader(ref PEBinaryReader reader)
        {
            // byte count
            reader.ReadInt32();

            MajorRuntimeVersion = reader.ReadUInt16();
            MinorRuntimeVersion = reader.ReadUInt16();
            MetadataDirectory   = new DirectoryEntry(ref reader);
            Flags = (CorFlags)reader.ReadUInt32();
            EntryPointTokenOrRelativeVirtualAddress = reader.ReadInt32();
            ResourcesDirectory               = new DirectoryEntry(ref reader);
            StrongNameSignatureDirectory     = new DirectoryEntry(ref reader);
            CodeManagerTableDirectory        = new DirectoryEntry(ref reader);
            VtableFixupsDirectory            = new DirectoryEntry(ref reader);
            ExportAddressTableJumpsDirectory = new DirectoryEntry(ref reader);
            ManagedNativeHeaderDirectory     = new DirectoryEntry(ref reader);
        }
Beispiel #5
0
        internal CorHeader(ref PEBinaryReader reader)
        {
            // byte count
            reader.ReadInt32();

            MajorRuntimeVersion = reader.ReadUInt16();
            MinorRuntimeVersion = reader.ReadUInt16();
            MetadataDirectory = new DirectoryEntry(ref reader);
            Flags = (CorFlags)reader.ReadUInt32();
            EntryPointTokenOrRelativeVirtualAddress = reader.ReadInt32();
            ResourcesDirectory = new DirectoryEntry(ref reader);
            StrongNameSignatureDirectory = new DirectoryEntry(ref reader);
            CodeManagerTableDirectory = new DirectoryEntry(ref reader);
            VtableFixupsDirectory = new DirectoryEntry(ref reader);
            ExportAddressTableJumpsDirectory = new DirectoryEntry(ref reader);
            ManagedNativeHeaderDirectory = new DirectoryEntry(ref reader);
        }
Beispiel #6
0
            sizeof(int);    // SectionCharacteristics

        internal SectionHeader(ref PEBinaryReader reader)
        {
            Name = reader.ReadNullPaddedUTF8(NameSize);
            VirtualSize = reader.ReadInt32();
            VirtualAddress = reader.ReadInt32();
            SizeOfRawData = reader.ReadInt32();
            PointerToRawData = reader.ReadInt32();
            PointerToRelocations = reader.ReadInt32();
            PointerToLineNumbers = reader.ReadInt32();
            NumberOfRelocations = reader.ReadUInt16();
            NumberOfLineNumbers = reader.ReadUInt16();
            SectionCharacteristics = (SectionCharacteristics)reader.ReadUInt32();
        }