package pe

Import Path
	debug/pe (on golang.org and go.dev)

Dependency Relation
	imports 9 packages, and imported by 0 packages

Involved Source Files Package pe implements access to PE (Microsoft Windows Portable Executable) files. pe.go section.go string.go symbol.go
Package-Level Type Names (total 14)
/* sort by: | */
COFFSymbol represents single COFF symbol table record. Name [8]uint8 NumberOfAuxSymbols uint8 SectionNumber int16 StorageClass uint8 Type uint16 Value uint32 FullName finds real name of symbol sym. Normally name is stored in sym.Name, but if it is longer then 8 characters, it is stored in COFF string table st instead.
Size uint32 VirtualAddress uint32
A File represents an open PE file. // all COFF symbols (including auxiliary symbol records) FileHeader FileHeader FileHeader.Characteristics uint16 FileHeader.Machine uint16 FileHeader.NumberOfSections uint16 FileHeader.NumberOfSymbols uint32 FileHeader.PointerToSymbolTable uint32 FileHeader.SizeOfOptionalHeader uint16 FileHeader.TimeDateStamp uint32 // of type *OptionalHeader32 or *OptionalHeader64 Sections []*Section StringTable StringTable // COFF symbols with auxiliary symbol records removed Close closes the File. If the File was created using NewFile directly instead of Open, Close has no effect. (*T) DWARF() (*dwarf.Data, error) ImportedLibraries returns the names of all libraries referred to by the binary f that are expected to be linked with the binary at dynamic link time. ImportedSymbols returns the names of all symbols referred to by the binary f that are expected to be satisfied by other libraries at dynamic load time. It does not return weak symbols. Section returns the first section with the given name, or nil if no such section exists. *T : io.Closer func NewFile(r io.ReaderAt) (*File, error) func Open(name string) (*File, error)
FormatError is unused. The type is retained for compatibility. (*T) Error() string *T : error
Reloc represents a PE COFF relocation. Each section contains its own relocation list. SymbolTableIndex uint32 Type uint16 VirtualAddress uint32
Section provides access to PE COFF section. Embed ReaderAt for ReadAt method. Do not embed SectionReader directly to avoid having Read and Seek. If a client wants Read and Seek it must use Open() to avoid fighting over the seek offset with other clients. Relocs []Reloc SectionHeader SectionHeader SectionHeader.Characteristics uint32 SectionHeader.Name string SectionHeader.NumberOfLineNumbers uint16 SectionHeader.NumberOfRelocations uint16 SectionHeader.Offset uint32 SectionHeader.PointerToLineNumbers uint32 SectionHeader.PointerToRelocations uint32 SectionHeader.Size uint32 SectionHeader.VirtualAddress uint32 SectionHeader.VirtualSize uint32 Data reads and returns the contents of the PE section s. Open returns a new ReadSeeker reading the PE section s. ( T) ReadAt(p []byte, off int64) (n int, err error) T : io.ReaderAt func (*File).Section(name string) *Section
SectionHeader is similar to SectionHeader32 with Name field replaced by Go string. Characteristics uint32 Name string NumberOfLineNumbers uint16 NumberOfRelocations uint16 Offset uint32 PointerToLineNumbers uint32 PointerToRelocations uint32 Size uint32 VirtualAddress uint32 VirtualSize uint32
StringTable is a COFF string table. String extracts string from COFF string table st at offset start. func (*COFFSymbol).FullName(st StringTable) (string, error)
Symbol is similar to COFFSymbol with Name field replaced by Go string. Symbol also does not have NumberOfAuxSymbols. Name string SectionNumber int16 StorageClass uint8 Type uint16 Value uint32
Package-Level Functions (total 2)
NewFile creates a new File for accessing a PE binary in an underlying reader.
Open opens the named file using os.Open and prepares it for use as a PE binary.
Package-Level Constants (total 78)
const COFFSymbolSize = 18
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
IMAGE_DIRECTORY_ENTRY constants
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
OptionalHeader64.DllCharacteristics and OptionalHeader32.DllCharacteristics values. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
Values of IMAGE_FILE_HEADER.Characteristics. These can be combined together.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.
OptionalHeader64.Subsystem and OptionalHeader32.Subsystem values.