IntelliJ-调试模式-在程序存储器中搜索文本 [英] IntelliJ - debug mode - search text in program memory
问题描述
我正在使用未记录的第三方库。我知道在库中深处的一个字段中某处存储了某个 String (我可以预测动态值,但我想从库的API中获取它)。
I'm working with undocumented 3rd party library. I know that there is a certain String stored somewhere in one of the fields deep in the library (dynamic value that I can predict, but I want to get it from the API of the library).
在调试模式下并在某些断点处停止时,是否可以通过 full 程序存储器进行搜索(类似于全文搜索?)?我想找到哪个对象实际存储该值的字段。
Is there a way to search (something like fulltext search?) through the full program memory while in the debug mode and while stopped on certain breakpoint? I want to find which field in which object actually stores this value.
(我知道我可以进行手动转储和grep,如果IntelliJ支持此功能,我会更感兴趣)
(I know I could do manual dump and grep, I'm more interested if IntelliJ supports this feature)
推荐答案
IntelliJ 2015和2016可以反编译Java类,因此您可以从库获取字符串,而无需进行任何调试。使用导航->声明或导航->实现,查看该类字节码的反编译版本。反编译器可以从库中获取除原始变量名和注释以外的所有内容。
IntelliJ 2015 and 2016 can decompile Java classes, so you can get the string from the library without debugging at all. Use Navigate -> Declaration or Navigate -> Implementation(s) to see a decompiled version of the byte code for the class. The decompiler can get everything except the original variable names and comments from a library.
这篇关于IntelliJ-调试模式-在程序存储器中搜索文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!