Enviado em 21/03/2020 - 12:46h
Como é meu primeiro tópico gostaria de me apresentar:root@debian-s-1vcpu-1gb-nyc1-01:/etc/openvpn# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 68.183.16.1 0.0.0.0 UG 0 0 0 eth0
10.10.0.0 * 255.255.0.0 U 0 0 0 eth0
10.136.0.0 * 255.255.0.0 U 0 0 0 eth1
68.183.16.0 * 255.255.240.0 U 0 0 0 eth0
192.168.254.0 192.168.254.2 255.255.255.0 UG 0 0 0 tun0
192.168.254.2 * 255.255.255.255 UH 0 0 0 tun0
#!/bin/bash
# Flushing all rules
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT
iptables -F
iptables -X
iptables -t nat -F
iptables -t nat -X
iptables -t mangle -F
iptables -t mangle -X
iptables -t nat -A PREROUTING -s 0/0 -m tcp -p tcp --dport 3300 -j DNAT --to-destination 68.183.26.221:3389 #Este redirecionamento funciona bem.
iptables -t nat -A PREROUTING -s 0/0 -m tcp -p tcp --dport 3389 -j DNAT --to-destination 192.168.254.10:3389 #Este não funciona :(
iptables -I INPUT 1 -p tcp --match multiport --port 3300,3389 -j ACCEPT
iptables -I INPUT 2 -p udp --match multiport --port 3300,3389 -j ACCEPT
iptables -I OUTPUT 1 -p tcp --match multiport --port 3300,3389 -j ACCEPT
iptables -I OUTPUT 2 -p udp --match multiport --port 3300,3389 -j ACCEPT
echo "1" > /proc/sys/net/ipv4/conf/eth0/accept_redirects
echo "1" > /proc/sys/net/ipv4/conf/eth0/forwarding
echo "1" > /proc/sys/net/ipv4/conf/tun0/accept_redirects
echo "1" > /proc/sys/net/ipv4/conf/tun0/forwarding
echo "1" > /proc/sys/net/ipv4/conf/all/accept_redirects
echo "1" > /proc/sys/net/ipv4/conf/all/forwarding
Servidor de Backup com Ubuntu Server 24.04 LTS, RAID e Duplicati (Dell PowerEdge T420)
Visualizar câmeras IP ONVIF no Linux sem necessidade de instalar aplicativos
Atualizar Debian Online de uma Versão para outra
Instalar driver Nvidia no Debian 13
Redimensionando, espelhando, convertendo e rotacionando imagens com script
Debian 13 Trixie para Iniciantes
Convertendo pacotes DEB que usam ZSTD (Padrão Novo) para XZ (Padrão Antigo)