A light weight http proxy based on tornado and an upstream proxy switcher using SwitchyOmega rules


License
MIT
Install
pip install ballade==0.97.6

Documentation

Ballade

Current version: 0.92

Ballade is a fast proxy switcher based on tornado built for SwitchyOmega rules

Ballade means ballade tempo, not that fast ~

This project is a fork of tornado-proxy-server project

Support python 3.4 and above, python 3.0 to 3.3 is not tested

Features and improvements

  • IPv6 over HTTP proxy support, especially for CERNET IPv6 users
  • HTTP, SOCKS5 upstream proxy support
  • TLS and HTTP protocols support
  • Switch rules support
  • Multiprocess support
  • Some bugs fixed

Usages

pip3 install ballade # If you are a linux user, you may need to run as root to add  this script to /usr/local/bin/

Copy sample/.ballade/ to your home directory

git clone https://github.com/holyshawn/ballade
cd ballade/sample/
cp -r .ballade ~/

Just run

ballade # Start with the default config directory -> /home/xxx/.ballade
ballade -c /home/xxx/.ballade # Use your own config directory

Configuration Syntax

The name of configuration file is "config.yaml"

bind:
  address: '0.0.0.0'
  port: 8080
proxy: # Keys and values must match the omega rules
  first: 'http://127.0.0.1:12345'
  second: 'socks5://127.0.0.1:23456'
  direct: 'direct://'
omega_file: 'omega.conf'

omega.conf:

The rules file should be imported from SwitchyOmega rules and named as "omega.conf"

You can also make your own copy

[SwitchyOmega Conditions]
@with result

*.cloudflare.com +first
*.t.co +second

* +direct

To Do

  • Authentication

Acknowledgements

  • @thinxer: the author of the original project

License

This project is under the MIT License. See the LICENSE file for the full license text