lldb----打印出类中所有函数的入口地址

最近一直在研究破解相关问题,发现Objective-C中存在函数_shortMethodDescription,该函数可以打印出该类下所有函数的地址,这个地址是已经偏移之后的真实地址,免去了自己去IDA里面翻地址还要自己算的麻烦,效果相当于class-dump加内存地址,而且还有继承关系。

(lldb) po [XMHDeviceTypeSelectViewController _shortMethodDescription]
<XMHDeviceTypeSelectViewController: 0x10531f568>:
in XMHDeviceTypeSelectViewController:
	Properties:
		@property (retain, nonatomic) NSMutableArray* buttonsArray;  (@synthesize buttonsArray = _buttonsArray;)
		............
		@property (readonly, copy) NSString* debugDescription;
	Instance Methods:
		- (void) setupSubViews; (0x104b2b3bc)
		...........
		- (void) didReceiveMemoryWarning; (0x104b2b380)
in XMHBaseVC:
	Properties:
		@property (nonatomic) BOOL hasPullToRefresh;
		............
		@property (nonatomic) long largeTitleDisplayMode;
	Instance Methods:
		- (void) setTitleLabelText:(id)arg1; (0x104b1cafc)
		...........
		- (long) largeTitleDisplayMode; (0x104b1ca88)
(UIViewController ...)
已标记关键词 清除标记
©️2020 CSDN 皮肤主题: 酷酷鲨 设计师:CSDN官方博客 返回首页