Esta guía te ayudará a configurar un proxy Snowflake independiente en un servidor para ayudar a los usuarios censurados a conectarse a la red Tor. El único requerimiento es conectividad a Internet, sin embargo, una de las principales ventajas de los proxies Snowflake independientes es que pueden ser instalados en servidores, y ofrecen un ancho de banda más alto y una opción más confiable para usuarios detrás de NATs y cortafuegos restrictivos. Por lo tanto, recomendamos especialmente:

  1. Conectividad 24/7 a Internet
  2. Un NAT uno a uno (puedes usar esta herramienta para comportamiento de NAT para probar qué tipo de NAT tienes. Las propiedades deseables son mapeo independiente de la dirección, y filtrado independiente o bien dependiente de la dirección)
  3. A server behind no or unrestricted NAT, with incoming UDP on the whole port range of cat /proc/sys/net/ipv4/ip_local_port_range open (or the range set using the optional -ephemeral-ports-range flag).

Hay varias maneras de configurar y mantener un proxy snowflake independiente.

Configuración con Docker

Primero debes tener Docker y docker-compose instalados.

Tenemos una imagen Docker para facilitar la configuración de un proxy snowflake. Primero descarga docker-compose.yml. Luego, despliega el proxy ejecutando:

docker-compose up -d snowflake-proxy

Ahora deberías ver la salida:

Creating snowflake-proxy ... done

¡y tu proxy está corriendo!

Ansible

There is now an Ansible role to install a Snowflake proxy on Debian, Fedora, Arch Linux, FreeBSD and Ubuntu created by Jacobo Nájera. Follow the guide to run a Snowflake with Ansible.

Compilar y ejecutar desde el código fuente

  1. Primero tendrás que instalar y configurar el compilador de Go para construir el proxy independiente del código fuente. Please login using a user account with sudo rights or directly with root (in the later case omit the sudo part in the following commands). If you are running Ubuntu or Debian, you can install Go by executing sudo apt install golang. If you are using Fedora, Red Hat or Amazon Linux with sudo yum install golang or sudo dnf install golang. También puedes visitar https://golang.org/dl/. You will need Go 1.15 or newer to run the Snowflake proxy. You can check your installed version using the command go version.

  2. En segundo lugar necesitas el cliente git para descargar el código fuente de Snowflake. Please login using a user account with sudo rights or directly with root (in the later case omit the sudo part of the following commands). If you are running Ubuntu or Debian, you can install git by executing sudo apt install git. If you are using Fedora, Red Hat or Amazon Linux with sudo yum install git or sudo dnf install git. Otherwise consult the documentation for your operating system.

  3. Por favor sigue los siguientes pasos con la cuenta de usuario en la que se ha de ejecutar el proxy. Don't use root. It's recommended to create a separate snowflake account with restricted rights on the system.

  4. Clona el source code.

    git clone https://git.torproject.org/pluggable-transports/snowflake.git
    
  5. Build the Snowflake proxy.

    cd snowflake/proxy
    go build
    
  6. Run the Snowflake proxy.

    nohup ./proxy &
    

    If you want to save the proxy output to a logfile, you can use:

    nohup ./proxy >snowflake.log 2>&1 &
    
  7. Make sure the proxy is started after a reboot of the system:

    crontab -e
    

    Enter the following line (example, adapt paths to your situation)

    @reboot nohup /home/snowflake/snowflake/proxy/proxy > /home/snowflake/snowflake/proxy/snowflake.log 2>&1 &
    

    Please verify if this is working by rebooting the system and checking the log. On some Linux installations this might not work.

To keep your snowflake proxy updated, execute the following commands every few weeks (login with the user account you used during installing the proxy):

kill -9 $(pidof proxy)
cd snowflake/
git pull
cd proxy
go build
nohup ./proxy >snowflake.log 2>&1 &