Files
frida-python/examples/rpc.py
T
Ole André Vadla Ravnås 8f31efacf2 Format with the current Black
Black has changed how it lays out a call whose argument is a
multiline string, and a `with` statement holding several contexts.
2026-09-17 19:01:25 +02:00

20 lines
299 B
Python

import frida
session = frida.attach("Twitter")
script = session.create_script(
"""\
rpc.exports = {
hello: function () {
return 'Hello';
},
failPlease: function () {
oops;
}
};
"""
)
script.load()
api = script.exports_sync
print("api.hello() =>", api.hello())
api.fail_please()