Skip to content
New issue

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

Failed to build androidpayload on windows #525

Open
green-force opened this issue Jan 19, 2022 · 3 comments
Open

Failed to build androidpayload on windows #525

green-force opened this issue Jan 19, 2022 · 3 comments

Comments

@green-force
Copy link

I try to build on windows using command: mvn clean package -Dandroid.sdk.path=/path/to/android-sdk -Dandroid.release=true -P deploy, but then I get this following error:

[ERROR] Failed to execute goal com.simpligility.maven.plugins:android-maven-plugin:4.4.3:proguard (default-proguard) on project Metasploit-AndroidPayload: : MojoExecutionException: ANDROID-040-001: Could not execute: Command = cmd.exe /X /C ""C:\Program Files\Java\jdk-11.0.11\bin\java" -Xmx512M -jar C:\Users\XXX\.m2\repository\net\sf\proguard\proguard-base\5.2.1\proguard-base-5.2.1.jar @e:\metasploit\metasploit-payloads\java\androidpayload\app\target\proguard\temp_config.cfg", Result = 1 -> [Help 1]

Any suggestion?

@timwr
Copy link
Contributor

timwr commented Jan 19, 2022

Did you replace /path/to/android-sdk with the actual SDK location?
I haven't actually tried building on windows, you're definitely better off using Linux/Macos/docker to build it.

@green-force
Copy link
Author

Did you replace /path/to/android-sdk with the actual SDK location? I haven't actually tried building on windows, you're definitely better off using Linux/Macos/docker to build it.

Yes, the actual location is C:\Users\XXX\AppData\Local\Android\Sdk which is the default sdk location of Android Studio. I will try to build on linux. Can I build it using latest java and maven version?

@green-force
Copy link
Author

I have tried building on linux but still got similar error

Screenshot

I used latest jdk and maven version

Screenshot from 2022-01-20 11-58-52

Need some help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants