Mudanças entre as edições de "VPN"

De MochilaWiki
Ir para navegaçãoIr para pesquisar
Linha 1: Linha 1:
 +
No servidor rode
 +
<source lang="bash">
 +
wget https://git.io/vpn -O openvpn-install.sh && bash openvpn-install.sh
 +
</source>
 +
 +
No cliente
 +
<source lang="bash">
 +
sudo iptables -t nat -A POSTROUTING -o tun0 -j MASQUERADE
 +
sudo iptables -A FORWARD -i tun0 -o wlan0 -m state --state RELATED,ESTABLISHED -j ACCEPT
 +
sudo iptables -A FORWARD -i wlan0 -o tun0 -j ACCEPT
 +
</source>
 +
 +
baixe o arquivo client.ovpn e rode o comando
 +
<source lang="bash">
 +
sudo openvpn client.ovpn
 +
</source>
 +
 
* http://www.brunovianna.net/documenta/?p=93
 
* http://www.brunovianna.net/documenta/?p=93
 
* https://github.com/Nyr/openvpn-install
 
* https://github.com/Nyr/openvpn-install

Edição das 15h24min de 7 de fevereiro de 2018

No servidor rode

wget https://git.io/vpn -O openvpn-install.sh && bash openvpn-install.sh

No cliente

sudo iptables -t nat -A POSTROUTING -o tun0 -j MASQUERADE
sudo iptables -A FORWARD -i tun0 -o wlan0 -m state --state RELATED,ESTABLISHED -j ACCEPT
sudo iptables -A FORWARD -i wlan0 -o tun0 -j ACCEPT

baixe o arquivo client.ovpn e rode o comando

sudo openvpn client.ovpn