We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Below is a very simple code that uses rpc.exports
import urllib.request import os import time import frida import sys import threading import traceback jscode = """ 'use strict'; rpc.exports = { begin: function (username, password) { setImmediate(main(username, password)); console.log("inside") } }; function main(username, password) { console.log("inside main") } """ device = frida.get_usb_device() package_name = 'com.myapp' script = None try: device.kill(package_name) except: pass try: os.system("adb shell pm clear " + package_name) app = [package_name] pid = device.spawn(app) time.sleep(5) session = device.attach(pid) device.resume(pid) def on_message(message, data): if message['type'] == 'send': print(message['payload']) elif message['type'] == 'error': print(message['stack']) script = session.create_script(jscode) script.on('message', on_message) script.load() print(script.exports.begin("myusername", "mypassword")) #print(script.exports.sub(5, 3)) print("Done with that begin function") time.sleep(45) session.detach() except BaseException as e: traceback.print_exc() pass print("DONE") print("---------------------------------------------")
I get the following error when I run the above script
TypeError: cannot read property 'apply' of undefined at [anon] (duk_hobject_props.c:2385) at frida/runtime/core.js:57
Is this a bug? or something I am doing wrong?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Below is a very simple code that uses rpc.exports
I get the following error when I run the above script
Is this a bug? or something I am doing wrong?
The text was updated successfully, but these errors were encountered: