opsdisk / pagodo

pagodo (Passive Google Dork) - Automate Google Hacking Database scraping and searching
GNU General Public License v3.0
2.66k stars 486 forks source link

ModuleNotFoundError: No module named 'yagooglesearch' #86

Closed LauraPy closed 10 months ago

LauraPy commented 10 months ago

When i try to run,using some dork commands,i get this Traceback (most recent call last): File "/home/ethical****/Documents/pagodo/pagodo.py", line 15, in import yagooglesearch ModuleNotFoundError: No module named 'yagooglesearch'

ghost commented 10 months ago

Did you install all requirements with pip install -r requirements.txt ?

LauraPy commented 10 months ago

Yes i did installed them

opsdisk commented 10 months ago

@LauraPy Are you using a Python virtual environment? That's my recommendation instead of installing the Python libraries system-wide. Instructions are here https://github.com/opsdisk/pagodo#installation

Can you also run pip list and provide the output? You should see a line like yagooglesearch 1.7.0

@f4lkensmaz3 - Thanks for providing a potential answer before I was able to get to it.

LauraPy commented 10 months ago

Hey,sorry for the late response,and wanted also to thank you for trying to help me.I did pip list,and it shows yagooglesearch 1.7.0,I will check again and see what is going on,maybe eventually it will work,i have seen some good feedbacks about this tool,so worth to still try! Thanks again!

opsdisk commented 10 months ago

Cool, let me know if you still run into issues...I'll keep the issue open for now. Any screenshots, command line options used, or command output can help in troubleshooting.

LauraPy commented 10 months ago

I have managed finally to figure out what was wrong.This is the command, i first used and gave me troubles,i follow some guys from Hak5,i have seen in a tutorial using your tool,and the guy used this command : sudo python3 pagodo.py -d amazon.com -g dorks/files_containing_juicy_info.dorks -l 50 -s -e 35.0 -j 1.1.I have modified and used the command without those parameters,,and it seems to have worked,well until the point google blocked my ip adress for ,,performing to many requests,,.So the tool is perfectly fine,it could be the commands might have changed? Cuz the tutorial i watched was from 2 years a go... Only a question before i close,i have noticed that it pagodo doesn't saves the results anymore... It doesn't? Or maybe i haven't done something right? Thank you!

opsdisk commented 10 months ago

Yeah, some of the switches have changed since that video was done. What's is the entire command you're using? If you need to sudo, it might be a file permission issue.

LauraPy commented 10 months ago

I wrote up the command,this is the command i ran : sudo python3 pagodo.py -d amazon.com -g dorks/files_containing_juicy_info.dorks -l 50 -s -e 35.0 -j 1.1 Without sudo it would not work at all,would give me bunch of errors It is working now,i do not know if you read the whole comment i wrote.So i think it was not working because of those ,,parameters,, in the command,without them it works,with pretty limited results,but it works.Thank you!

opsdisk commented 10 months ago

I was addressing your question at the end:

Only a question before i close,i have noticed that it pagodo doesn't saves the results anymore... It doesn't? Or maybe i haven't done something right?

-o saves results to a .json file -s saves results to a .txt file

You can specify both. Since you're running pagodo using sudo, when you go to read the files, you may get a permission error because the file will be written to as the elevated sudo user.

So cat results.txt won't work, but sudo cat results.txt will work.

In general, you shouldn't need to use sudo when running pagodo though.

LauraPy commented 10 months ago

So this is what i get each time i try to run the comand without sudo,permission denied when not using sudo... python3 pagodo.py -d amazon.com -g dorks/files_containing_juicy_info.dorks
Traceback (most recent call last): File "/home/ethical/Documents/pagodo/pagodo.py", line 15, in import yagooglesearch File "/home/ethical/.local/lib/python3.11/site-packages/yagooglesearch/init.py", line 23, in log_file_handler = logging.FileHandler("yagooglesearch.py.log") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/logging/init.py", line 1181, in init StreamHandler.init(self, self._open()) ^^^^^^^^^^^^ File "/usr/lib/python3.11/logging/init.py", line 1213, in _open return open_func(self.baseFilename, self.mode, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ PermissionError: [Errno 13] Permission denied: '/home/ethical****/Documents/pagodo/yagooglesearch.py.log'

also when i try to run cat results.txt,i get this cat: results.txt: No such file or directory

opsdisk commented 10 months ago

If you do an ls -la in the /home/ethical****/Documents/pagodo directory, all the files/directories should be owned by your ethical**** user. None of them should be owned by root, which I'm guessing the /home/ethical****/Documents/pagodo/yagooglesearch.py.log is.

You have 2 options. You can either delete the log (will need to use sudo) and re-run pagodo without sudo

sudo rm -f /home/ethical****/Documents/pagodo/yagooglesearch.py.log

or change the ownership to your ethical**** user (will need to use sudo) and re-run pagodo without sudo

sudo chown ethical****:ethical**** /home/ethical****/Documents/pagodo/yagooglesearch.py.log
LauraPy commented 10 months ago

Yes it shows it is in the root.i will do the changes,Thank you very much!

opsdisk commented 10 months ago

Great to hear, going to close out the issue for now.