Skip to content

Target process crashes on detach/script reload with Java hooks installed (9.1.6) #18

Description

@hedger

frida -U -l java.js com.android.terminal
On editing script or detaching from target process it crashes.
Crashes don't happen if I don't set up a hook.

java.js:

function onLoad() {
    console.log("Loaded.")

    Java.perform( function() { 
      URL = Java.use('java.net.URL');
      URL.getHost.implementation = function () {
        console.log("inside hook!");
        return this.getHost();
      };
    });

    Java.perform( function() { 
      url = URL.$new('http://www.ikke.no/');
      host = url.getHost();
      console.log('host=' + host);
    });
}
onLoad();

Android 6.0.1, CM13. Device is Wileyfox Swift.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions