Coder Social home page Coder Social logo

mohamedelbalshy / anticensorship-mirror-python Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fightforthefuture/anticensorship-mirror-python

0.0 0.0 0.0 125 KB

Team Future Anti-censorship Alerts for Python

License: Other

Makefile 4.17% Python 95.83%

anticensorship-mirror-python's Introduction

Internet Defense League Anti-Censorship Mirror (Python app)

This project contains a simple Python Flask app to run an Anti-Censorship Network Mirror. Run this app on your server and make the Anti-Censorship Network stronger. Together we can beat government censorship forever! The project is set up to be extremely easy to deploy to Heroku, but you can run it on any Python server.

How to set up:

  1. Sign up for an API Key

  2. Deploy the app to Heroku (or your own server)

    If you deploy to your own server, please run the make command to grab the MaxMind GeoLite2 geolocation database.

  3. Configure your environment variables with the following definitions:

    API_KEY=[your API key]
    
    DOMAIN=[Full URL to your installation of the Mirror, no trailing slash]
    
    SECRET_KEY=[A random string, used by Flask]
    

    For example, if you're running the app at https://my-mirror.herokuapp.com, you could configure your environment variables using the following commands:

    heroku config:set API_KEY=foo
    
    heroku config:set DOMAIN=https://my-mirror.herokuapp.com
    
    heroku config:set SECRET_KEY=bar
    
  4. Restart server if needed. You're done!

How to test:

Simply visit the URL for your server in a browser (eg. https://anticensorship-mirror.herokuapp.com ). If everything is working, you should see a weird looking binary response like this:

W6¼��Bv¯zo{`¼�8>���¿Zcü]Má�¥w01»Üì�Øñ¤Eoýس�õLo©ã�ë^æ�ó�í�Û¼��ë�5"�gQË|9Ü`YK�;�g�=�Y�Ö?�éïË�.�ëãüEÙZaÔúå<"]ú¶! û¶w¬¥Êômx�ÈÛý·X*Ý��Aä�%?� Ö�?�Ößui�ùÒ&'ñna�ÛâÈì�Z>vÏ�¨� áUGØÛ2É÷�nád¹/ÁËÌ�ôt�J®ç÷� �JÍÂm"NîÀ*Z(ø¨�1¡b/��ð<ЮFF_V/lÒL�ò0j9Ó:��X��83RPÐ�êÃØå£Ù�

This is the encrypted data that allows sites that embed the ACN JavaScript code to communicate with the Network's central server. Essentially your Mirror is a proxy server, and because the data is RSA-encrypted and digitally signed, it's impossible to tamper with mid-stream. This protects the data against government censors and malicious Mirror servers.

You can see that the response changes if you pass the parameter ?_ac_force_locale=CN.

More information

There are tons of other ways to get involved with the Anti-Censorship Network. To learn more, visit https://www.internetdefenseleague.org/censorship/

anticensorship-mirror-python's People

Contributors

rubbingalcoholic avatar

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.