Skip to content

Commit

Permalink
Get CC in a plaform-aware manner. (#61)
Browse files Browse the repository at this point in the history
  • Loading branch information
ltfish authored Sep 21, 2023
1 parent fcdefb3 commit 151374f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion angrop/chain_builder/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,10 @@ def func_call(self, address, args, **kwargs):
else:
raise RopException("Symbol passed to func_call does not exist in the binary")

cc = angr.DEFAULT_CC[self.project.arch.name](self.project.arch)
cc = angr.default_cc(
self.project.arch.name,
platform=self.project.simos.name if self.project.simos is not None else None,
)(self.project.arch)
func_gadget = RopGadget(address)
func_gadget.stack_change = self.project.arch.bytes
return self._func_call(func_gadget, cc, args, **kwargs)
Expand Down

0 comments on commit 151374f

Please sign in to comment.