VirtualBox

Ignore:
Timestamp:
Jul 28, 2014 5:52:58 PM (11 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
95276
Message:

SUP,IPRT: Implemented forwarder support in RTLdr and cleaned up some the ordinal mess. Resolved imports when doing the process verification/purification runs other than SUPHARDNTVPKIND_CHILD_PURIFICATION. This is necessary since 32-bit windows combine .text with .rdata, and we don't want to overwrite the import table after it has been snapped. Include read-only sections in the verfication runs.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/include/internal/ldr.h

    r51770 r52213  
    217217     *
    218218     * @returns iprt status code.
     219     * @retval  VERR_LDR_FORWARDER forwarder, use pfnQueryForwarderInfo. Buffer size
     220     *          in @a pValue.
    219221     * @param   pMod        Pointer to the loader module structure.
    220222     * @param   pvBits      Pointer to bits returned by RTLDROPS::pfnGetBits(), optional.
    221223     * @param   BaseAddress The image base address to use when calculating the symbol value.
     224     * @param   iOrdinal    Symbol table ordinal, UINT32_MAX if the symbol name
     225     *                      should be used.
    222226     * @param   pszSymbol   The symbol name.
    223227     * @param   pValue      Where to store the symbol value.
    224228     * @remark  Extended loader feature.
    225229     */
    226     DECLCALLBACKMEMBER(int, pfnGetSymbolEx)(PRTLDRMODINTERNAL pMod, const void *pvBits, RTUINTPTR BaseAddress, const char *pszSymbol, RTUINTPTR *pValue);
     230    DECLCALLBACKMEMBER(int, pfnGetSymbolEx)(PRTLDRMODINTERNAL pMod, const void *pvBits, RTUINTPTR BaseAddress,
     231                                            uint32_t iOrdinal, const char *pszSymbol, RTUINTPTR *pValue);
     232
     233    /**
     234     * Query forwarder information on the specified symbol.
     235     *
     236     * This is an optional entrypoint.
     237     *
     238     * @returns iprt status code.
     239     * @param   pMod        Pointer to the loader module structure.
     240     * @param   pvBits      Pointer to bits returned by RTLDROPS::pfnGetBits(),
     241     *                      optional.
     242     * @param   iOrdinal    Symbol table ordinal of the forwarded symbol to query.
     243     *                      UINT32_MAX if the symbol name should be used.
     244     * @param   pszSymbol   The symbol name of the forwarded symbol to query.
     245     * @param   pInfo       Where to return the forwarder information.
     246     * @param   cbInfo      The size of the pInfo buffer. The pfnGetSymbolEx
     247     *                      entrypoint returns the required size in @a pValue when
     248     *                      the return code is VERR_LDR_FORWARDER.
     249     * @remark  Extended loader feature.
     250     */
     251    DECLCALLBACKMEMBER(int, pfnQueryForwarderInfo)(PRTLDRMODINTERNAL pMod, const void *pvBits, uint32_t iOrdinal,
     252                                                   const char *pszSymbol, PRTLDRIMPORTINFO pInfo, size_t cbInfo);
    227253
    228254    /**
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette