I'm having trouble connecting to Tor through the Ruby-Watir webdriver.
I am using the Tor Browser package. The problem is that when I try to connect via Watir (Selenium), I cannot open Tor instead of regular Firefox.
Looking at similar problems, I tried the following:
require 'watir-webdriver'
profile = Selenium::WebDriver::Firefox::Profile.new
profile['network.proxy.socks'] = '127.0.0.1'
profile['network.proxy.socks_port'] = 9150
profile['network.proxy.type'] = 1
browser = Watir::Browser.new :firefox, :profile => profile
browser.goto [an .onion website]
When I use the previous code, I still still open the regular Firefox browser and cannot connect to the onion sites.
Any thoughts? Is there any other way to connect Tor browser to my webdriver profile?
source
share