Code Monkey home page Code Monkey logo

chrome-protocol-proxy's Introduction

chrome-protocol-proxy

chrome-protocol-proxy is small, reverse proxy designed for working with Chrome's DevTools protocol. It captures all commands sent to and events received from Chrome, coalesce requests with responses, unpack messages from Target domain and provide easy to read, colored output. This tool is a fork of (and heavily inspired by) chromedp-proxy.

chrome-protocol-proxy screenshot

Installation

Via homebrew

brew install wendigo/tap/chrome-protocol-proxy

Via go get

go get -u github.com/wendigo/chrome-protocol-proxy

Via docker

docker run -t -i -p 9222:9222 wendigo/chrome-protocol-proxy:latest

This image bundles headless Chrome in the latest version so debugger is ready to use (head to http://localhost:9222 to validate).

Features

Configuration flags

-d	write logs file per targetId
-delta
   show delta time between log entries
-exclude value
   exclude requests/responses/events matching pattern (default exclude = )
-i	include request frames as they are sent
-include value
   display only requests/responses/events matching pattern (default include = )
-l string
   listen address (default "localhost:9223")
-log-dir string
   logs directory (default "logs")
-m	display time in microseconds
-once
   debug single session
-q	do not show logs on stdout
-r string
   remote address (default "localhost:9222")
-s	shorten requests and responses
-version
   display version information

Demo

asciicast

chrome-protocol-proxy's People

Contributors

dependabot-preview[bot] avatar paulirish avatar wendigo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

chrome-protocol-proxy's Issues

Interactive UI

Provide interactive UI that allows searching, filtering, sending commands etc

install plugin error

when

brew install wendigo/tap/chrome-protocol-proxy

tips:

Error: wendigo/tap/chrome-protocol-proxy: wrong number of arguments (given 1, expected 0)

handle /devtools/browser endpoint

This is what's used by puppeteer. They connect to the browser endpoint and use Target.sendMessage for nearly all their stuff.

Since chrome-protocol-proxy doesnt proxy that endpoint, it doesn't seem possible to use against puppeteer.

As an example I'm trying to use it with https://github.com/GoogleChrome/puppeteer/blob/master/examples/block-images.js but changing the puppeteer.launch() line to: const browser = await puppeteer.connect({browserWSEndpoint: "ws://localhost:9223/devtools/browser/6ad89a71-164e-46a1-8c63-c9e588b0780b"});

Missing shared dependency

The chrome-protocol-proxy binary for linux-amd64 depends on libc.musl-x86_64.so.1. You don't have it in major distros, so the binary won't run. I had to do ln -s /lib64/ld-linux-x86_64.so.2 /lib/libc.musl-x86_64.so.1, after that it seems to work.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.