From fb9cfc6683ea547d192a9a01d52fe116689215ab Mon Sep 17 00:00:00 2001 From: doron zarhi Date: Wed, 30 Mar 2022 11:46:06 +0300 Subject: [PATCH] darwin: symbol: add region property --- src/rpcclient/rpcclient/darwin/symbol.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/rpcclient/rpcclient/darwin/symbol.py b/src/rpcclient/rpcclient/darwin/symbol.py index 14173af8..3910d34f 100644 --- a/src/rpcclient/rpcclient/darwin/symbol.py +++ b/src/rpcclient/rpcclient/darwin/symbol.py @@ -11,6 +11,13 @@ def objc_call(self, selector, *params, **kwargs): return self._client.symbols.objc_msgSend(self, sel, *params, **kwargs) + @property + def region(self): + """ get corresponding region """ + for region in self._client.processes.get_by_pid(self._client.pid).regions: + if (self >= region.start) and (self <= region.end): + return region + @property def cfdesc(self): """