+ Responder ao Tópico



  1. #1
    perdiga
    Visitante

    Padrão problemas dns, firewall

    ola pessoal, estou precisando de uma força de vcs.
    O que esta acontecendo é o seguinte meu dns interno não esta funcionando, se eu digito meu ip externo na rede interna ele não aparece nada, se eu dou um telnet ip_externo 25,110 qualquer coisa ele não conecta, mas de fora esta funcionando perfeitamente, esse problema começou quando resolvi separar os serviços de uma máquina que fazia tudo sozinha, montei dois servidores um de web e outro de e-mail, e deixei a outra máquina com firewall, proxy e dns os arquivo resolv.conf das máquinas estão sendo apontadas para o servidor dns normalmente, mas não funciona, agora não sei se isso é problema de firewall ou dns, porque se fosse dns ao menos o ip_externo deveria retornar algo correto?
    acho que tenho que adicionar alguma regra no firewall de redirecionamento interno mas num sei como.

    bom galera se alguem tiver alguma ideia, ja estou com esse problema a mais de 1 mês, e não consigo resolver..

    agradeço vcs desde agora ....

    abraço

  2. #2
    perdiga
    Visitante

    Padrão problemas dns, firewall

    e ai pessoal, alguem tem alguma ideia do que seja...

    não consigo dar um telnet da minha rede interna para o ip_externo

    esx telnet ip_externo 25 não vai nem na porta 80 nem 110 nada


    alguem para me dar uma força ai

    valeu..

  3. #3
    sarna
    Visitante

    Padrão problemas dns, firewall

    Citação Postado originalmente por perdiga
    não consigo dar um telnet da minha rede interna para o ip_externo
    esx telnet ip_externo 25 não vai nem na porta 80 nem 110 nada
    digita aí um iptables -L
    e posta aí pra nós vermos...
    Você não explicou muito bem... mas faz isso aí e posta aqui que ja da pra ver se é no firewall ou não!


  4. #4
    perdiga
    Visitante

    Padrão problemas dns, firewall

    Chain INPUT (policy DROP)
    target prot opt source destination
    ACCEPT all -- anywhere anywhere
    ACCEPT tcp -- 192.168.100.0/24 anywhere multiport ports ftp-data,ftp,ssh,imap2,smtp,www,pop3,3128,domain,sunrpc,2049,745,676
    ACCEPT udp -- 192.168.100.0/24 anywhere multiport ports domain,sunrpc,673,2049
    ACCEPT icmp -- 192.168.100.0/24 anywhere
    ACCEPT all -- 10.0.0.0/8 anywhere
    FORA all -- anywhere anywhere
    DROP all -- anywhere 207-36-232-140.ptr.primarydns.com

    Chain FORWARD (policy DROP)
    target prot opt source destination
    DROP all -- anywhere 207-36-232-140.ptr.primarydns.com
    ACCEPT tcp -- 192.168.100.233 anywhere tcp dpt:1863
    ACCEPT tcp -- 192.168.100.17 anywhere tcp dpt:1863
    ACCEPT tcp -- 192.168.100.6 anywhere tcp dpt:1863
    ACCEPT tcp -- 192.168.100.12 anywhere tcp dpt:1863
    ACCEPT tcp -- 192.168.100.30 anywhere tcp dpt:1863
    ACCEPT tcp -- 192.168.100.100 anywhere tcp dpt:1863
    ACCEPT tcp -- 192.168.100.101 anywhere tcp dpt:1863
    ACCEPT tcp -- 192.168.100.34 anywhere tcp dpt:1863
    DROP all -- 192.168.100.0/24 213.248.112.0/24
    DROP tcp -- 192.168.100.0/24 anywhere tcp dpts:1024:65535 state NEW
    DROP udp -- 192.168.100.0/24 anywhere udp dpts:1024:65535 state NEW
    DROP tcp -- 192.168.100.0/24 anywhere multiport dports 4661,4462,4242,4662,4672,4246,3310,4465,4468
    DROP udp -- 192.168.100.0/24 anywhere multiport dports 4661,4462,4242,4662,4672,4246,3310,4465,4468
    DROP all -- 192.168.100.0/24 66.135.33.0/24
    DROP tcp -- anywhere anywhere tcp dpt:5190 state NEW
    DROP udp -- anywhere anywhere udp dpt:5190 state NEW
    DROP tcp -- anywhere anywhere tcp dpts:ircd:6669 state NEW
    DROP all -- 192.168.100.0/24 216.35.208.0/24
    DROP tcp -- 192.168.100.0/24 anywhere tcp dpt:6346
    DROP udp -- 192.168.100.0/24 anywhere udp dpt:6346
    DROP all -- 192.168.100.0/24 209.61.186.0/24
    DROP all -- 192.168.100.0/24 64.49.201.0/24
    DROP all -- 192.168.100.0/24 host0.maxim.net/24
    DROP all -- 192.168.100.0/24 206.142.53.0/24
    DROP all -- 192.168.100.0/24 64.245.58.0/23
    ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
    ACCEPT all -- anywhere 192.168.100.0/24
    ACCEPT all -- 192.168.100.0/24 anywhere
    ACCEPT all -- anywhere 10.0.0.0/8
    ACCEPT all -- 10.0.0.0/8 anywhere
    DROP all -- anywhere anywhere unclean
    ACCEPT tcp -- 192.168.100.0/24 anywhere multiport ports ftp-data,ftp,ssh,smtp,www,imap2,pop3,3128,domain
    ACCEPT udp -- 192.168.100.0/24 anywhere multiport ports domain
    ACCEPT tcp -- anywhere anywhere tcp flags:SYN,RST,ACK/SYN limit: avg 1/sec burst 5
    ACCEPT tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,ACK/RST limit: avg 1/sec burst 5
    DROP icmp -- anywhere 192.168.100.0/24
    DROP all -- anywhere anywhere state INVALID
    DROP all -- anywhere anywhere

    Chain OUTPUT (policy ACCEPT)
    target prot opt source destination
    DROP all -- anywhere 207-36-232-140.ptr.primarydns.com
    DROP all -- 192.168.100.0/24 213.248.112.0/24
    DROP tcp -- 192.168.100.0/24 anywhere tcp dpts:1024:65535 state NEW
    DROP udp -- 192.168.100.0/24 anywhere udp dpts:1024:65535 state NEW
    DROP tcp -- 192.168.100.0/24 anywhere multiport dports 4661,4462,4242,4662,4672,4246,3310,4465,4468
    DROP udp -- 192.168.100.0/24 anywhere multiport dports 4661,4462,4242,4662,4672,4246,3310,4465,4468
    DROP all -- 192.168.100.0/24 66.135.33.0/24
    DROP tcp -- anywhere anywhere tcp dpt:5190 state NEW
    DROP udp -- anywhere anywhere udp dpt:5190 state NEW
    DROP tcp -- anywhere anywhere tcp dpts:ircd:6669 state NEW
    DROP all -- 192.168.100.0/24 216.35.208.0/24
    DROP tcp -- 192.168.100.0/24 anywhere tcp dpt:6346
    DROP udp -- 192.168.100.0/24 anywhere udp dpt:6346
    DROP all -- 192.168.100.0/24 209.61.186.0/24
    DROP all -- 192.168.100.0/24 64.49.201.0/24
    DROP all -- 192.168.100.0/24 host0.maxim.net/24
    DROP all -- 192.168.100.0/24 206.142.53.0/24
    DROP all -- 192.168.100.0/24 64.245.58.0/23
    ACCEPT tcp -- 192.168.100.0/24 anywhere tcp dpt:sunrpc
    ACCEPT tcp -- 192.168.100.0/24 anywhere tcp dpt:676
    ACCEPT tcp -- 192.168.100.0/24 anywhere tcp dpt:2049
    ACCEPT udp -- 192.168.100.0/24 anywhere udp dpt:sunrpc
    ACCEPT udp -- 192.168.100.0/24 anywhere udp dpt:673
    ACCEPT udp -- 192.168.100.0/24 anywhere udp dpt:2049

    Chain FORA (1 references)
    target prot opt source destination
    ACCEPT icmp -- anywhere anywhere icmp destination-unreachable limit: avg 5/sec burst 5
    ACCEPT icmp -- anywhere anywhere icmp source-quench limit: avg 5/sec burst 5
    ACCEPT icmp -- anywhere anywhere icmp time-exceeded limit: avg 5/sec burst 5
    ACCEPT icmp -- anywhere anywhere icmp parameter-problem limit: avg 5/sec burst 5
    DROP icmp -- anywhere anywhere icmp address-mask-request
    DROP icmp -- anywhere anywhere icmp address-mask-reply
    DROP icmp -- anywhere anywhere icmp timestamp-request
    DROP icmp -- anywhere anywhere icmp timestamp-reply
    DROP icmp -- anywhere anywhere icmp echo-request
    ACCEPT icmp -- anywhere anywhere icmp echo-reply limit: avg 2/sec burst 5
    DROP tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,PSH,ACK,URG/FIN,PSH,URG
    DROP tcp -- anywhere anywhere tcp flags:SYN,RST/SYN,RST
    DROP tcp -- anywhere anywhere tcp flags:FIN,SYN/FIN,SYN
    DROP tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,PSH,ACK,URG/FIN
    DROP tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,PSH,ACK,URG/FIN,SYN,RST,PSH,ACK,URG
    DROP tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,PSH,ACK,URG/NONE
    LOG tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,PSH,ACK,URG/NONE limit: avg 5/min burst 5 LOG level info tcp-options ip-options prefix `NULL SCAN:'
    DROP tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,PSH,ACK,URG/NONE
    LOG udp -- anywhere anywhere udp dpt:31337 state NEW LOG level warning prefix `FORA: PORTA UDP BLOQUEADA! '
    DROP udp -- anywhere anywhere udp dpt:31337
    LOG udp -- anywhere anywhere udp dpt:27444 state NEW LOG level warning prefix `FORA: PORTA UDP BLOQUEADA! '
    DROP udp -- anywhere anywhere udp dpt:27444
    LOG udp -- anywhere anywhere udp dpt:31335 state NEW LOG level warning prefix `FORA: PORTA UDP BLOQUEADA! '
    DROP udp -- anywhere anywhere udp dpt:31335
    LOG udp -- anywhere anywhere udp dpt:10498 state NEW LOG level warning prefix `FORA: PORTA UDP BLOQUEADA! '
    DROP udp -- anywhere anywhere udp dpt:10498
    LOG udp -- anywhere anywhere udp dpt:32775 state NEW LOG level warning prefix `FORA: PORTA UDP BLOQUEADA! '
    DROP udp -- anywhere anywhere udp dpt:32775
    LOG udp -- anywhere anywhere udp dpt:32770 state NEW LOG level warning prefix `FORA: PORTA UDP BLOQUEADA! '
    DROP udp -- anywhere anywhere udp dpt:32770
    DROP udp -- anywhere anywhere udp dpts:33434:33523
    DROP all -- anywhere anywhere state INVALID
    DROP all -f anywhere anywhere
    DROP tcp -- anywhere anywhere tcp option=64
    DROP tcp -- anywhere anywhere tcp option=128
    ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
    ACCEPT tcp -- anywhere anywhere tcp dpts:1024:65535 state RELATED
    ACCEPT udp -- anywhere anywhere udp dpts:1024:65535 state RELATED
    LOG tcp -- anywhere anywhere tcp dpt:ftp state NEW LOG level info prefix `FORA: ftp '
    ACCEPT tcp -- anywhere anywhere tcp dpt:ftp
    LOG tcp -- anywhere anywhere tcp dptostgres state NEW LOG level warning prefix `FORA: PGSQL'
    LOG tcp -- anywhere anywhere tcp dpt:ssh state NEW LOG level info prefix `FORA: ssh '
    ACCEPT tcp -- anywhere anywhere tcp dpt:ssh
    LOG tcp -- anywhere anywhere tcp dpt:smtp state NEW LOG level warning prefix `FORA: smtp '
    ACCEPT tcp -- anywhere anywhere tcp dpt:smtp
    ACCEPT tcp -- anywhere anywhere tcp dpt:domain
    ACCEPT udp -- anywhere anywhere udp dpt:domain
    LOG tcp -- anywhere anywhere tcp dpt:www state NEW LOG level warning prefix `FORA: www '
    ACCEPT tcp -- anywhere anywhere tcp dpt:www
    LOG tcp -- anywhere anywhere tcp dptop3 state NEW LOG level warning prefix `FORA: pop3 '
    ACCEPT tcp -- anywhere anywhere tcp dptop3
    LOG tcp -- anywhere anywhere tcp dpt:auth state NEW LOG level warning prefix `FORA: auth '
    LOG tcp -- anywhere anywhere tcp dpt:10000 state NEW LOG level warning prefix `FORA: webmin '
    LOG tcp -- anywhere anywhere tcp dpt:mysql state NEW LOG level warning prefix `FORA: mysql '
    LOG tcp -- anywhere anywhere tcp dpt:999 state NEW LOG level warning prefix `FORA: SGFW <-> Conexao! '
    LOG tcp -- anywhere anywhere tcp dpt:5222 state NEW LOG level warning prefix `FORA: EXODUS <-> Conexao! '





    esta ai amigo as regras..

  5. #5
    perdiga
    Visitante

    Padrão problemas dns, firewall

    galera por favor alguem pode me dar uma força...

    não estou conseguindo dar um telnet na porta 25 e 110 alguem pode me ajudar..

    olha so alguem sabe como criar uma regra de roteamento interno....


    por ex:

    eu tenho 3 servidores um de firewall,dns,proxy outro de email e outro de web, o problema é o seguinte de fora para dentro esta funcionando tudo corretamente, mas da rede interna não esta funcionando, a rede interna para acessar a pagina receber e-mais tem que ser tudo atraves do ip das máquinas, algum sabe o porque, e acho que não é dns não deve ser no firewall ...




    alguma ajuda ai galera sera bem vinda ..

    vlw..

  6. #6
    sambaloco40
    Visitante

    Padrão que coisa

    percebi um problema semelhante na minha rede, mas sempre que desativo o firewall tudo funfa bem.,.. faz tempo que eu procuro meu erro e ainda não encontrei,,, vai ver é algo semelhante...
    ainda, isso não tem nada com dns pq vc está colocando os ip''s direto e não os nomes.... T+

    procure algum problema com o firewall

  7. #7
    sarna
    Visitante

    Padrão problemas dns, firewall

    Você ja tentou dar um flush no output pra ver se vai ?

    Código :
    iptables -F OUTPUT

    Daí se nao der vc tenta dar também no INPUT, deve ter regras conflitando, é meio ruim de ver as regras assim...

    Ah coloca politica ACCEPT pra eles também enquanto estiver testando
    Código :
    iptables -P INPUT ACCEPT
    iptables -P OUTPUT ACCEPT

    Tenta fazer isso daí da pra saber onde q ta o problema se ta no INPUT ou no OUTPUT!


  8. #8
    perdiga
    Visitante

    Padrão problemas dns, firewall

    amigo fiz o que vc me disse, mas mesmo assim não adiantou

    ce tem alguma outra ideia talvez


    abraço..

  9. #9

    Padrão problemas dns, firewall

    cara...

    a princípio vc não tem problemas de DNS e sim de firewall

    suas rotas devem estar erradas

    vc deve analizar seu firewall e tentar encontrar o erro...

    qualquer coisa vc faz um firewall simples para testes, sem proteção sem nada, apenas com as rotas e boa...

    assim fica até mais fácil de vc encontrar o erro nas regras atuais...

    valew

  10. #10
    perdiga
    Visitante

    Padrão problemas dns, firewall

    amigos olha so, fiz um script liberando tudo, sem nenhuma politica de negação e nenhuma regra de negação, testei e nada o que me surprende é que nem um ping não funciona tanto dando para o ip externo quanto ao interno do firewall, tem algum outro lugar que pode estar bloqueado ping, mas a rede esta funcionando legal galera deveria teoricamente funcionar isso né...



    abraços.

  11. #11

    Padrão problemas dns, firewall

    amigo posta ai o resultado disso
    echo /proc/sys/net /ipv4/ip_forward e route
    abracos

    Citação Postado originalmente por perdiga
    amigos olha so, fiz um script liberando tudo, sem nenhuma politica de negação e nenhuma regra de negação, testei e nada o que me surprende é que nem um ping não funciona tanto dando para o ip externo quanto ao interno do firewall, tem algum outro lugar que pode estar bloqueado ping, mas a rede esta funcionando legal galera deveria teoricamente funcionar isso né...



    abraços.

  12. #12
    perdiga
    Visitante

    Padrão problemas dns, firewall

    esta ai amigo o resultado do comando route..


    Kernel IP routing table
    Destination Gateway Genmask Flags Metric Ref Use Iface
    BrT-L10-cslce70 * 255.255.255.255 UH 0 0 0 ppp0
    192.168.100.0 * 255.255.255.0 U 0 0 0 eth0
    10.0.0.0 * 255.0.0.0 U 0 0 0 eth1
    default BrT-L10-cslce70 0.0.0.0 UG 0 0 0 ppp0

    abraço