Skip to content

[bug] Objection does not function on newer Android (and Play Services) versions due to outdated frida-java-bridge included in the Objection agent #800

@d235j

Description

@d235j

Describe the bug
Objection does not function on recent Android and Google Play Services versions due to an ART (Android Runtime) update that breaks the shipped version of frida-java-bridge. This shipped version is v7.0.10, referenced from agent/package-lock.json. A newer version has been shipped which fixes this bug.

To Reproduce
Steps to reproduce the behavior:

Attempt to use an Objection command such as android sslpinning disable.

Similar Issues
The upstream bug report is at frida/frida#3713. This has been fixed upstream, but is a bug in frida-java-bridge, not Frida itself. While frida-tools bundles a version of frida-java-bridge, it is separately included in the Objection agent, therefore merely updating the frida-tools that pip or a similar tool installs alongside Objection is insufficient.

Expected behavior
The command executes properly.

Evidence / Logs / Screenshots
The following output is generated:

A Frida agent exception has occurred.
Error: Unable to find copied methods in java/lang/Thread; please file a bug
    at <anonymous> (/src/index.js:3860)
    at <anonymous> (/src/index.js:2847)
    at getArtClassSpec (/src/index.js:3874)
    at compileModule (/src/index.js:9475)
    at ensureInitialized (/src/index.js:9444)
    at build (/src/index.js:9358)
    at _make (/src/index.js:11262)
    at use (/src/index.js:11141)
    at <anonymous> (/src/index.js:13369)
    at <anonymous> (/src/index.js:2847)
    at _performPendingVmOpsWhenReady (/src/index.js:13407)
    at perform (/src/index.js:13348)
    at <anonymous> (/src/index.js:13544)
    at Promise (native)
    at wrapJavaPerform (/src/index.js:13545)
    at sslContextEmptyTrustManager (/src/index.js:20739)
    at disable (/src/index.js:20924)
    at androidSslPinningDisable (/src/index.js:21462)
    at call (native)
    at handleRpcMessage (/frida/runtime/message-dispatcher.js:39)
    at handleMessage (/frida/runtime/message-dispatcher.js:25)

Environment (please complete the following information):

  • Device: Google Pixel 3a
  • OS: Android 12
  • Play Services Version: 26.18.33 (190400-913931251)
  • Frida Version: 17.9.10
  • Objection Version: 1.12.4

Application
Any application

Additional context
To fix this, do the following:
Upgrade the frida-java-bridge version to the latest (currently 7.0.13) by running npm upgrade frida-java-bridge from the agent subdirectory
Rebuild the agent as per the instructions.

I can confirm that this fixes the bug, and allows Objection to work with the latest Android and Play Services versions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    freshissueDefault label for new, untriaged issues.

    Type

    No type
    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