cześć , troche tego będzie więc jak nie masz ochoty to nie czytaj
mam problem z otworzeniem portów na zewnątrz dla niektórych usług.
, jest tak :
skanowanie od wewnątrz
[root@RCNdeamon maya]# nmap 192.168.0.1
Starting nmap 3.75 (
http://www.insecure.org/nmap/ ) at 2006-01-25 00:32 CET
Interesting ports on Router (192.168.0.1):
(The 1656 ports scanned but not shown below are in state: closed)
PORT STATE SERVICE
21/tcp open ftp
22/tcp open ssh
25/tcp open smtp
80/tcp open http
81/tcp open hosts2-ns
110/tcp open pop3
666/tcp open doom
Nmap run completed -- 1 IP address (1 host up) scanned in 3.490 seconds
czyli jest wszystko .....666 to mój panel administracyjny https communigate , a 81 to panel logowania usera communigate
skanowanie z zewnątrz :
milkdrinker@student:~$ nmap 83.18.76.107
Starting nmap 3.75 (
http://www.insecure.org/nmap/ ) at 2006-01-25 01:35 CET
Interesting ports on awy107.internetdsl.tpnet.pl (83.18.76.107):
(The 1656 ports scanned but not shown below are in state: filtered)
PORT STATE SERVICE
20/tcp closed ftp-data
21/tcp open ftp
22/tcp open ssh
80/tcp open http
113/tcp closed auth
480/tcp open loadsrv
1080/tcp closed socks
Nmap run completed -- 1 IP address (1 host up) scanned in 72.970 seconds
czyli jest tylko ftp, i www ... 480 to przekierowanie do komputera wewnątrz sieci,
nie wiem co to jest 113 i 1080, ale to nie ważne ..
chciałbym aby te usługi które działają na lokalu działały również z internetu
zrobiłem 'odblokowanie portów' w firewall'u czerwa i wygąda to teraz tak :
_____________
[root@RCNdeamon maya]# iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- anywhere anywhere
DROP tcp -- anywhere anywhere multiport dports 135,445
ACCEPT all -- Maya anywhere
ACCEPT tcp -- anywhere anywhere multiport dports www
ACCEPT udp -- anywhere anywhere multiport dports www
ACCEPT tcp -- anywhere anywhere tcp dpt:ftp-data
ACCEPT tcp -- anywhere anywhere tcp dpt:ftp
ACCEPT tcp -- anywhere anywhere tcp dpt:ssh
REJECT tcp -- anywhere anywhere tcp dpt:auth reject-with icmp-port-unreachable
REJECT tcp -- anywhere anywhere tcp dpt:1080 reject-with icmp-port-unreachable
ACCEPT icmp -- anywhere anywhere icmp echo-request limit: avg 1/sec burst 5
ACCEPT all -- AP anywhere
ACCEPT all -- Adam anywhere
ACCEPT all -- AP_sr anywhere
ACCEPT all -- Gruby anywhere
ACCEPT all -- Lysy anywhere
ACCEPT all -- Rafal anywhere
ACCEPT all -- Maya anywhere
ACCEPT all -- Jacek anywhere
ACCEPT all -- Cien anywhere
ACCEPT all -- Cinek anywhere
ACCEPT all -- Jurek anywhere
ACCEPT all -- Ania anywhere
ACCEPT all -- Sztywa anywhere
ACCEPT all -- Sztywa_biuro anywhere
ACCEPT all -- Sztywa_ap anywhere
ACCEPT all -- Maya_wlan anywhere
ACCEPT all -- AP_dn anywhere
ACCEPT all -- FTP_dn anywhere
ACCEPT all -- Daniel anywhere
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
Chain FORWARD (policy DROP)
target prot opt source destination
mrtg_traffic all -- anywhere anywhere
ACCEPT all -- anywhere anywhere
DROP tcp -- anywhere anywhere multiport dports 135,445
DROP tcp -- Jurek anywhere tcp flags:SYN,RST,ACK/SYN #conn/32 > 30
DROP tcp -- Cinek anywhere tcp flags:SYN,RST,ACK/SYN #conn/32 > 30
ACCEPT tcp -- anywhere AP_sr tcp dpt:www
ACCEPT tcp -- AP_sr anywhere tcp spt:www
ACCEPT udp -- anywhere AP_sr udp dpt:www
ACCEPT udp -- AP_sr anywhere udp spt:www
ACCEPT tcp -- anywhere Daniel tcp dpt:2980
ACCEPT tcp -- Daniel anywhere tcp spt:2980
ACCEPT udp -- anywhere Daniel udp dpt:2980
ACCEPT udp -- Daniel anywhere udp spt:2980
ACCEPT tcp -- anywhere Daniel tcp dpt:2921
ACCEPT tcp -- Daniel anywhere tcp spt:2921
ACCEPT udp -- anywhere Daniel udp dpt:2921
ACCEPT udp -- Daniel anywhere udp spt:2921
ACCEPT tcp -- anywhere Sztywa_ap tcp dpt:www
ACCEPT tcp -- Sztywa_ap anywhere tcp spt:www
ACCEPT udp -- anywhere Sztywa_ap udp dpt:www
ACCEPT udp -- Sztywa_ap anywhere udp spt:www
ACCEPT tcp -- anywhere AP tcp dpt:www
ACCEPT tcp -- AP anywhere tcp spt:www
ACCEPT udp -- anywhere AP udp dpt:www
ACCEPT udp -- AP anywhere udp spt:www
ACCEPT all -- AP anywhere
ACCEPT all -- Adam anywhere
ACCEPT all -- AP_sr anywhere
ACCEPT all -- Gruby anywhere
ACCEPT all -- Lysy anywhere
ACCEPT all -- Rafal anywhere
ACCEPT all -- Maya anywhere
ACCEPT all -- Jacek anywhere
ACCEPT all -- Cien anywhere
ACCEPT all -- Cinek anywhere
ACCEPT all -- Jurek anywhere
ACCEPT all -- Ania anywhere
ACCEPT all -- Sztywa anywhere
ACCEPT all -- Sztywa_biuro anywhere
ACCEPT all -- Sztywa_ap anywhere
ACCEPT all -- Maya_wlan anywhere
ACCEPT all -- AP_dn anywhere
ACCEPT all -- FTP_dn anywhere
ACCEPT all -- Daniel anywhere
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain mrtg_traffic (1 references)
target prot opt source destination
RETURN all -- anywhere RCNdeamon
RETURN all -- RCNdeamon anywhere
RETURN all -- anywhere Router
RETURN all -- Router anywhere
RETURN all -- anywhere AP
RETURN all -- AP anywhere
RETURN all -- anywhere Adam
RETURN all -- Adam anywhere
RETURN all -- anywhere AP_sr
RETURN all -- AP_sr anywhere
RETURN all -- anywhere Gruby
RETURN all -- Gruby anywhere
RETURN all -- anywhere Lysy
RETURN all -- Lysy anywhere
RETURN all -- anywhere Rafal
RETURN all -- Rafal anywhere
RETURN all -- anywhere Maya
RETURN all -- Maya anywhere
RETURN all -- anywhere Jacek
RETURN all -- Jacek anywhere
RETURN all -- anywhere Cien
RETURN all -- Cien anywhere
RETURN all -- anywhere Cinek
RETURN all -- Cinek anywhere
RETURN all -- anywhere Jurek
RETURN all -- Jurek anywhere
RETURN all -- anywhere Ania
RETURN all -- Ania anywhere
RETURN all -- anywhere Sztywa
RETURN all -- Sztywa anywhere
RETURN all -- anywhere Sztywa_biuro
RETURN all -- Sztywa_biuro anywhere
RETURN all -- anywhere Sztywa_ap
RETURN all -- Sztywa_ap anywhere
RETURN all -- anywhere Maya_wlan
RETURN all -- Maya_wlan anywhere
RETURN all -- anywhere AP_dn
RETURN all -- AP_dn anywhere
RETURN all -- anywhere FTP_dn
RETURN all -- FTP_dn anywhere
RETURN all -- anywhere Daniel
RETURN all -- Daniel anywhere
[root@RCNdeamon maya]#
_________________
tak zaś wygląda /etc/rc.local :
SSH=1
WWW=0
HTTPS=0
FTP=1
MAIL=0
IMAP=0
IMAPS=0
zrobiłem test, i jak widać zablokowałem tutaj WWW i odblkowalełem w firewall'u czerwa i działa, .. to samo chciałem zrobić z portami 25 , 81, i 110, lecz nie udalo się, ja widac wcześniej nie działają z zewnątrz
czy może ktoś mnie naprowadzić co się dzieje?
dziękuje i pozdrawiam