SERVIDOR INTERNET, COMPARTILHAMENTO [RESOLVIDO]

1. SERVIDOR INTERNET, COMPARTILHAMENTO [RESOLVIDO]

Perfil removido
removido

(usa Nenhuma)

Enviado em 31/08/2012 - 13:32h

Mas peço a ajuda de vocês por que meu problema agora é que ficou grande..
Deixa eu tentar explicar...

No meu servidor novo está com as seguintes configurações...

Minha rede conectada na Internet

DEVICE="em1"
BOOTPROTO="nome"
IPADDR="192.168.1.2"
GATEWAY="192.168.1.1"
HWADDR="18:03:73:EB:57:7B"
NM_CONTROLLED="yes"
ONBOOT="yes"
USERCTL="no"
IPV6INIT="no"
TYPE="Ethernet"
UUID="3f297767-4615-42f8-98e7-39942e312310"

Minha rede local

DEVICE="em2"
BOOTPROTO="nome"
HWADDR="18:03:73:EB:57:7C"
IPADDR="192.168.0.2"
NM_CONTROLLED="yes"
USERCTL="no"
IPV6INIT="no"
ONBOOT="yes"
TYPE="Ethernet"
UUID="1e5f2669-24e4-457e-97f5-8292ff0e8b0e"

Meu DHCP

server-identifier "meudominio".com.br;
ddns-update-style interim;
ddns-domainname "meudominio".com.br";
deny unknown-clients;

default-lease-time 6220800;
max-lease-time 6220800;
option domain-name "meudominio".com.br";
option domain-name-servers 192.168.0.1,192.168.0.2;
option netbios-name-servers 192.168.0.2;
option netbios-node-type 0x8;
option routers 192.168.0.2;
option subnet-mask 255.255.255.0;
authoritative;

subnet 192.168.0.0 netmask 255.255.255.0{
#range 192.168.0.100 192.168.0.200;
option domain-name "meudominio.com.br";
option domain-name-servers 192.168.0.2;
option netbios-name-servers 192.168.0.2;
option netbios-node-type 0x8;
option routers 192.168.0.2;
option subnet-mask 255.255.255.0;


############### IPS E MACS #############

### SERVIDORES 01-20 ###

host sistema_manager {
hardware ethernet XX:XX:XX:XX:XX:XX;
fixed-address 192.168.0.1;
}

Essa parte está toda OK, meus computadores da Rede estão pegando os IPS que estão amarrados no MAC perfeitamente, fiz aquele esquema pra ele não pegar IP manual, usando os macs falsos..

Ta.. essa parte eu sei que ta certa por que está funcionando redondinho, tanto que as maquinas da rede conseguem pingar as duas interfaces a interna e a externa, usei aquele comando do arpa-f também...

Mas meu problema é que não consigo de maneira nenhuma colocar as maquinas para navegarem na Internet, o servidor navega... mas os computadores não.. já configurei o firewall e não consegui.. a e tem a parte do DNS também tipo, não sei bem como funciona essa parte por que usei o Bind, instalei ele, e no arquivo named.conf coloquei o ip da minha rede local, e no resolv.conf coloquei "nameserver 192.168.0.1" e "nameserver 127.0.0.1" ha! e tenho uma interface do DNS também que inicia junto com o sistema que é a em1:1 que tem as seguintes configurações:

DEVICE="em1:1"
ONBOOT="yes"
BOOTPROTO="nome"
IPADDR="187.51.85.52" <-- é outro numero, é meu DNS..
NETMASK="255.255.255.252"
TYPE="Ethernet"
USECTL="no"
IPV6INIT="no"
ONPARENT="no"

Ha! não me perguntem o que é isso, por que não sei, copiei do servidor antigo que está rodando atualmente.. e eu gostaria de entender essa parte tmb.. haa! e ela só aparece no comando "ifconfig" se estiver conectado no modem..

Ufaa! é isso...
PEÇO HUMILDIMENTE A AJUDA DE TODOS VOCÊS!!!
SOU INICIANTE...
E JÁ VI QUE AQUI NO FORUM ESTÃO TODOS SEMPRE DISPOSTOS A AJUDAR...
DESDE JÁ EU AGRADEÇO A TODOSS E DESEJO UMA BOA TARDE A TODOS!!!
Abraços..



Editar


  


2. Re: SERVIDOR INTERNET, COMPARTILHAMENTO [RESOLVIDO]

johnny borges
johnnyb

(usa Fedora)

Enviado em 31/08/2012 - 16:07h

Amigo vc ja ativo a regra de compartilhamento no firewall?


3. Compartilhamento

Perfil removido
removido

(usa Nenhuma)

Enviado em 31/08/2012 - 16:13h

Pode ser que sim! rs...
que regra seriam estas??


4. Re: SERVIDOR INTERNET, COMPARTILHAMENTO [RESOLVIDO]

johnny borges
johnnyb

(usa Fedora)

Enviado em 31/08/2012 - 16:37h

echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -o placa de rede externa -j MASQUERADE

ai vc posta seu firewall aqui e tambem confirma se vc ta recebendo o ip pelo
dhcp caso nao esteja coloque manual apenas para teste blz


5. fw

Perfil removido
removido

(usa Nenhuma)

Enviado em 31/08/2012 - 16:51h

Já tentei sim amigo, segue meu firewall.. poxa ta [*****] resolver isso cara..
quebrando a cabeça aqui..


# Source function library.
. /etc/rc.d/init.d/functions

# Source networking configuration.
. /etc/sysconfig/network

# Check that networking is up.
[ ${NETWORKING} = "no" ] && exit 0

modprobe iptable_nat
#modprobe ip_conntrack
modprobe ip_conntrack_ftp
modprobe ip_nat_ftp

INTERNAL_INTERFACE=eth1
EXTERNAL_INTERFACE=eth0
EXTERNAL_NET=192.168.1.0/24
EXTERNAL_IP=192.168.1.2
INTERNAL_NET=192.168.0.0/24
INTERNAL_IP=192.168.0.2

MX_SERVER=192.168.1.2

ANYWHERE="any/0" # Match any IP address
BROADCAST_SRC="0.0.0.0" # Broadcast Source Address
BROADCAST_DEST="255.255.255.255" # Broadcast Destination Address
CLASS_A="10.0.0.0/8" # Class-A Private (RFC-1918) Networks
CLASS_B="172.16.0.0/12" # Class-B Private (RFC-1918) Networks
CLASS_C="192.168.0.0/16" # Class-C Private (RFC-1918) Networks
CLASS_D_MULTICAST="224.0.0.0/4" # Class-D Multicast Addresses
CLASS_E_RESERVED_NET="240.0.0.0/5" # Class-E Reserved Addresses
PRIVPORTS="0:1023" # Well-Known, Privileged Port Range
UNPRIVPORTS="1024:65535" # Unprivileged Port Range
TRACEROUTE_SRC_PORTS="32769:65535" # Traceroute Source Ports
TRACEROUTE_DEST_PORTS="33434:33523" # Traceroute Destination Ports
#
# The Loopback interface defines should not be
# edited unless your Linux distribution defines
# these differently.
#

LOOPBACK_INTERFACE="lo" # The loopback interface
LOOPBACK_NETWORK="127.0.0.0/8" # Reserved Loopback Address Range

# X Window port allocation begins at 6000 and increments
# for each additional server running from 6000 to 6063.

XWINDOW_PORTS="6000:6063" # (TCP) X Windows

# SSH starts at 1023 and works down to 513 for each additional
# simultaneous incoming connection.

SSH_HI_PORTS="513:1023" # SSH Simultaneous Connections

#
# Source function library.
#

. /etc/rc.d/init.d/functions
. /etc/firewall/fwfunc.sh


case "$1" in
start)
action "Starting firewall: " /bin/true

$0 clear-rules
#exit 0

# Set the default policy to DROP


iptables -P INPUT DROP
iptables -P OUTPUT ACCEPT
iptables -P FORWARD DROP

iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT

BuildNewChain "LnD" "DROP"
BuildNewChain "LnR" "REJECT"
BuildNewChain "ScanD" "DROP"

VoidPortScan

iptables -A INPUT -i $LOOPBACK_INTERFACE -j ACCEPT
iptables -A OUTPUT -o $LOOPBACK_INTERFACE -j ACCEPT

SetKernelParameters

iptables -A FORWARD -d 192.168.0.21 -j ACCEPT # Ligia
iptables -A FORWARD -s 192.168.0.21 -j ACCEPT #

iptables -A INPUT -s 192.168.0.148 -j DROP #
iptables -A OUTPUT -s 192.168.0.148 -j DROP #
iptables -A FORWARD -s 192.168.0.148 -j DROP #
iptables -A INPUT -s 192.168.0.144 -j DROP #
iptables -A OUTPUT -s 192.168.0.144 -j DROP #
iptables -A FORWARD -s 192.168.0.144 -j DROP #


iptables -t nat -A POSTROUTING -o $EXTERNAL_INTERFACE -j MASQUERADE
#iptables -t nat -A POSTROUTING -s $INTERNAL_NET -o $EXTERNAL_INTERFACE -j SNAT --to $EXTERNAL_IP
iptables -t nat -A POSTROUTING -s 192.192.192.0 -o $EXTERNAL_INTERFACE -j SNAT --to $EXTERNAL_IP

ICMP 1
CloseNFS

AcceptNet $INTERNAL_NET
AcceptNet 192.192.192.0/24
AcceptNet 192.168.2.0/32
AcceptNet 10.8.0.0/32

iptables -A FORWARD -d 10.8.0.0/32 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/32 -j ACCEPT

iptables -A FORWARD -d 192.192.192.0/24 -j ACCEPT
iptables -A FORWARD -s 192.192.192.0/24 -j ACCEPT
iptables -A FORWARD -d 192.168.1.0/24 -s 192.192.192.0/24 -p tcp -j ACCEPT
iptables -A FORWARD -s 192.168.1.0/24 -d 192.192.192.0/24 -p tcp -j ACCEPT

FwConPort $UNPRIVPORTS '80 22 443' $EXTERNAL_IP $ANYWHERE TCP F
FwOpenPort $UNPRIVPORTS '80 20:21 22' $ANYWHERE $EXTERNAL_IP TCP

FwConPort $UNPRIVPORTS 25 $MX_SERVER $ANYWHERE TCP F
FwConPort $UNPRIVPORTS 2200 $MX_SERVER $ANYWHERE TCP F

#FwOpenPort $UNPRIVPORTS 25 $ANYWHERE $MX_SERVER TCP
#FwOpenPort $UNPRIVPORTS 110 $ANYWHERE $MX_SERVER TCP

DnsFullServer 187.59.80.54

FwOpenPort $UNPRIVPORTS 2200 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 5900 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 5901 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 5902 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 5910 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 9876 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 5920 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 10100:10150 $ANYWHERE $EXTERNAL_IP TCP

FwOpenPort $UNPRIVPORTS 443 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 11112 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 10000 $ANYWHERE $EXTERNAL_IP TCP
# FwOpenPort $UNPRIVPORTS 5010 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 3389 $ANYWHERE $EXTERNAL_IP TCP #TS
FwOpenPort $UNPRIVPORTS 3390 $ANYWHERE $EXTERNAL_IP TCP #TS
FwOpenPort $UNPRIVPORTS 1194 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 9090 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 5222 $ANYWHERE $EXTERNAL_IP TCP # Jabber
FwOpenPort $UNPRIVPORTS 8088 $ANYWHERE $EXTERNAL_IP TCP # ISS
FwOpenPort $UNPRIVPORTS 8022 $ANYWHERE $EXTERNAL_IP TCP # SSH
FwOpenPort $UNPRIVPORTS 3306 $ANYWHERE $EXTERNAL_IP TCP #

# PortForward TCP 9668 192.168.0.4 9668
# PortForward TCP 9669 192.168.0.4 9669
# PortForward TCP 9670 192.168.0.4 9670
# PortForward TCP 8666 192.168.0.4 8666
# PortForward TCP 6055 192.168.0.4 6055

FwOpenPort $UNPRIVPORTS 9666 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 9667 $ANYWHERE $EXTERNAL_IP TCP #
# FwOpenPort $UNPRIVPORTS 9668 $ANYWHERE $EXTERNAL_IP TCP #
# FwOpenPort $UNPRIVPORTS 9669 $ANYWHERE $EXTERNAL_IP TCP #
# FwOpenPort $UNPRIVPORTS 9670 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 6050 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 6052 $ANYWHERE $EXTERNAL_IP TCP #
# FwOpenPort $UNPRIVPORTS 6055 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 6062 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 6063 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 4006 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 2104 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 2222 $ANYWHERE $EXTERNAL_IP TCP #
FwOpenPort $UNPRIVPORTS 8022 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8670 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8671 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8681 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8682 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8866 $ANYWHERE $EXTERNAL_IP TCP

FwOpenPort $UNPRIVPORTS 8666 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8672 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8673 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8683 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 8684 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 6091 $ANYWHERE $EXTERNAL_IP TCP
FwOpenPort $UNPRIVPORTS 6092 $ANYWHERE $EXTERNAL_IP TCP

FwOpenPort $UNPRIVPORTS 60000:60200 $ANYWHERE $EXTERNAL_IP TCP F

FwConPort $UNPRIVPORTS 3389 $EXTERNAL_IP $ANYWHERE TCP F # TS
FwConPort $UNPRIVPORTS '7 2703' $EXTERNAL_IP $ANYWHERE TCP F #Razor
FwConPort $UNPRIVPORTS '7 2703' $EXTERNAL_IP $ANYWHERE UDP F #Razor
FwConPort $UNPRIVPORTS 6277 $EXTERNAL_IP $ANYWHERE UDP F #DCC
FwConPort $UNPRIVPORTS 5222 $EXTERNAL_IP $ANYWHERE UDP F # Jabber
FwConPort $UNPRIVPORTS 1498 $EXTERNAL_IP $ANYWHERE UDP F # sql
FwConPort $UNPRIVPORTS 1498 $EXTERNAL_IP $ANYWHERE TCP F #
FwConPort $UNPRIVPORTS 24441 $EXTERNAL_IP $ANYWHERE TCP F #Pyzor
FwConPort $UNPRIVPORTS 20:21 $EXTERNAL_IP $ANYWHERE TCP F #FTP
FwConPort $UNPRIVPORTS 8245 $EXTERNAL_IP $ANYWHERE TCP F #noip
FwConPort $UNPRIVPORTS 8080 $EXTERNAL_IP $ANYWHERE TCP F #
FwConPort $UNPRIVPORTS 3128 $EXTERNAL_IP $ANYWHERE TCP F #
FwConPort $UNPRIVPORTS 995 $EXTERNAL_IP $ANYWHERE TCP F #
FwConPort $UNPRIVPORTS 465 $EXTERNAL_IP $ANYWHERE TCP F #

iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 25 -j DROP #SMTP
iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 8080 -j DROP #PROXY
iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 3128 -j DROP #
iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 5190 -j DROP #ICQ
iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 1214 -j DROP #Kaaza
iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 6346 -j DROP #LimeWire
iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 5050 -j DROP #LimeWire

iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 5122 -j DROP #MSN
iptables -A FORWARD -p TCP -s $INTERNAL_NET -d $ANYWHERE --dport 1863 -j DROP #MSN
iptables -A FORWARD -p UDP -s $INTERNAL_NET -d $ANYWHERE --dport 1863 -j DROP #MSN

#---------------------Kproxy Orkut-------------------------------
iptables -A INPUT -d www.kproxy.com -j DROP
iptables -A FORWARD -d www.kproxy.com -j DROP
iptables -A INPUT -d kproxy.com -p tcp -j DROP
iptables -A FORWARD -d kproxy.com -p tcp -j DROP
iptables -A INPUT -d www.orkut.com -p tcp --dport 443 -j DROP
iptables -A FORWARD -d www.orkut.com -p tcp --dport 443 -j DROP
iptables -A INPUT -d orkut.com -p tcp --dport 443 -j DROP
iptables -A FORWARD -d orkut.com -p tcp --dport 443 -j DROP

#---------------------Stuffed Routing-------------------------------

iptables -A INPUT -s 255.255.255.255 -j DROP
iptables -A INPUT -s 0.0.0.0 -j DROP
iptables -A INPUT -s 255.255.255.255 -j DROP
iptables -A INPUT -s 0.0.0.0 -j DROP

iptables -A FORWARD -s $INTERNAL_NET -d login.icq.com -j DROP
iptables -A FORWARD -s $INTERNAL_NET -d scsa.yahoo.com -j DROP
iptables -A FORWARD -s $INTERNAL_NET -d 64.245.58.0/24 -j DROP #AudioGalaxy
iptables -A FORWARD -s $INTERNAL_NET -d 216.35.208.0/24 -j DROP #iMesh

# All trafic on Local Net to http is redirected do Proxy

iptables -t nat -A PREROUTING -p tcp -i $INTERNAL_INTERFACE -d orkut.com --dport 443 -j REDIRECT --to 3128
iptables -t nat -A PREROUTING -p tcp -i $INTERNAL_INTERFACE -d meboo.com --dport 443 -j REDIRECT --to 3128
# iptables -t nat -A PREROUTING -p tcp -i eth0 -d meudominio.com.br --dport 80 -j REDIRECT --to 80

iptables -t nat -A PREROUTING -p tcp -i $INTERNAL_INTERFACE -d ! 200.201.174.0/24 --dport 80 -j REDIRECT --to 3128

PortForward TCP 5900 192.192.192.2 5900
PortForward TCP 11112 192.168.0.155 11112
PortForward TCP 5901 192.168.0.5 5900
# Robo
PortForward TCP 5902 192.192.192.4 5900


PortForward TCP 3389 192.168.0.3 3389
# PortForward TCP 3389 192.168.0.12 3389

# PortForward TCP 9668 192.168.0.4 9668
# PortForward TCP 9669 192.168.0.4 9669
# PortForward TCP 9670 192.168.0.4 9670
# PortForward TCP 6055 192.168.0.4 6055

PortForward TCP 9666 192.168.0.4 9666
PortForward TCP 9667 192.168.0.4 9667
PortForward TCP 6052 192.168.0.4 6052
PortForward TCP 6062 192.168.0.4 6062
PortForward TCP 8866 192.168.0.4 8866
PortForward TCP 8670 192.168.0.4 8670
PortForward TCP 8671 192.168.0.4 8671
PortForward TCP 8681 192.168.0.4 8681
PortForward TCP 8682 192.168.0.4 8682
PortForward TCP 6063 192.168.0.4 6063

PortForward TCP 6091 192.168.0.4 6091
PortForward TCP 6092 192.168.0.4 6092

PortForward TCP 6050 192.168.0.4 6050
PortForward TCP 8666 192.168.0.4 8666
PortForward TCP 8672 192.168.0.4 8672
PortForward TCP 8673 192.168.0.4 8673
PortForward TCP 8683 192.168.0.4 8683
PortForward TCP 8684 192.168.0.4 8684



PortForward TCP 8088 192.168.0.1 80
PortForward TCP 2222 192.168.0.1 2222
PortForward TCP 4006 192.192.192.6 4006
PortForward TCP 2104 192.192.192.2 2104

PortForward TCP 3390 192.168.0.45 3389
PortForward TCP 443 192.168.0.254 443
PortForward TCP 8022 192.168.0.4 22

iptables -A FORWARD -d $INTERNAL_NET -j ACCEPT
iptables -A FORWARD -s $INTERNAL_NET -j ACCEPT

;;
stop)
action "Stoping firewall: " /bin/true
echo 1 > /proc/sys/net/ipv4/ip_forward

$0 clear-rules

iptables -t nat -A PREROUTING -p tcp -i $INTERNAL_INTERFACE -d orkut.com --dport 443 -j REDIRECT --to 3128
iptables -t nat -A PREROUTING -p tcp -i eth0 -d meudominio.com.br --dport 80 -j REDIRECT --to 80
iptables -t nat -A PREROUTING -p tcp -i $INTERNAL_INTERFACE -d ! 200.201.174.0/24 --dport 80 -j REDIRECT --to 3128


iptables -t nat -A POSTROUTING -o $EXTERNAL_INTERFACE -j MASQUERADE

PortForward TCP 5900 192.192.192.2 5900
PortForward TCP 11112 192.168.0.155 11112
PortForward TCP 5901 192.168.0.5 5900

PortForward TCP 3389 192.168.0.3 3389
PortForward TCP 8088 192.168.0.1 80
PortForward TCP 9666 192.168.0.4 9666
PortForward TCP 9667 192.168.0.4 9667
PortForward TCP 9668 192.168.0.4 9668
PortForward TCP 9669 192.168.0.4 9669
PortForward TCP 9670 192.168.0.4 9670
PortForward TCP 6050 192.168.0.4 6050
PortForward TCP 6055 192.168.0.4 6055
PortForward TCP 8681 192.168.0.4 8681
PortForward TCP 8670 192.168.0.4 8670
PortForward TCP 2222 192.168.0.1 2222
PortForward TCP 6063 192.168.0.4 6063
PortForward TCP 4006 192.192.192.6 4006
PortForward TCP 2104 192.192.192.2 2104

PortForward TCP 3390 192.168.0.45 3389
PortForward TCP 443 192.168.0.254 443

PortForward TCP 8022 192.168.0.4 22

AcceptNet $INTERNAL_NET

;;
clear-rules)
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT

iptables -t nat -P PREROUTING ACCEPT
iptables -t nat -P POSTROUTING ACCEPT
iptables -t nat -P OUTPUT ACCEPT

iptables -F
iptables -t nat -F

iptables -X
iptables -t nat -X

ifconfig eth0:1 187.59.80.54 netmask 255.255.255.252

;;

*)
echo "Usage: $0 {start|stop|restart|status}"
exit 1
esac

exit 0



6. AJUDA

Perfil removido
removido

(usa Nenhuma)

Enviado em 03/09/2012 - 10:31h

Por favor alguém!
:/


7. Orra ninguém/

Perfil removido
removido

(usa Nenhuma)

Enviado em 04/09/2012 - 08:11h

:( cade o pessoal prestativoo poww //;9


8. Re: SERVIDOR INTERNET, COMPARTILHAMENTO [RESOLVIDO]

johnny borges
johnnyb

(usa Fedora)

Enviado em 18/09/2012 - 11:14h

Amigo tente essa regra e veja se funcione

iptables -t nat -A POSTROUTING -o eth0 -s 0/0 -j MASQUERADE

desculpe a demora tive farios problemas ao mesmo tempo
mais o bom mesmo seria reformularmos o seu firewall


9. Re: SERVIDOR INTERNET, COMPARTILHAMENTO [RESOLVIDO]

Reginaldo de Matias
saitam

(usa Slackware)

Enviado em 18/09/2012 - 13:45h

Aqui esta o script de firewall com algumas regras essenciais, que faz o compartilhamento via NAT.
http://mundodacomputacaointegral.blogspot.com.br/2012/05/entendendo-o-funcionamento-de-um.html


10. RESOLVIDO

Perfil removido
removido

(usa Nenhuma)

Enviado em 19/09/2012 - 08:49h

Obrigado a todos pela colaboração..
Mas já encontrei a solução, segue o link a baixo para futuros problemas.. e diga se de passagem o autor desse blog é muito gentil, e entende o que faz..

http://blog.cesar.augustus.nom.br/instalando-o-firewall-no-linux.html

Grato, a todos.






Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts