Command Palette

Search for a command to run...

Назад к скиллам
скилл № 85382

browser-automation

Use when you need to DRIVE a browser for testing — automate a defended login, hold an authenticated session, or extract cookies for downstream API replay…

БесплатноБез исполняемых скриптов
VigilOSSот VigilOSS★ 35 звёзд на GitHub

Установить browser-automation в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Об этом скилле

Browser Automation

Drive a real browser to get past a bot-defended login and hold a session, then hand that session to faster headless tooling. This skill is the mechanics; the should I use a browser at all decision lives in agent/skills/browser-semantic-analysis/SKILL.md. If the question is evidence correctness (soft 404s, browser-enforced CORS/CSP, headless-vs-headed deltas), start there. If you already know you need to log in and capture a session, you are in the right place.

When to Activate

  • You must automate an authenticated login against a bot-defended target (Akamai Bot Manager, Cloudflare, PerimeterX) and a plain curl/httpx login fails or returns a "system unavailable" block.
  • You hold valid creds and need a live session (cookies / bearer) for BOLA, authz, or surface-mapping work on the authenticated app or its API.
  • A JS-first SPA only reveals its real request surface after an interactive, in-browser login.
  • You need to extract context.cookies() into a cookie jar for curl_chrome116 / API replay.

Do not activate just to crawl JS routes with no auth wall — that is Katana -headless (see browser-semantic-analysis). Do not activate to defeat a CAPTCHA / proof-of-human gate — stop and ask the operator.

Primary tool: headed stealth Playwright Chromium

Headed real Chromium + stealth beats headless and beats curl for bot-defended sites (illustrated with fictional www.acme-bank.example): a headless or MITM-proxied automated browser hit Akamai Bot Manager at the login step; a HEADED Chromium on a residential IP with stealth hardening passed and reached the authenticated dashboard.

Tool Role
Headed Playwright + stealth Chromium Primary — solve the interactive challenge, log in, hold the session
curl_chrome116 (curl-impersonate) JA3-correct replay once you hold the session — cannot solve the login challenge
Headless Chromium / Katana -headless Weak/no bot defense, broad JS crawl only — detectable, blocked at defended logins
Selenium Legacy harnesses only — leaks navigator.webdriver, weaker structured output

Full rationale table and the load-bearing finding: agent/references/web/browser-automation-playwright.md.

Procedure

Headed Chromium runs on the host (the residential egress is the point), so every target-facing run goes through vigil assess host-exec, which writes the same audit row as a kali call (agent/shared-constraints.md §2). Bot-manager evasion is operator-authorized work: confirm the engagement allows it before starting, and surface a block as an operator decision otherwise.

1. Install (first time)

Install Playwright in the engagement directory and copy the skeleton next to it, so Node resolves playwright from the engagement's node_modules:

cd "$ENGAGEMENT_DIR"
npm i playwright && npx playwright install chromium
cp <vigil-checkout>/agent/scripts/browser/playwright-login.js "$ENGAGEMENT_DIR/scans/"

2. Pick the capture mode

  • Mode A — through-proxy auto-capture. vigil mitmproxy start, then launch the browser with PROXY=http://127.0.0.1:8080. The proxy addon auto-detects login and POSTs the captured credentials to the backend store, and posts request observations that the backend derives into the work buffer (assessment_work_items, ADR 0013) server-side. Use when the edge tolerates the proxy.
  • Mode B — direct + cookie-dump. Launch headed Chromium with no proxy on the residential IP; after login, dump context.cookies() to a Netscape jar. The MITM proxy in the TLS path can itself trip Akamai — switch to Mode B the moment the proxied browser hits a "system unavailable" block the direct browser does not.

Try Mode A first; fall back to Mode B on a bot-manager block. Record which mode you used (Mode B captures outside the mitmproxy pipeline).

3. Run the login + cookie-dump skeleton

agent/scripts/browser/playwright-login.js is parameterized, takes creds from env (no hardcoded secrets), and implements headed stealth, both modes, multi-selector two-step login, akredirect/bot-block detection, screenshot-every- step, and the Netscape jar dump.

vigil assess host-exec --tool node --technique AUTH --phase collect \
  --intent "headed stealth login + cookie dump" --target-host www.target.example -- \
  env TARGET_URL="https://www.target.example/login" USERNAME="$U" PASSWORD="$P" \
      JAR="$ENGAGEMENT_DIR/sessions/target.cookies.txt" \
      SHOTS_DIR="$ENGAGEMENT_DIR/scans/login-shots" \
  node scans/playwright-login.js
# Mode A: add  PROXY="http://127.0.0.1:8080"  to the env (after vigil mitmproxy start)
# Two-step IdP: the script submits username, waits, then fills password.
# OTP step-up: supply OTP="123456" just-in-time; never hardcode.

Stealth hardening (all jointly necessary to clear Akamai): spoof navigator.webdriver / languages / plugins / window.chrome / permissions, realistic UA + locale + t

Полный SKILL.md на GitHub

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

FAQ

Что делает скилл browser-automation?

Use when you need to DRIVE a browser for testing — automate a defended login, hold an authenticated session, or extract cookies for downstream API replay. Headed stealth Playwright Chromium is the primary tool (beats headless and beats curl against Akamai/Cloudflare bot defense). Covers the two capture modes (through-proxy auto-capture vs direct + cookie-dump when the proxy trips the edge), stealth hardening, login-flow automation, and context.cookies() -> Netscape jar for curl_chrome116 replay. NOT for deciding whether a browser is needed (that is browser-semantic-analysis).

Как установить скилл browser-automation?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл browser-automation запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить browser-automation с