Skip to content

Commit

Permalink
Add pypanda callstack instr simple test
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew Fasano committed Jun 3, 2024
1 parent f861fb3 commit 5c548ef
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions panda/python/examples/callstack_instr.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#!/usr/bin/env python3

from sys import argv
from os import path
from pandare import Panda

arch = "x86_64" if len(argv) <= 1 else argv[1]
panda = Panda(generic=arch)

panda.load_plugin("callstack_instr", #{"verbose": "true"}
)

@panda.ppp("callstack_instr", "on_call")
def call_to(cpu, target):
print(hex(target))

@panda.queue_blocking
def driver():
panda.revert_sync("root")
print(panda.run_serial_cmd("whoami"))
panda.end_analysis()

panda.run()

0 comments on commit 5c548ef

Please sign in to comment.