WithSecureLabs / drozer

The Leading Security Assessment Framework for Android.
https://labs.withsecure.com/tools/drozer
Other
3.89k stars 775 forks source link

Failed install of Drozer 2.4.4 #385

Closed parkclay closed 3 years ago

parkclay commented 3 years ago

Steps to reproduce

1.I am trying to install Drozer 2.4.4 when I try to run the command "python setup.py bdist_wheel" 2.I have installed and verified the prereqs. I have cloned the repository

I receive the following error Traceback (most recent call last): File "setup.py", line 4, in import setuptools ImportError: No module named setuptools cparker@cparker-Latitude-E7470:~/drozer$

Environment

Ubuntu 20.10 cparker@cparker-Latitude-E7470:~$ java --version openjdk 11.0.9.1 2020-11-04 OpenJDK Runtime Environment (build 11.0.9.1+1-Ubuntu-0ubuntu1.20.10) OpenJDK 64-Bit Server VM (build 11.0.9.1+1-Ubuntu-0ubuntu1.20.10, mixed mode, sharing)

I have Googled the error and tried to correct it.

cparker@cparker-Latitude-E7470:~$ sudo apt-get install python-setuptools Reading package lists... Done Building dependency tree
Reading state information... Done python-setuptools is already the newest version (44.1.1-1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

1UC1F3R616 commented 3 years ago

sudo apt-get install python-setuptools

parkclay commented 3 years ago

I have already installed Python Tools

Thanks Clay cparker@CPARKER-US-LL:~$ sudo apt-get install python-setuptools [sudo] password for cparker: YSorry, try again. [sudo] password for cparker: Sorry, try again. [sudo] password for cparker: Reading package lists... Done Building dependency tree Reading state information... Done python-setuptools is already the newest version (44.1.1-1). The following package was automatically installed and is no longer required: libmessaging-menu0 Use 'sudo apt autoremove' to remove it. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

On Mon, Feb 1, 2021 at 1:31 AM Kush Choudhary notifications@github.com wrote:

sudo apt-get install python-setuptools

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/FSecureLABS/drozer/issues/385#issuecomment-770672828, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXA2BUD3YZS5XFVHE5476DS4ZRFPANCNFSM4VWWK4SA .

1UC1F3R616 commented 3 years ago

@parkclay you maybe having python3 and python2 both installed, it needs python2 to work.

I got it working, had many issue but finally it's working. Also ur jdk version is 11 which will create error at later stage and some packages like scanner for uris won't work, didn't worked for me atleast. check here for other tools that you might find useful --> https://github.com/tanprathan/MobileApp-Pentest-Cheatsheet

parkclay commented 3 years ago

Thanks, I'll check it out. cparker@CPARKER-US-LL:~$ python --version Python 2.7.17 cparker@CPARKER-US-LL:~$ python3 --version Python 3.8.6 cparker@CPARKER-US-LL:~$

On Mon, Feb 1, 2021 at 10:38 AM Kush Choudhary notifications@github.com wrote:

@parkclay https://github.com/parkclay you maybe having python3 and python2 both installed, it needs python2 to work.

  • make sure ur setup is for python2

I got it working, had many issue but finally it's working. Also ur jdk version is 11 which will create error at later stage and some packages like scanner for uris won't work, didn't worked for me atleast. check here for other tools that you might find useful --> https://github.com/tanprathan/MobileApp-Pentest-Cheatsheet

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/FSecureLABS/drozer/issues/385#issuecomment-771028843, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXA2BSCQ4IIGDBUKXDHV3DS43RIPANCNFSM4VWWK4SA .

1UC1F3R616 commented 3 years ago

@parkclay very strange, error clearly says not able to import setuptools but you have it installed and python2 is being used. I tried using it's docker image though it didn't connected, you can try that as ur last resolve.

also try this for last time pip install wheel sudo apt-get install -y python-setuptools python setup.py bdist_wheel

If this works then u will get a new error, to resolve that edit setup.py file and comment out the version() function call at the end.

parkclay commented 3 years ago

I get a weird error on the last command

cparker@CPARKER-US-LL:~$ sudo pip install wheel [sudo] password for cparker: Requirement already satisfied: wheel in /usr/lib/python3/dist-packages (0.34.2) cparker@CPARKER-US-LL:~$ sudo apt-get install -y python-setuptools Reading package lists... Done Building dependency tree Reading state information... Done python-setuptools is already the newest version (44.1.1-1). 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded. cparker@CPARKER-US-LL:~$ python setup.py bdist_wheel python: can't open file 'setup.py': [Errno 2] No such file or directory cparker@CPARKER-US-LL:~$

On Mon, Feb 1, 2021 at 10:54 AM Kush Choudhary notifications@github.com wrote:

@parkclay https://github.com/parkclay very strange, error clearly says not able to import setuptools but you have it installed and python2 is being used. I tried using it's docker image though it didn't connected, you can try that as ur last resolve.

also try this for last time pip install wheel sudo apt-get install -y python-setuptools python setup.py bdist_wheel

If this works then u will get a new error, to resolve that edit setup.py file and comment out the version() function call at the end.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/FSecureLABS/drozer/issues/385#issuecomment-771038669, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXA2BWXGWJTLV6XUUFGNLTS43TEXANCNFSM4VWWK4SA .

parkclay commented 3 years ago

I will start for scratch on the install since I have all the correct things installed and hopefully configured correctly. Clay

On Mon, Feb 1, 2021 at 11:06 AM Clay Parker parkclay@gmail.com wrote:

I get a weird error on the last command

cparker@CPARKER-US-LL:~$ sudo pip install wheel [sudo] password for cparker: Requirement already satisfied: wheel in /usr/lib/python3/dist-packages (0.34.2) cparker@CPARKER-US-LL:~$ sudo apt-get install -y python-setuptools Reading package lists... Done Building dependency tree Reading state information... Done python-setuptools is already the newest version (44.1.1-1). 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded. cparker@CPARKER-US-LL:~$ python setup.py bdist_wheel python: can't open file 'setup.py': [Errno 2] No such file or directory cparker@CPARKER-US-LL:~$

On Mon, Feb 1, 2021 at 10:54 AM Kush Choudhary notifications@github.com wrote:

@parkclay https://github.com/parkclay very strange, error clearly says not able to import setuptools but you have it installed and python2 is being used. I tried using it's docker image though it didn't connected, you can try that as ur last resolve.

also try this for last time pip install wheel sudo apt-get install -y python-setuptools python setup.py bdist_wheel

If this works then u will get a new error, to resolve that edit setup.py file and comment out the version() function call at the end.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/FSecureLABS/drozer/issues/385#issuecomment-771038669, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXA2BWXGWJTLV6XUUFGNLTS43TEXANCNFSM4VWWK4SA .

parkclay commented 3 years ago

DO you have a "preferred" set of instructions to use? Thanks Clay

On Mon, Feb 1, 2021 at 11:13 AM Clay Parker parkclay@gmail.com wrote:

I will start for scratch on the install since I have all the correct things installed and hopefully configured correctly. Clay

On Mon, Feb 1, 2021 at 11:06 AM Clay Parker parkclay@gmail.com wrote:

I get a weird error on the last command

cparker@CPARKER-US-LL:~$ sudo pip install wheel [sudo] password for cparker: Requirement already satisfied: wheel in /usr/lib/python3/dist-packages (0.34.2) cparker@CPARKER-US-LL:~$ sudo apt-get install -y python-setuptools Reading package lists... Done Building dependency tree Reading state information... Done python-setuptools is already the newest version (44.1.1-1). 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded. cparker@CPARKER-US-LL:~$ python setup.py bdist_wheel python: can't open file 'setup.py': [Errno 2] No such file or directory cparker@CPARKER-US-LL:~$

On Mon, Feb 1, 2021 at 10:54 AM Kush Choudhary notifications@github.com wrote:

@parkclay https://github.com/parkclay very strange, error clearly says not able to import setuptools but you have it installed and python2 is being used. I tried using it's docker image though it didn't connected, you can try that as ur last resolve.

also try this for last time pip install wheel sudo apt-get install -y python-setuptools python setup.py bdist_wheel

If this works then u will get a new error, to resolve that edit setup.py file and comment out the version() function call at the end.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/FSecureLABS/drozer/issues/385#issuecomment-771038669, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXA2BWXGWJTLV6XUUFGNLTS43TEXANCNFSM4VWWK4SA .

1UC1F3R616 commented 3 years ago
git clone https://github.com/mwrlabs/drozer/
cd drozer
python setup.py bdist_wheel
sudo pip install dist/drozer-2.x.x-py2-none-any.whl

possible error:

@parkclay

Yogehi commented 3 years ago

try using the docker image?

https://github.com/FSecureLABS/drozer/tree/develop/docker