Accès publique aléatoire à un serveur linux sur routeur(s) via Freebox

Accès publique aléatoire à un serveur linux sur routeur(s) via Freebox - Windows & Software

Marsh Posté le 01-05-2006 à 20:57:01    

Bonjour à tous,
 
je poste aujourd'hui pour essayer de résoudre un problème qui dure depuis
plus de deux ans, je m'explique :
 
J'ai fait monté par un ami un serveur http/ftp/dns/imap/smtp tournant sous Linux
derrière un routeur Netgear FWG114P(v1) dans le but d'héberger trois site commerciaux
de faible à moyenne fréquentation (80 visites par jour environs et peu de gros fichiers)
via un abonnement Freebox(v3) dégroupé.
 
Le problème réside dans le fait que le routeur Netgear (modèle semi-pro) se bloque aléatoirement
(tout les mois environs) bloquant tout le trafic entrant. De plus, il doit avoir un problème de dns
dans le sens ou trop souvent les domaines hébergés sont inaccéssibles en local (mais sont
visibles de l'extérieur), l'intérogation des dns semble être assez longue lors du surf également.
 
J'ai fait un échange avec un deuxième routeur identique : mêmes problèmes.
 
Après deux ans de patience, j'ai décidé de racheter un nouveau routeur : le DI-524 de chez D-Link
(modèle familial), après configuration quelle était ma joie de voir que tout marchait à merveille
et de plus j'avais gagné grandement en rapidité. Mais, Mais : l'accès de l'extérieur tombe après une
heure environs sur tout les protocoles et ports. L'accès au Web en local reste fonctionnnel.
On résout le problème soit : en relaçant le routeur,
soit : en tapant l'adresse publique du routeur en local , alors TOUT le trafic redevient normal !!!
Je n'y comprend plus rien en fait...
 
Voici les éléments que j'ai dans les mains :
------------------
Configuration hardware/software:
Ancien routeur : NETGEAR FWG114P(v1) (firmware V2.0_18, dernier en date)
Nouveau routeur : D-LINK DI-524(révision 2) (firmware V2.02)
OS Serveur : Debian3.1
Kernel : 2.4.28-pre3
Processeur : Pentium III (Katmai) 550MHz
RAM : 512 + 128 + 128 Mo SDRAM
Serveur HTTP : Apache/2.0.54 (Unix) mod_ssl/2.0.54 OpenSSL/0.9.7e PHP/4.4.0 MySQL/4.0.21 PhpMyAdmin/2.6.0-rc2  
Serveur FTP : glftpd
Serveur DNS : Bind
Serveur MAIL : Courrier IMAP, Qmail, QmailAdmin/1.2.0, vpopmail/5.4.0, SquirrelMail/1.4.4

 

-----------------
Configuration du serveur DNS (Bind) :
** fichier 127.0.0
$TTL 86400
@       IN      SOA     serveur.#mondomaine#.com. webmestre.#mondomaine#.com. (
                        2006011801
                        3H
                        15M
                        1W
                        1D
)
                NS      serveur.#mondomaine#.com.
1               PTR     localhost.
** fichier 192.168.147
$TTL 86400
@       IN      SOA     serveur.#mondomaine#.com. webmestre.#mondomaine#.com. (
                        2006011801
                        3H
                        15M
                        1W
                        1D
)
                NS      serveur.#mondomaine#.com.
2               PTR     serveur.#mondomaine#.com.
** fichier #mondomaine#
$TTL 86400
@       IN      SOA     serveur.#mondomaine#.com. webmestre.#mondomaine#.com. (
        2006011801      ; Annee Mois Jour Revision
        7200            ; Raffraichissement 2 heures
        1200            ; Reessai 20 minutes
        1209600         ; Expiration 2 semaines
        86400           ; TTL duree de vie 12 heures
)
@       IN      NS      serveur.#mondomaine#.com.
                NS      ns6.gandi.net.
                MX      10 serveur.#mondomaine#.com.
                A       8x.xxx.xxx.xxx
serveur IN      A       8x.xxx.xxx.xxx
w       IN      A       8x.xxx.xxx.xxx
ww      IN      A       8x.xxx.xxx.xxx
www     IN      A       8x.xxx.xxx.xxx
wwww    IN      A       8x.xxx.xxx.xxx
ftp     IN      A       8x.xxx.xxx.xxx
pop     IN      A       8x.xxx.xxx.xxx
imap    IN      A       8x.xxx.xxx.xxx
smtp    IN      A       8x.xxx.xxx.xxx
forum   IN      A       8x.xxx.xxx.xxx
webmail IN      A       8x.xxx.xxx.xxx
admin   IN      A       8x.xxx.xxx.xxx
localhost       IN      A       127.0.0.1
** fichier named.conf
options {
        directory "/etc/bind";
        allow-query { 192.168.147.0/24; 127.0.0.1; 8x.xxx.xxx.xxx;};
        allow-recursion { 192.168.147.0/24; 127.0.0.1; 8x.xxx.xxx.xxx;};
        listen-on { 192.168.147.0/24; 127.0.0.1; 8x.xxx.xxx.xxx;};
};
logging {
        category lame-servers { null; };
        category cname { null; };
};
zone "." {
        type hint;
        file "root.hints";
};
zone "0.0.127.in-addr.arpa" {
        type master;
        file "127.0.0";
        allow-transfer { 217.70.177.40; };
        allow-query { any; };
};
zone "147.168.192.in-addr.arpa" {
        type master;
        file "192.168.147";
        allow-transfer { 217.70.177.40; };
        allow-query { any; };
};
zone "#mondomaine#" {
        type master;
        file "#mondomaine#";
        allow-transfer { 217.70.177.40; };
        allow-query { any; };
};
-------------------
Extraits des Logs du routeur D-Link :
Monday May 01, 2006 18:59:04 Unrecognized attempt blocked from 82.236.223.222:2989 to 82.236.60.239 TCP:445
Monday May 01, 2006 18:59:34 Unrecognized attempt blocked from 82.236.223.222:4406 to 82.236.60.239 TCP:139
Monday May 01, 2006 18:59:37 Unrecognized attempt blocked from 82.236.223.222:4406 to 82.236.60.239 TCP:139
Monday May 01, 2006 18:59:43 Unrecognized attempt blocked from 82.236.223.222:3872 to 82.236.60.239 TCP:445
Monday May 01, 2006 18:59:46 Unrecognized attempt blocked from 82.236.223.222:3872 to 82.236.60.239 TCP:445
Monday May 01, 2006 18:59:47 Unrecognized attempt blocked from 82.236.243.121:1467 to 82.236.60.239 TCP:445
Monday May 01, 2006 18:59:49 Unrecognized attempt blocked from 82.236.243.121:1467 to 82.236.60.239 TCP:445
Monday May 01, 2006 18:59:49 Unrecognized attempt blocked from 82.236.243.121:1467 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:00:25 Unrecognized attempt blocked from 82.236.55.251:2952 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:00:25 Unrecognized attempt blocked from 82.236.0.28:3502 to 82.236.60.239 TCP:139
...   ...
Monday May 01, 2006 19:44:58 Unrecognized attempt blocked from 82.236.169.152:1224 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:16:14 Unrecognized attempt blocked from 82.236.55.251:2784 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:16:21 Unrecognized attempt blocked from 82.236.190.250:4468 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:16:24 Unrecognized attempt blocked from 82.236.190.250:4468 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:16:40 Unrecognized attempt blocked from 82.236.26.54:1316 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:16:40 Unrecognized attempt blocked from 82.236.55.251:3678 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:16:43 Unrecognized attempt blocked from 82.236.55.251:3678 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:16:43 Unrecognized attempt blocked from 82.236.127.71:1232 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:16:46 Unrecognized attempt blocked from 82.236.127.71:1232 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:17:02 Unrecognized attempt blocked from 82.236.193.85:3321 to 82.236.60.239 TCP:139

 

Merci à l'avance pour votre aide précieuse.

 

Cordialement.

Reply

Marsh Posté le 01-05-2006 à 20:57:01   

Reply

Marsh Posté le 01-05-2006 à 21:10:19    

Citation :

Mais, Mais : l'accès de l'extérieur tombe après une
heure environs sur tout les protocoles et ports. L'accès au Web en local reste fonctionnnel.
On résout le problème soit : en relaçant le routeur,
soit : en tapant l'adresse publique du routeur en local , alors TOUT le trafic redevient normal !!!
Je n'y comprend plus rien en fait...


 
Pour résumer, au bout d'un certain temps, le port 80 est inaccessible depuis Internet.
Quand ce phénomène se produit, as tu accès à Internet depuis le serveur ? (ping google.fr ...)

Reply

Marsh Posté le 01-05-2006 à 21:17:53    

Merci pour cette réponse rapide,
 
le plus gros problème est que je n'arrive pas à déterminer la cause du phénomène, c'est complètement aléatoire.
 
A partir du réseau il n'y a pas de problème pour pinguer l'extérieur, je testerai directement à partir du serveur dès que le serveur retombe down.
 
PS: tous les ports et non le port 80 seul sont inaccessibles quand le phénomène se produit. Exemple : 143(imap)

Reply

Marsh Posté le 01-05-2006 à 21:21:09    

j'ai l'impression que le routeur doit endosser pas mal de connexions malveillantes sur le port 139 et 445 qui sont deux point faible de windows.
Mais ça ne devrais pas le faire planter :s

Reply

Marsh Posté le 01-05-2006 à 21:31:39    

Effectivement TaKoS, j'ai l'impression que j'essuis pas mal d'attaques, voici les 3 premières pages de logs (sur 31 !!!) :
 
Monday May 01, 2006 19:37:53 Unrecognized attempt blocked from 82.236.66.185:2523 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:37:56 Unrecognized attempt blocked from 82.236.66.185:2523 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:38:32 Unrecognized attempt blocked from 82.236.53.213:1665 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:38:35 Unrecognized attempt blocked from 82.236.53.213:1665 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:38:36 Unrecognized attempt blocked from 82.236.15.163:4973 to 82.236.60.239 TCP:1433
Monday May 01, 2006 19:38:39 Unrecognized attempt blocked from 82.236.15.163:4973 to 82.236.60.239 TCP:1433
Monday May 01, 2006 19:38:43 Unrecognized attempt blocked from 82.236.53.213:3368 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:38:44 Unrecognized attempt blocked from 82.236.88.19:4585 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:38:46 Unrecognized attempt blocked from 82.236.53.213:3368 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:38:46 Unrecognized attempt blocked from 82.236.88.19:4585 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:38:46 Unrecognized attempt blocked from 82.236.88.19:4585 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:38:49 Unrecognized attempt blocked from 82.236.193.85:3130 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:38:50 Unrecognized attempt blocked from 82.236.91.140:3449 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:38:52 Unrecognized attempt blocked from 82.236.193.85:3130 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:38:53 Unrecognized attempt blocked from 82.236.91.140:3449 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:39:29 Unrecognized attempt blocked from 82.236.33.7:3631 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:39:32 Unrecognized attempt blocked from 82.236.33.7:3631 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:39:33 Unrecognized attempt blocked from 82.232.36.77:3330 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:39:37 Unrecognized attempt blocked from 82.245.39.171:1234 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:39:40 Unrecognized attempt blocked from 82.245.39.171:1234 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:39:52 Unrecognized attempt blocked from 82.236.181.179:2427 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:39:55 Unrecognized attempt blocked from 82.236.181.179:2427 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:40:24 Unrecognized attempt blocked from 82.236.131.59:3209 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:40:27 Unrecognized attempt blocked from 82.236.131.59:3209 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:40:29 Unrecognized attempt blocked from 82.236.217.116:2109 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:40:32 Unrecognized attempt blocked from 82.236.217.116:2109 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:40:46 Unrecognized attempt blocked from 82.236.218.117:4257 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:41:28 Unrecognized attempt blocked from 82.231.103.215:2843 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:41:37 Unrecognized attempt blocked from 82.236.182.75:1353 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:41:38 Unrecognized attempt blocked from 82.236.89.233:4265 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:42:04 Unrecognized attempt blocked from 82.236.225.17:2048 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:42:07 Unrecognized attempt blocked from 82.227.177.191:1135 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:42:10 Unrecognized attempt blocked from 82.227.177.191:1135 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:42:46 Unrecognized attempt blocked from 82.236.57.32:3316 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:42:55 Unrecognized attempt blocked from 82.236.131.59:4736 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:42:58 Unrecognized attempt blocked from 82.236.114.180:2600 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:42:58 Unrecognized attempt blocked from 82.236.131.59:4736 to 82.236.60.239 TCP:445
Monday May 01, 2006 19:43:01 Unrecognized attempt blocked from 82.236.114.180:2600 to 82.236.60.239 TCP:139
Monday May 01, 2006 19:43:06 Unrecognized attempt blocked from 222.50.85.166:1750 to 82.236.60.239 TCP:135
Monday May 01, 2006 19:43:07 Unrecognized attempt blocked from 82.236.61.120:2590 to 82.236.60.239 TCP:135
Monday May 01, 2006 20:30:25 Unrecognized attempt blocked from 82.236.88.19:2044 to 82.236.60.239 TCP:445
Monday May 01, 2006 20:04:55 Unrecognized attempt blocked from 82.236.107.133:1641 to 82.236.60.239 TCP:135
Monday May 01, 2006 20:05:20 Unrecognized attempt blocked from 82.236.55.251:2953 to 82.236.60.239 TCP:135
Monday May 01, 2006 20:05:29 Unrecognized attempt blocked from 82.236.20.2:1509 to 82.236.60.239 TCP:139
Monday May 01, 2006 20:05:32 Unrecognized attempt blocked from 82.236.20.2:1509 to 82.236.60.239 TCP:139
Monday May 01, 2006 20:05:39 Unrecognized attempt blocked from 82.236.7.89:2137 to 82.236.60.239 TCP:135
Monday May 01, 2006 20:05:46 Unrecognized attempt blocked from 82.236.218.146:1567 to 82.236.60.239 TCP:1433
Monday May 01, 2006 20:05:49 Unrecognized attempt blocked from 82.236.218.146:1567 to 82.236.60.239 TCP:1433
Monday May 01, 2006 20:06:18 Unrecognized attempt blocked from 82.236.70.210:2474 to 82.236.60.239 TCP:135
Monday May 01, 2006 20:06:27 Unrecognized attempt blocked from 82.236.181.120:4463 to 82.236.60.239 TCP:135

Reply

Marsh Posté le 01-05-2006 à 21:37:07    

Citation :


A partir du réseau il n'y a pas de problème pour pinguer l'extérieur, je testerai directement à partir du serveur dès que le serveur retombe down.


il faudra le tester rapidement, car je pense que tu satures ton routeur en connexions.
Régulièrement il faudra faire un  

netstat -na | grep tcp| wc -l


 
PS: je doute que ce soit les attaques SMB (5 par minutes) qui saturent le modem.

Reply

Marsh Posté le 01-05-2006 à 21:42:33    

Merci pour l'info jlighty,
 
actuellement (requette distante par ssh), l'instuction me renvoie 21.

Reply

Marsh Posté le 01-05-2006 à 21:52:04    

Autre chose, il semblerait que la Freebox V3 gère un faible nombre de connexions (à contrario de la V4), il faudra monitorer régulièrement les connexions établies.

netstat -na | grep ESTABLISHED| wc -l

Reply

Marsh Posté le 01-05-2006 à 21:54:15    

Pour l'instant je suis à 3, je vous tiendrais au courant des deux valeurs régulièrement.

Reply

Marsh Posté le 01-05-2006 à 22:08:42    

Juste pour info, phpSysInfo me renvoi les stats suivantes :
 
Réseau  
Périphérique Réception    Envoi        Err/Drop  
lo               99.74 Mo    99.74 Mo   0/0  
dummy0      0.00 Ko       0.00 Ko     0/0  
eth0          1.82 Go       1.38 Go     0/0
 
Je trouve que 1.82 Go en réception sur eth0 (supérieur à l'envoi) est énorme pour un serveur principalement http et mail (à moins que l'effervescence des spams n'en soit la cause)
 
Je ne veux pas non plus vous mettre sur une mauvaise voie :)

Reply

Marsh Posté le 01-05-2006 à 22:08:42   

Reply

Marsh Posté le 01-05-2006 à 23:56:16    

goodchip a écrit :

Effectivement TaKoS, j'ai l'impression que j'essuis pas mal d'attaques, voici les 3 premières pages de logs (sur 31 !!!) :

 

Monday May 01, 2006 19:37:53 Unrecognized attempt blocked from 82.236.66.185:2523 to 82.236.60.239 TCP:139
[...]
Monday May 01, 2006 20:06:27 Unrecognized attempt blocked from 82.236.181.120:4463 to 82.236.60.239 TCP:135


Ouais, c'est pareil sur mon dslam. A croire que les voisins ont pas d'antivirus :o J'ai un Linksys befsr41 (une vieu routeur acheté 5€ aux puces) il fonctionne tres bien la grande majorité du temps, mais des fois il me ralentis le surf c'est assez désagréable :s

Reply

Marsh Posté le 02-05-2006 à 07:58:05    

Nouvelles infos :
 
voici les logs du routeur avant son nouveau plantage de cette nuit (il a quand même tenu quelques heures bravo... :( )
 
Tuesday May 02, 2006 06:54:45 Unrecognized attempt blocked from 82.236.44.80:2996 to 82.236.60.239 TCP:445
Tuesday May 02, 2006 04:11:03 Unrecognized attempt blocked from 82.236.20.2:3215 to 82.236.60.239 TCP:139
Tuesday May 02, 2006 04:11:06 Unrecognized attempt blocked from 82.236.20.2:3215 to 82.236.60.239 TCP:139
Tuesday May 02, 2006 04:11:44 Unrecognized attempt blocked from 82.236.20.2:3171 to 82.236.60.239 TCP:445
Tuesday May 02, 2006 04:11:47 Unrecognized attempt blocked from 82.236.20.2:3171 to 82.236.60.239 TCP:445
Tuesday May 02, 2006 04:11:55 Unrecognized attempt blocked from 82.236.193.85:3035 to 82.236.60.239 TCP:139
Tuesday May 02, 2006 04:11:58 Unrecognized attempt blocked from 82.236.193.85:3035 to 82.236.60.239 TCP:139
Tuesday May 02, 2006 04:14:51 Unrecognized attempt blocked from 82.236.127.71:3634 to 82.236.60.239 TCP:139
Tuesday May 02, 2006 04:14:54 Unrecognized attempt blocked from 82.236.127.71:3634 to 82.236.60.239 TCP:139
Tuesday May 02, 2006 04:15:59 Unrecognized attempt blocked from 82.236.193.158:3916 to 82.236.60.239 TCP:135
 
Actives sessions :
Page 1/1  
Internal                    Prot.     External                NAT       Time-out  
192.168.147.2:36661  TCP      195.93.102.35:23   59375     29927
 
ça m'inquiète un poil ce qui est au dessus, le port 23 c'est bien Telnet non, or ce n'est pas moi,
j'utilise exclusivement ssh.
 
PS:  
Routeur en 192.168.147.1
Serveur en 192.168.147.2
Imprim.rézo en 192.168.147.3

Message cité 1 fois
Message édité par goodchip le 02-05-2006 à 08:11:50
Reply

Marsh Posté le 02-05-2006 à 08:31:46    

goodchip a écrit :

Nouvelles infos :
Actives sessions :
Page 1/1  
Internal                    Prot.     External                NAT       Time-out  
192.168.147.2:36661  TCP      195.93.102.35:23   59375     29927
 
ça m'inquiète un poil ce qui est au dessus, le port 23 c'est bien Telnet non, or ce n'est pas moi,
j'utilise exclusivement ssh.
 
PS:  
Routeur en 192.168.147.1
Serveur en 192.168.147.2
Imprim.rézo en 192.168.147.3


Attention cela veut dire que ton serveur est connecté à un autre équipement (abonné AOL) sur son port 23 (telnet ou un quelconque service écoutant sur le port 23)

Reply

Marsh Posté le 02-05-2006 à 11:18:00    

Voici les infos demandées :
 
Le serveur pigue bien l'extérieur même avec le routeur en carafe :
 
root@serveur:/# ping google.com
PING google.com (64.233.167.99): 56 data bytes
64 bytes from 64.233.167.99: icmp_seq=0 ttl=241 time=106.3 ms
64 bytes from 64.233.167.99: icmp_seq=1 ttl=241 time=105.8 ms
64 bytes from 64.233.167.99: icmp_seq=2 ttl=241 time=106.0 ms
64 bytes from 64.233.167.99: icmp_seq=3 ttl=241 time=106.1 ms
64 bytes from 64.233.167.99: icmp_seq=4 ttl=241 time=105.8 ms
64 bytes from 64.233.167.99: icmp_seq=5 ttl=241 time=106.0 ms
64 bytes from 64.233.167.99: icmp_seq=6 ttl=241 time=105.9 ms
64 bytes from 64.233.167.99: icmp_seq=7 ttl=241 time=105.9 ms
64 bytes from 64.233.167.99: icmp_seq=8 ttl=241 time=106.3 ms
64 bytes from 64.233.167.99: icmp_seq=9 ttl=241 time=106.1 ms
64 bytes from 64.233.167.99: icmp_seq=10 ttl=241 time=106.4 ms
64 bytes from 64.233.167.99: icmp_seq=11 ttl=241 time=106.3 ms
64 bytes from 64.233.167.99: icmp_seq=12 ttl=241 time=105.7 ms
 
--- google.com ping statistics ---
13 packets transmitted, 13 packets received, 0% packet loss
round-trip min/avg/max = 105.7/106.0/106.4 ms
 
root@serveur:/# ping free.fr    
PING free.fr (212.27.48.10): 56 data bytes
64 bytes from 212.27.48.10: icmp_seq=0 ttl=120 time=9.4 ms
64 bytes from 212.27.48.10: icmp_seq=1 ttl=120 time=8.5 ms
64 bytes from 212.27.48.10: icmp_seq=2 ttl=120 time=8.7 ms
64 bytes from 212.27.48.10: icmp_seq=3 ttl=120 time=8.9 ms
64 bytes from 212.27.48.10: icmp_seq=4 ttl=120 time=9.0 ms
64 bytes from 212.27.48.10: icmp_seq=5 ttl=120 time=8.7 ms
64 bytes from 212.27.48.10: icmp_seq=6 ttl=120 time=8.3 ms
 
--- free.fr ping statistics ---
7 packets transmitted, 7 packets received, 0% packet loss
round-trip min/avg/max = 8.3/8.7/9.4 ms
 
root@serveur:/# ping #mondomaine#.com
PING #mondomaine#.com (8x.xxx.xxx.xxx): 56 data bytes
64 bytes from 8x.xxx.xxx.xxx: icmp_seq=0 ttl=64 time=0.4 ms
64 bytes from 8x.xxx.xxx.xxx: icmp_seq=1 ttl=64 time=0.4 ms
64 bytes from 8x.xxx.xxx.xxx: icmp_seq=2 ttl=64 time=0.4 ms
64 bytes from 8x.xxx.xxx.xxx: icmp_seq=3 ttl=64 time=0.4 ms
64 bytes from 8x.xxx.xxx.xxx: icmp_seq=4 ttl=64 time=0.4 ms
 
--- #mondomaine#.com ping statistics ---
5 packets transmitted, 5 packets received, 0% packet loss
round-trip min/avg/max = 0.4/0.4/0.4 ms
 
root@serveur:/# ping 192.168.147.1  
PING 192.168.147.1 (192.168.147.1): 56 data bytes
64 bytes from 192.168.147.1: icmp_seq=0 ttl=64 time=0.7 ms
64 bytes from 192.168.147.1: icmp_seq=1 ttl=64 time=0.4 ms
64 bytes from 192.168.147.1: icmp_seq=2 ttl=64 time=0.4 ms
64 bytes from 192.168.147.1: icmp_seq=3 ttl=64 time=0.4 ms
64 bytes from 192.168.147.1: icmp_seq=4 ttl=64 time=0.4 ms
 
--- 192.168.147.1 ping statistics ---
5 packets transmitted, 5 packets received, 0% packet loss
round-trip min/avg/max = 0.4/0.4/0.7 ms
 
Pour l'écoute du telnet, j'ai fait une règle de filtrage en sortie sur le firewall. Question : faut-il filtrer le port 36661(interne) ou 23(wan) ?
 
Autre réponse (23 page vues aujourd'hui sur le site principal, charge ridicule donc) :
root@serveur:~# netstat -na | grep ESTABLISHED| wc -l  
4
root@serveur:~# netstat -na | grep tcp| wc -l
21

Reply

Marsh Posté le 02-05-2006 à 12:38:39    

déjà trouve l'application qui a créé cette connexion :

lsof -i |grep "23 "


Citation :


Le serveur pigue bien l'extérieur même avec le routeur en carafe :


il faudra verifier qu'un firewall ne s'est pas activé ( iptables -L -n -v )


Message édité par jlighty le 02-05-2006 à 16:40:09
Reply

Marsh Posté le 02-05-2006 à 13:38:13    


 Merci. Je vérifie dès que j'ai accès au serveur.
 
 Sinon, voici sur les logs la situation où le routeur à planté ce midi :
Friday April 28, 2006 12:57:09 Unallowed access from 82.242.115.105: to 192.168.147.2: protocol=6 rule=-1 (by firewall)
Friday April 28, 2006 12:00:04 Unrecognized attempt blocked from 82.236.117.38:2526 to 82.236.60.239 TCP:445
Friday April 28, 2006 12:00:07 Unrecognized attempt blocked from 82.236.117.38:2526 to 82.236.60.239 TCP:445
Friday April 28, 2006 12:00:44 Unrecognized attempt blocked from 82.236.193.85:3753 to 82.236.60.239 TCP:139
Friday April 28, 2006 12:00:47 Unrecognized attempt blocked from 82.236.193.85:3753 to 82.236.60.239 TCP:139
Friday April 28, 2006 12:01:24 Unrecognized attempt blocked from 82.236.9.159:1193 to 82.236.60.239 TCP:139
Friday April 28, 2006 12:01:27 Unrecognized attempt blocked from 82.236.9.159:1193 to 82.236.60.239 TCP:139
Friday April 28, 2006 12:02:51 Unrecognized attempt blocked from 82.236.121.178:1188 to 82.236.60.239 TCP:445
Friday April 28, 2006 12:02:53 Unrecognized attempt blocked from 82.236.121.178:1188 to 82.236.60.239 TCP:445
Friday April 28, 2006 12:03:06 Unrecognized attempt blocked from 82.236.183.182:2150 to 82.236.60.239 TCP:139
 
j'ai en attendant créé une règle de blocage du serveur (192.168.147.2) vers le net sur le port 36661. (je pense que c'est ce qui à provoqué la ligne en gras, ce qui m'étonne par contre c'est le plantage à ce moment là)


Message édité par goodchip le 02-05-2006 à 13:39:40
Reply

Marsh Posté le 02-05-2006 à 14:34:52    


Petit problème dans les commandes jlighty :
 
root@serveur:~# lsof -i |grep "23 "
-bash: lsof: command not found
 
root@serveur:~# iptables -L -n -b
iptables v1.2.11: Unknown arg `-b'
Try `iptables -h' or 'iptables --help' for more information.

Reply

Marsh Posté le 02-05-2006 à 16:39:56    

Citation :


root@serveur:~# lsof -i |grep "23 "
-bash: lsof: command not found


il faut installer lsof, sinon tu peux aussi faire  

netstat -lapute | grep " 23 "


Citation :


root@serveur:~# iptables -L -n -b
iptables v1.2.11: Unknown arg `-b'
Try `iptables -h' or 'iptables --help' for more information.


j'ai écris trop vite :ange:  c'est -v à la place de -b  

Reply

Marsh Posté le 02-05-2006 à 17:11:54    

root@serveur:/# lsof -i |grep "23 "
lsof: no pwd entry for UID 92
lsof: no pwd entry for UID 92
named      9823     bind   20u  IPv4 32030503       UDP localhost:domain  
named      9823     bind   21u  IPv4 32030504       TCP localhost:domain (LISTEN)
named      9823     bind   22u  IPv4 32030505       UDP serveur.#mondomaine#.com:domain  
named      9823     bind   23u  IPv4 32030506       TCP serveur.#mondomaine#.com:domain (LISTEN)
named      9823     bind   24u  IPv4 32030507       UDP *:35590  
named      9823     bind   25u  IPv4 32030508       TCP localhost:953 (LISTEN)
 
-----------------
 
root@serveur:/# iptables -L -n -v
modprobe: Can't locate module ip_tables
iptables v1.2.11: can't initialize iptables table `filter': iptables who? (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.


 
un remove / install agt-get iptables ne donne rien de bon non plus


Message édité par goodchip le 02-05-2006 à 17:13:40
Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed