NullArray / DorkNet

Selenium powered Python script to automate searching for vulnerable web apps.
GNU General Public License v3.0
337 stars 103 forks source link

Capabilities Error #10

Closed b5019628 closed 5 years ago

b5019628 commented 5 years ago

Using Selenium 3.7.0 and Firefox Esr or even Firefox I get the following; (also got a friend to run and same error.)

Traceback (most recent call last): File "dorknet.py", line 154, in proc_one = search() File "dorknet.py", line 107, in search driver = webdriver.Firefox() File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/firefox/webdriver.py", line 154, in init keep_alive=True) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 151, in init self.start_session(desired_capabilities, browser_profile) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 240, in start_session response = self.execute(Command.NEW_SESSION, parameters) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 308, in execute self.error_handler.check_response(response) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/errorhandler.py", line 194, in check_response raise exception_class(message, screen, stacktrace) selenium.common.exceptions.WebDriverException: Message: Unable to find a matching set of capabilities

NullArray commented 5 years ago

Hi, thank you for reporting the issue. I have been experiencing similar issues as well. I updated my Geckodriver to the latest release. For me it resolved the problem.

The latest release can be found at the link below.

https://github.com/mozilla/geckodriver/releases

And i have updated the installer shell script that comes with the DorkNet repo to insure any future installs with it will get the most recent release as well.

https://github.com/NullArray/DorkNet/commit/e12f75ddd86a290e6f5e54f5594071a95bcb06fd

NullArray commented 5 years ago

If you're still experiencing issues after the update let me know. You need to have the stand-alone binary for the Geckodriver, which you can find at the link i provided.

b5019628 commented 5 years ago

Finally got it working! Spent too much time on fixing this. I uninstalled pretty much everything, went through and reinstalled ensuring I did the latest versions + correct architecture versions. Ran as root to give permissions than ran Dorknet using a separate user. Done a lot and finally got it working.

Tried quite a bit on Kali but could never get it working. I've done a completely fresh install of Ubuntu to test on. Using the Gecko-Setup.sh gives "./gecko-setup.sh: line 50: syntax error near unexpected token `}'
./gecko-setup.sh: line 50: `}'".

I've opened the setup file and used the wget link in there to install Geckodriver then used the commands following it. Reverted Firefox to version 50, used requirements.txt to install everything and I'm still getting the error. It also doesn't work with an updated version of Firefox.

Firefox = 50
Geckodriver  = 0.23.0
Blessings = 1.7
Python = 2.7
Selenium = 3.14.1

Get the following:

[+]Would you like DorkNet to proxy it's connection to the search engine?
[Y]es/[N]o: n

[+]Establishing unproxied connection...

Traceback (most recent call last):
  File "./dorknet.py", line 154, in <module>
    proc_one = search()
  File "./dorknet.py", line 107, in search
    driver = webdriver.Firefox()
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/firefox/webdriver.py", line 174, in __init__
    keep_alive=True)
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 157, in __init__
    self.start_session(capabilities, browser_profile)
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 252, in start_session
    response = self.execute(Command.NEW_SESSION, parameters)
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 321, in execute
    self.error_handler.check_response(response)
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.SessionNotCreatedException: Message: Unable to find a matching set of capabilities