github h4ckf0r0day/obscura v0.2.1

2 hours ago

v0.2.1

Child frames now run their own scripts and talk to the parent page, MCP keeps driving the page between tool calls, and rendering, CDP, and stealth all gained fidelity and consistency fixes. 122 commits since v0.2.0.

Highlights

iframes run their own scripts. Child frames get their own V8 realm, a page can reach into its same-origin frames, postMessage flows between a page and its frames, and CDP reports the real child frame tree. Frame realms are released before the isolate they point into, fixing a class of crashes on frame-heavy pages (#600).
MCP drives the page between tool calls. The active page's task queue is pumped while the transport waits, so timers, fetches, and queued navigations (form submits, location changes, clicks) complete instead of stranding until the next tool call (#618, #640).
Rendering keeps closing on Chrome. Webfont icons and color emoji render, outset box shadows clip correctly, and textarea gets an intrinsic control box and its own JS interface, so Playwright visibility checks, clicks, and fills work on textareas.
SPA routes are reported. Same-document navigations surface after clicks and location coerces assigned values, so client-side routers (Next.js, React Router, vue-router) no longer freeze on the original route.
Stealth tells one story. --stealth applies to --dump original, ES modules load over the stealth transport instead of the plain client, and stealth requests use emulation compression.

CDP and networking

Runtime.bindingCalled is delivered to the session that subscribed.
Input.insertText embeds text as a JSON literal, so text with newlines or quotes is inserted instead of dropped.
Storage.clearCookies is implemented; cookie domains are canonicalized on every jar key, and expired updates delete the cookie.
--eval awaits promise-returning expressions, so async IIFEs resolve instead of serializing as {} (#693).
• objectId lookups escape backslashes before interpolation (#557).
fetch and XHR resolve relative URLs through the URL parser against the document base, replacing a :// substring check (#663), and follow twenty redirects per the Fetch standard.
• The stealth client applies the SSRF DNS guard, so --stealth no longer trades away protection against hostnames that resolve to private or loopback addresses.
Accept-Language can be overridden, plain GETs retry after a connection reset, and connection refusals produce a proper CDP response.

DOM and Web APIs

• DOMParser produces a <parsererror> document for malformed XML mime types, matching Chrome's signal.
Document.createEvent rejects unknown interface names (#610), and DOMStringMap is exposed globally (#599).
Function.prototype.toString keeps its native shape, and the bootstrap shim runs in an IIFE so internal DOM classes no longer leak into page script scope.
insertBefore and replaceChild run the full insertion steps, and document.write feeds one input stream per document.
• HTMLSelectElement gains parity for type, change-on-assignment, and selectedIndex.
performance.timeOrigin can no longer land in the future.

Security and robustness

Runtime.removeBinding validates binding names, closing a JS injection path into the page (#578).
DOM.setFileInputFiles is gated behind --allow-file-access, matching the file:// navigation opt-in (#579). Behavior change: Puppeteer/Playwright file uploads now fail with a clear error unless the flag is set.
• PBKDF2 iterations and output length are capped against runtime DoS (#580).
children() and ancestors() walks are bounded against cyclic DOM chains (#582), and duplicate module graphs and heap exhaustion are contained.

Tooling and docs

• New tools/live-view.mjs watches agent sessions live with target-following and adaptive pacing, with a guide under docs/.
• Cross-compilation builds generate the V8 snapshot with the target-architecture mksnapshot (#682).
• The CLI enforces --obey-robots.
• PR validation compares obstacle-course failures against the base revision and covers render, stealth, and no-render configurations.

Contributors

Thanks to @xrip, @mnaza, @aech, @Suydev, @zhangyang-crazy-one, @lisa0314, @Zed128, @aleekaz, @ousamabenyounes, @marcoripa96, and @dgcavalcante-png for contributions to this release.

Full Changelog: v0.2.0...v0.2.1

Don't miss a new obscura release

NewReleases is sending notifications on new releases.