Expand description
§orb-browse
A TUI browser widget for Rust with WebDriver automation and bot detection bypass.
orb-browse provides a reusable browser component that can be embedded in terminal applications using ratatui, with the unique ability to bypass bot detection systems.
§Features
- 🌐 WebDriver Automation - Full browser control via W3C WebDriver
- 🥷 Bot Detection Bypass - Patches ChromeDriver to avoid detection
- 🎨 TUI Widget - Embeddable ratatui widget for terminal apps
- 📸 Screenshot Capture - Capture web pages as images
- 🚀 Auto-Setup - Downloads and configures ChromeDriver automatically
§Quick Start
use orb_browse::OrbBrowser;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
// Create a browser instance
let browser = OrbBrowser::new().await?;
// Navigate and capture screenshot
let screenshot = browser.capture("https://google.com", 1920, 1080).await?;
// Save screenshot
std::fs::write("google.png", &screenshot)?;
Ok(())
}§Use as TUI Widget
use orb_browse::{OrbBrowser, widget::{BrowserWidget, BrowserState}};
let browser = OrbBrowser::new().await?;
let mut state = BrowserState::new();
// Navigate to a URL
state.navigate(&browser, "https://example.com".to_string()).await?;
// In your ratatui render loop:
// frame.render_widget(BrowserWidget::new(&state), area);§How It Works
- Binary Patching: Removes
$cdc_markers from ChromeDriver - Automation Bypass Flags: Disables
--enable-automationand automation hints - JavaScript Injection: Overrides
navigator.webdriverand mocks APIs - WebDriver Protocol: Uses W3C WebDriver (not detectable CDP)
This achieves functional parity with Python’s undetected-chromedriver.
Re-exports§
pub use patcher::ChromeDriverPatcher;pub use injections::COMPREHENSIVE_BOOTSTRAP;pub use client::OrbBrowser;
Modules§
- client
- WebDriver client with bot detection bypass
- injections
- Enhanced JavaScript injections for bot detection bypass
- patcher
- ChromeDriver binary patcher
- widget
- TUI widget for embedding a browser in terminal applications
Functions§
- find_
chrome - Find Chrome/Chromium binary on the system
- launch_
patched_ chromedriver - Launch patched ChromeDriver and return the WebDriver URL and process handle