# HG changeset patch # User Henry Precheur # Date 1490164009 25200 # Tue Mar 21 23:26:49 2017 -0700 # Node ID 367d4f8edb2f4aad73eeecc293209869c60b555c # Parent 8e666bed6306ff92119ecb6e6a864f682c430533 Add readme diff --git a/README.md b/README.md new file mode 100644 --- /dev/null +++ b/README.md @@ -0,0 +1,44 @@ +Dependencies +============ + + - stunnel + - HTTP forwarding proxy + +In this directory (root fo the repo): + + $ go get -u github.com/saucelabs/sauceproxy-rest + $ go build github.com/saucelabs/sauceproxy-rest/cmd/sauceproxy_ctl + $ go get -u bitbucket.org/henry/kgp + $ go build bitbucket.org/henry/kgp/cmd/kgpdemux + +We’ll use goproxy-basic as our HTTP proxy, because it works out of the box: + + $ go get -u github.com/elazarl/goproxy + $ go build github.com/elazarl/goproxy/examples/goproxy-basic + +Let’s start our tunnel: + + $ export SAUCE_USERNAME=... + $ export SAUCE_ACCESS_KEY=... + $ ./scfs.sh + ... + ready + $ + +Once we have our tunnel started, we’ll start stunnel to connect to the tunnel +via SSL: + + $ stunnel ./stunnel.conf + ... + +Now we need to connect the KGP demultiplexer to stunnel’s unix domain socket to +start demultiplexing the decrypted traffic in clear: + + $ kgpdemux unix:///tmp/scfs_stunnel.sock tcp://localhost:8080 + +We then start our HTTP proxy on localhost 8080 to forward traffic: + + $ ./goproxy-basic + +Tada! We now have a working secure forwarding HTTP proxy enterprise ready to +rock!