Retrieving all the entries in the Win64 exception table

核能气质少年 提交于 2019-12-24 05:47:04

问题


From some clearer understanding from Win64 exception stack walking not displaying entries, I would like to be able retrieve all the entries from the Win64 exception table - including any run-time additions by the API calls RtlAddFunctionTable and RtlInstallFunctionTableCallback.

Is this possible from Delphi?


回答1:


From:

RtlVirtualUnwind(UNW_FLAG_NHANDLER,
                   LImageBase,
                   LContext.Rip,
                   LRuntimeFunction,
                   LContext,
                   HandlerData,
                   EstablisherFrame,
                   NvContext);

The HandlerData pointer contains compiler/language specific information about the exception table. If you reverse some details from System.pas, in particular the methods _DelphiExceptionHandler and FindOnExceptionDescEntry, it is possible to figure out what each entry is for - the details are against the TExcScope record definition in System.pas.



来源:https://stackoverflow.com/questions/14254193/retrieving-all-the-entries-in-the-win64-exception-table

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!