This repository has been archived by the owner on Jun 12, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
How to install
JHK edited this page Jul 6, 2012
·
3 revisions
- Java JDK at least in version 6
- Maven
- optipng
- jpegoptim
- openssl (for SPDY only)
On a Ubuntu 12.04 you can install all the requirements with a single line:
sudo apt-get install openjdk-7-jdk maven optipng jpegoptim openssl
To get the HTTP proxy running is pretty easy.
- Get the code:
git clone https://github.com/JHK/jLange.git
- Build the project:
cd jLange && mvn clean install
- Run the proxy:
./run.sh
function FindProxyForURL(url, host) {
if (shExpMatch(url, "http://*")) { return "PROXY localhost:8080; DIRECT"; }
return "DIRECT";
}
- Create or edit a PAC file (e.g.
~/pac.js
) with content above (replace localhost with your proxy): - Update your browser to use this file for proxy detection
- Visit
about:config
- Set
network.http.proxy.pipelining
totrue
No further setup needed due chrome currently does not support HTTP pipelining for proxies.
For a SPDY proxy you need to build a certificate signed from a CA, so this might getting more complicated.
- Get the code:
git clone https://github.com/JHK/jLange.git
- Build the project:
cd jLange && mvn clean install
- Setup a CA:
./tools/create_ca.sh
(keep the password in mind) - Create a server certificate:
./tools/create_self_signed_cert.sh
- To sign the certificate you need the password of the CA
- The CN must be the IP or Hostname of the proxy server
- Copy proxy properties:
cp ./src/main/resources/jLange.properties .
- Setup proxy:
org.jlange.proxy.spdy.enabled=true
org.jlange.proxy.spdy.ssl.store=pki/CA/private/rootserver.jks
org.jlange.proxy.spdy.ssl.key=<YOUR_CERTIFICATE_PASSWORD>
- Run the proxy:
./run.sh
- This script includes a parameter for the jvm to include NPN support which is mandatory for getting SPDY running
Currently only Chrome/Chromium with at least version 20 support SPDY proxies.
function FindProxyForURL(url, host) {
if (shExpMatch(url, "http://*")) { return "HTTPS localhost:8443; DIRECT"; }
return "DIRECT";
}
- Create or edit a PAC file (e.g.
~/pac.js
) with content above (replace localhost with your proxy): - Update your browser to use this file for proxy detection
- Import ca.crt into the trusted certificates