Class PeLoader

    • Field Detail

      • PE_NAME

        public static final java.lang.String PE_NAME
        The name of the PE loader
        See Also:
        Constant Field Values
      • HEADERS

        public static final java.lang.String HEADERS
        The name of the PE headers memory block.
        See Also:
        Constant Field Values

        public static final java.lang.String PARSE_CLI_HEADERS_OPTION_NAME
        PE loader option to control parsing CLI headers
        See Also:
        Constant Field Values
    • Constructor Detail

      • PeLoader

        public PeLoader()
    • Method Detail

      • findSupportedLoadSpecs

        public java.util.Collection<LoadSpec> findSupportedLoadSpecs​(ByteProvider provider)
        Description copied from interface: Loader
        If this Loader supports loading the given ByteProvider, this methods returns a Collection of all supported LoadSpecs that contain discovered load specification information that this Loader will need to load. If this Loader cannot support loading the given ByteProvider, an empty Collection is returned.
        provider - The bytes being loaded.
        A Collection of LoadSpecs that this Loader supports loading, or an empty Collection if this Loader doesn't support loading the given ByteProvider.
        Throws: - if there was an IO-related issue finding the LoadSpecs.
      • validateOptions

        public java.lang.String validateOptions​(ByteProvider provider,
                                                LoadSpec loadSpec,
                                                java.util.List<Option> options,
                                                Program program)
        Description copied from interface: Loader
        Validates the Loader's options and returns null if all options are valid; otherwise, an error message describing the problem is returned.
        Specified by:
        validateOptions in interface Loader
        validateOptions in class AbstractLibrarySupportLoader
        provider - The bytes of the thing being loaded.
        loadSpec - The proposed LoadSpec.
        options - The list of Options to validate.
        program - existing program if the loader is adding to an existing program. If it is a fresh import, then this will be null.
        null if all Options are valid; otherwise, an error message describing the problem is returned.
      • isCaseInsensitiveLibraryFilenames

        protected boolean isCaseInsensitiveLibraryFilenames()
        Description copied from class: AbstractLibrarySupportLoader
        Specifies if the library filenames specified by this loader should be exact case match or case-insensitive.

        Derived loader classes should override this method and specify if the OS that normally handles this type of binary is case-insensitive.

        isCaseInsensitiveLibraryFilenames in class AbstractLibrarySupportLoader
        - true if case-insensitive or false if case-sensitive.
      • getName

        public java.lang.String getName()
        Description copied from interface: Loader
        Gets the Loader's name, which is used both for display purposes, and to identify the Loader in the opinion files.
        The Loader's name.
      • processComments

        protected void processComments​(Listing listing,
                                       TaskMonitor monitor)
      • hasComment

        protected boolean hasComment​(int type,
                                     Address address)
      • setComment

        protected void setComment​(int type,
                                  Address address,
                                  java.lang.String comment)