A Python library for automating Tor Browser with Selenium WebDriver for privacy-focused web scraping and testing.
tor-browser-selenium is a Python library that provides Selenium WebDriver bindings for automating the Tor Browser. It enables developers to programmatically control Tor Browser for tasks like web scraping, automated testing, and accessing onion services while leveraging Tor's privacy features. The library handles the integration with Tor Browser's unique configuration and supports both system Tor and programmatically managed Tor processes via Stem.
Developers and researchers who need to automate web interactions through the Tor network for privacy-focused scraping, testing onion services, or conducting anonymity-related experiments.
It offers a specialized, privacy-preserving automation solution by directly integrating with Tor Browser, unlike generic Selenium setups. Its support for headless operation, parallel execution, and programmatic Tor control via Stem provides flexibility for scalable and server-side automation tasks.
Tor Browser automation with Selenium.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Automates the actual Tor Browser, preserving its privacy settings like NoScript and anti-fingerprinting, as shown in examples accessing onion services.
Enables programmatic control of Tor processes via Stem, allowing custom SOCKS and controller ports, detailed in stem_simple.py and stem_adv.py examples.
Supports headless mode using PyVirtualDisplay for server-side automation, demonstrated in the headless.py example for GUI-less environments.
Allows running multiple Tor Browser instances concurrently for efficient tasks, as implemented in the parallel.py example.
Only works on Linux, with clear warnings against Windows and macOS use, restricting deployment to specific operating systems.
Requires manual downloading of Tor Browser and a specific geckodriver version, plus PATH configuration, adding initial setup complexity.
Inherits Tor Browser constraints, such as WebGL not working in headless mode and cookie handling issues in Private Browsing Mode, per troubleshooting notes.