logoalt Hacker News

Show HN: Wirebrowser – A JavaScript debugger with breakpoint-driven heap search

64 pointsby fcavallarinlast Wednesday at 2:30 PM15 commentsview on HN

Hi HN!

I'm building a JavaScript debugger called Wirebrowser. It combines network inspection, request rewriting, heap snapshots, and live object search.

The main experimental feature is BDHS (Breakpoint-Driven Heap Search): it hooks into the JavaScript debugger and automatically captures a heap snapshot at every pause and performs a targeted search for the value or structure of interest. This reveals the moment a value appears in memory and the user-land function responsible for creating it.

Another interesting feature is the Live Object Search: it inspects runtime objects (not just snapshots), supports regex and object similarity, and lets you patch objects directly at runtime.

Whitepaper: https://fcavallarin.github.io/wirebrowser/BDHS-Origin-Trace

Feedback very welcome, especially on whether BDHS would help your debugging workflow.


Comments

klaushougesen1last Thursday at 6:13 AM

Great effort!, this stuff is hard to do - so applause for getting something shipped! popped an issue into you issues list.

I sometimes find these tools crash hard when pushed via large memory items, huge blobs of code, long base64 strings etc. Even chrome dev tools crash hard on large WS Messages.

Also perhaps post the video near the top instead of hiding it in the origin paper :), kids like videos these days.

https://www.youtube.com/watch?v=WA5nHk-6UJc

show 1 reply
core-explorerlast Thursday at 11:52 AM

This is very cool. I am a big believer in tools analyzing a sequence of heap snapshots to automate the time-consuming parts of manual debugging.

I am working on doing something similar in C++, where there is an additional obstacle of recreating the objects from a memory snapshot without runtime support.

show 1 reply
paulirishlast Thursday at 7:24 AM

Very impressive to see the primitives of CDP be used for such a different DX than what's in existing devtools. Really well done.

show 1 reply
doomerhunterlast Thursday at 3:54 PM

Looks very cool. Wondering what the client-side security researchers will be able to find with that. A friend of mine is developping DomLoggerpp [1] notably to monitor and debug JavaScript sinks.

[1] https://github.com/kevin-mizu/domloggerpp

show 1 reply
Vinnllast Thursday at 2:55 PM

I kinda needed to see a video to get an idea of what this does. There's one linked at the bottom of the page: https://www.youtube.com/watch?v=WA5nHk-6UJc

Nice work!

Sn0wCoderlast Thursday at 7:48 AM

Only had a minute to install, build and use the app; but wow this is great! Thank you for building and showing us Wirebrowser. Are you building this because other tools do not meet your needs? I have not run across any tool(s) that combine all of these features into one package so hoping you all success with this release.

show 1 reply
Veservlast Thursday at 8:20 AM

BDHS seems strictly less powerful than a time travel debugger. You can just set a hardware breakpoint and run backwards until the value is set.

Why not just do proper time travel? Is that absent for Javascript?

show 2 replies
ridwanclast Thursday at 11:24 AM

[dead]