LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Some networking questions (https://www.linuxquestions.org/questions/linux-networking-3/some-networking-questions-130037/)

jmcollin92 12-30-2003 07:24 AM

Some networking questions
 
Hello there,

When searching to resolv the pb listed in this thread http://www.linuxquestions.org/questi...hreadid=128167

and I have some basics (?) questions :
1. is it a problem that local IP address are something like : 192.168.0.x ? Is the 0 possible in a IP address ?

2. what is the MTU parameter showed with ifconfig -a ?

3. ppp0 has MTU=1492 and eth0 has MTU=1500. Must those values be the same ?

4. How to change the MTU value for an IP interface and how to make this change persistant ?

Thank's for all.

yuray 12-30-2003 08:21 AM

About http://www.linuxquestions.org/quest...threadid=128167
Do you make ping from broken windows machine to broken sites ?

>1. is it a problem that local IP address are something like : 192.168.0.x ?
No problem. Only check what address give you ADSL provider.(must not from 192.168.0.x)
>Is the 0 possible in a IP address ?
No. IP address of host can`not be 0.
>2. what is the MTU parameter showed with ifconfig -a ?
Maximum Transfer Unit . Maximum size of packet. (for ethernet 1500)
>3. ppp0 has MTU=1492 and eth0 has MTU=1500. Must those values be the same ?
No. You router must fragmented IP packet if he is more then 1492.
>4. How to change the MTU value for an IP interface and how to make this change persistant ?
Why you need for ?

jmcollin92 12-30-2003 08:39 AM

Quote:

Originally posted by yuray
About http://www.linuxquestions.org/quest...threadid=128167
Do you make ping from broken windows machine to broken sites ?

>1. is it a problem that local IP address are something like : 192.168.0.x ?
No problem. Only check what address give you ADSL provider.(must not from 192.168.0.x)
>Is the 0 possible in a IP address ?
No. IP address of host can`not be 0.
>2. what is the MTU parameter showed with ifconfig -a ?
Maximum Transfer Unit . Maximum size of packet. (for ethernet 1500)
>3. ppp0 has MTU=1492 and eth0 has MTU=1500. Must those values be the same ?
No. You router must fragmented IP packet if he is more then 1492.
>4. How to change the MTU value for an IP interface and how to make this change persistant ?
Why you need for ?

Thank's for your answers,

But you says in 1. that there is no problem to have an IP like 192.168.0.1 and in 2. that it's not possible to have 0 in IP address. This seem's contradictoir to me. My question is : is an IP address like 192.168.0.1 legal or do I have to replace the 0 with something else ?

4. It was in case that both MTU (ppp0 and eth0) must be the same.

Do you have an idea for the problem listed in the thread : http://www.linuxquestions.org/quest...threadid=128167

Thank's for all

Gates1026 12-30-2003 09:11 AM

an address like 192.168.0.1 is legal, you just dont want to start an IP address with a 0 or end it with a 0. You also cannot use 255 for the IP b/c it is reserved

slightcrazed 12-30-2003 01:11 PM

255 = broadcast, meaning that packets are sent to every host on the subnet.

Gates is right, 0 can be used as long as it is not the end of the host portion. Often times a subnet is referred to by including the 0 (ie, 192.168.0.0 would refer to the subnet, and 192.168.0.1 would be a host on that subnet, and 192.168.0.255 would be the broadcast address for the subnet).

slight

yuray 12-31-2003 12:10 AM

Quote:

But you says in 1. that there is no problem to have an IP like 192.168.0.1 and in 2. that it's not possible to have 0 in IP address. This seem's contradictoir to me. My question is : is an IP address like 192.168.0.1 legal or do I have to replace the 0 with something else ?
In post http://www.linuxquestions.org/quest...threadid=128167 you write about
you have mask 255.255.255.0. In this case you may use legally ip from 192.168.0.1 to 192.168.0.254.
O in thrid octet belong to network part of address and with mask 255.255.255.0 is absolutly legally too.

Quote:

4. It was in case that both MTU (ppp0 and eth0) must be the same.
This is not necessarily so. But if you want - just read man ifconfig.

Quote:

Do you have an idea for the problem listed in the thread : http://www.linuxquestions.org/quest...threadid=128167
Do you make ping test from windows machines to Inernet urls ?

jmcollin92 12-31-2003 11:53 AM

Quote:

Originally posted by yuray

Do you make ping test from windows machines to Inernet urls ?

Yes all seems to be all right

yuray 01-02-2004 04:08 AM

Ok.
Try to sniffing traffic on inbound interface and adsl connection
In one window
tcpdump -vvv -i eth0(your local_net) host ip(one of windows box)
and other window
tcpdump -vvv -i ppp0(your adsl)
and from windows box check access to yahoo url.

What you see ? Can you give small dump ? (and result of ifconfig)

jmcollin92 01-02-2004 07:05 AM

Quote:

Originally posted by yuray
Ok.
Try to sniffing traffic on inbound interface and adsl connection
In one window
tcpdump -vvv -i eth0(your local_net) host ip(one of windows box)
and other window
tcpdump -vvv -i ppp0(your adsl)
and from windows box check access to yahoo url.

What you see ? Can you give small dump ? (and result of ifconfig)

I don't have tcpdump installed. Where can I find it ?

jmcollin92 01-02-2004 07:26 AM

OK I got it.
Sorry we will have to wait on monday to have people working. I cannot access this from home.

jmcollin92 01-03-2004 06:28 PM

2 ideas while waiting for users ....
 
While waiting for monday I have two ideas :
1. can it be a masquerading problem ?

My Linux box has an constant IP and I've read some articles saying that with constant IP with hav to use SNAT and not MASQUERADING ?

But I'm not shure the solution apply to me, they were talking about redirection also ...

What do you think about that ?

2. the port 113 (auth) was blocked is the OUTPUT rules with messages in /var/log/messages. I've read there that in this case http request could not work.
You could notice that by default all OUTPUT connections are DROPPED in my iptables config.
So perhaps do I need to open this port in OUTPUT ?
Does people have generally all OUTPUT ACCEPT and not DROP ?

yuray 01-04-2004 08:32 AM

I don`t think so.
You problem is not with all url. If you was have masquerading problem then windows machines can not
work at all.
I don`t know what is port 133 do.
HTTP -80 HTTPS -443 and thats all what need for web.
By the way, you forget https (hope, this solve the problem :) )
-A OUTPUT -p tcp -m tcp -o ppp0 --dport https -j ACCEPT

jmcollin92 01-04-2004 09:59 AM

I've already add the https which was missing, and it does not correct my problem.
See you tomorrow with real users ...

Thank's in advance for your help.

yuray 01-05-2004 06:15 AM

Hello.
I read a little more about iptables :)
Try to check very simple and insecure configuration.
iptables -F
iptables -t nat -F
iptables -t mangle -F
iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
( or iptables -t nat -A POSTROUTING -o ppp0 -j SNAT --to-source your_static_ip )
iptables -A FORWARD -j LOG --log-level info

In /var/log/messages (I don`t know where you syslog stored info, chekc /etc/syslog.conf ) you
will see requests and replys.

jmcollin92 01-05-2004 08:40 AM

Quote:

Originally posted by yuray
Ok.
Try to sniffing traffic on inbound interface and adsl connection
In one window
tcpdump -vvv -i eth0(your local_net) host ip(one of windows box)
and other window
tcpdump -vvv -i ppp0(your adsl)
and from windows box check access to yahoo url.

What you see ? Can you give small dump ? (and result of ifconfig)

Here are the traces requested :

On eth0 with the command tcpdump -vvv -i eth0 (only ticeropo1 was working) :
Code:

15:23:46.986313 ticeropo1.ticero.com.1028 > ticerosrv1.ticero.com.domain: [udp sum ok]  39+ A? www.nordparis.banquepopulaire.fr. (50) (ttl 128, id 49462, len 78)
15:23:46.986561 ticerosrv1.ticero.com.domain > ticeropo1.ticero.com.1028:  39 q: A? www.nordparis.banquepopulaire.fr. 1/3/0 www.nordparis.banquepopulaire.fr.[|domain] (DF) (ttl 64, id 0, len 158)
15:23:46.987699 ticeropo1.ticero.com.3197 > 194.51.109.131.http: S [tcp sum ok] 1484651153:1484651153(0) win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 128, id 49463, len 48)
15:23:47.122241 194.51.109.131.http > ticeropo1.ticero.com.3197: S [tcp sum ok] 3663766469:3663766469(0) ack 1484651154 win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 117, id 13569, len 48)
15:23:47.122453 ticeropo1.ticero.com.3197 > 194.51.109.131.http: . [tcp sum ok] 1:1(0) ack 1 win 65535 (DF) (ttl 128, id 49465, len 40)
15:23:47.124300 ticeropo1.ticero.com.3197 > 194.51.109.131.http: P 1:367(366) ack 1 win 65535 (DF) (ttl 128, id 49466, len 406)
15:23:47.410177 194.51.109.131.http > ticeropo1.ticero.com.3197: . [tcp sum ok] 1:1(0) ack 367 win 65169 (DF) (ttl 117, id 13602, len 40)
15:24:46.627600 ticeropo1.ticero.com.netbios-dgm > 192.168.0.255.netbios-dgm:
>>> NBT UDP PACKET(138) Res=0x1102 ID=0x80BD IP=192 (0xc0).168 (0xa8).0 (0x0).3 (0x3) Port=138 (0x8a) Length=196 (0xc4) Res2=0x0
SourceName=TICEROPO1      NameType=0x00 (Workstation)
DestName=
WARNING: Short packet. Try increasing the snap length

 (ttl 128, id 49606, len 238)
15:27:54.431914 arp who-has ticerosrv1.ticero.com tell ticeropo1.ticero.com
15:27:54.431931 arp reply ticerosrv1.ticero.com is-at 0:8:a1:40:67:d9
15:28:56.006362 ticeropo1.ticero.com.1028 > ticerosrv1.ticero.com.domain: [udp sum ok]  40+ A? maj.securitoo.com. (35) (ttl 128, id 50089, len 63)
15:28:56.154067 ticerosrv1.ticero.com.domain > ticeropo1.ticero.com.1028:  40 q: A? maj.securitoo.com. 1/2/0 maj.securitoo.com. A maj.securitoo.com ns: securitoo.com.[|domain] (DF) (ttl 64, id 0, len 132)
15:29:01.150582 arp who-has ticeropo1.ticero.com tell ticerosrv1.ticero.com
15:29:01.150727 arp reply ticeropo1.ticero.com is-at 0:a0:cc:5b:7b:8a
15:29:55.534641 ticeropo1.ticero.com.1028 > ticerosrv1.ticero.com.domain: [udp sum ok]  41+ A? bwcluster.securitoo.com. (41) (ttl 128, id 50195, len 69)
15:29:55.599256 ticerosrv1.ticero.com.domain > ticeropo1.ticero.com.1028:  41 q: A? bwcluster.securitoo.com. 1/2/0 bwcluster.securitoo.com. A[|domain] (DF) (ttl 64, id 0, len 138)
15:29:55.600955 ticeropo1.ticero.com.9370 > bwcluster.securitoo.com.codaauth2: [udp sum ok] udp 45 (ttl 128, id 50196, len 73)
15:29:55.679035 bwcluster.securitoo.com.codaauth2 > ticeropo1.ticero.com.9370: [udp sum ok] udp 12 (ttl 117, id 2629, len 40)

1667 packets received by filter
778 packets dropped by kernel

on ppp0 (with the command tcpdump -vvv -i ppp0 port not ssh
because I get this trace connected by ssh) :
[CODE]
15:23:46.987738 217.128.230.16.3197 > 194.51.109.131.http: S [tcp sum ok] 1484651153:1484651153(0) win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 127, id 49463, len 48)
15:23:46.988172 217.128.230.16.32850 > 198.6.1.83.domain: 49373 [1au] PTR? 131.109.51.194.in-addr.arpa. ar: . (56) (DF) (ttl 64, id 0, len 84)
15:23:47.122217 194.51.109.131.http > 217.128.230.16.3197: S [tcp sum ok] 3663766469:3663766469(0) ack 1484651154 win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 118, id 13569, len 48)
15:23:47.122464 217.128.230.16.3197 > 194.51.109.131.http: . [tcp sum ok] 1:1(0) ack 1 win 65535 (DF) (ttl 127, id 49465, len 40)
15:23:47.124311 217.128.230.16.3197 > 194.51.109.131.http: P 1:367(366) ack 1 win 65535 (DF) (ttl 127, id 49466, len 406)
15:23:47.186227 198.6.1.83.domain > 217.128.230.16.32850: 49373-% q: PTR? 131.109.51.194.in-addr.arpa. 0/5/3 ns: 51.194.in-addr.arpa.[|domain] (DF) (ttl 235, id 11963, len 247)
15:23:47.186568 217.128.230.16.32850 > 192.134.0.49.domain: 30993 [1au] PTR? 131.109.51.194.in-addr.arpa. ar: . (56) (DF) (ttl 64, id 0, len 84)
15:23:47.410162 194.51.109.131.http > 217.128.230.16.3197: . [tcp sum ok] 1:1(0) ack 367 win 65169 (DF) (ttl 118, id 13602, len 40)
15:23:49.190707 217.128.230.16.32850 > 193.0.0.193.domain: 31478 [1au] PTR? 131.109.51.194.in-addr.arpa. ar: . (56) (DF) (ttl 64, id 0, len 84)
15:23:49.480592 217.128.230.16.43695 > 217.167.52.114.auth: S [tcp sum ok] 2113102382:2113102382(0) win 5808 <mss 1452,sackOK,timestamp 136782637 0,nop,wscale 0> (DF) (ttl 64, id 16432, len 60)
15:23:51.200703 217.128.230.16.32850 > 194.51.3.49.domain: 57011 [1au] PTR? 131.109.51.194.in-addr.arpa. ar: . (56) (DF) (ttl 64, id 0, len 84)
15:23:51.265468 194.51.3.49.domain > 217.128.230.16.32850: 57011*- q: PTR? 131.109.51.194.in-addr.arpa. 1/2/3 131.109.51.194.in-addr.arpa.[|domain] (ttl 58, id 1869, len 199)
15:23:51.265784 217.128.230.16.32850 > 194.52.1.10.domain: 41731 [1au][|domain] (DF) (ttl 64, id 0, len 92)
15:23:51.361448 194.52.1.10.domain > 217.128.230.16.32850: 41731 q:[|domain] (DF) (ttl 243, id 23322, len 169)
15:23:51.361669 217.128.230.16.32850 > 194.51.3.49.domain: 48061 [1au][|domain] (DF) (ttl 64, id 0, len 92)
15:23:51.425435 194.51.3.49.domain > 217.128.230.16.32850: 48061- q:[|domain] (ttl 58, id 2009, len 181)
15:23:51.425694 217.128.230.16.32850 > 194.51.3.65.domain: 37938 [1au][|domain] (DF) (ttl 64, id 0, len 92)
15:23:51.425785 217.128.230.16.32850 > 193.176.144.6.domain: [udp sum ok] 51737 [1au] A? ceprox01.cerius.fr. ar: . OPT UDPsize=2048 (47) (DF) (ttl 64, id 0, len 75)
15:23:51.489425 194.51.3.65.domain > 217.128.230.16.32850: 37938 NXDomain*- q:[|domain] (DF) (ttl 248, id 13937, len 155)
15:23:51.505436 193.176.144.6.domain > 217.128.230.16.32850: 51737-% q: A? ceprox01.cerius.fr. 1/2/3 ceprox01.cerius.fr. A 194.51.109.157[|domain] (ttl 49, id 23295, len 162)
15:23:55.480591 217.128.230.16.43695 > 217.167.52.114.auth: S [tcp sum ok] 2113102382:2113102382(0) win 5808 <mss 1452,sackOK,timestamp 136783237 0,nop,wscale 0> (DF) (ttl 64, id 16433, len 60)

424 packets received by filter
87 packets dropped by kernel
[/CODE

in /var/log/messages :
Code:

Jan  5 15:21:43 ticerosrv1 kernel: device ppp0 left promiscuous mode
Jan  5 15:21:49 ticerosrv1 kernel: device ppp0 entered promiscuous mode
Jan  5 15:21:54 ticerosrv1 kernel: device ppp0 left promiscuous mode
Jan  5 15:22:00 ticerosrv1 CROND[8637]: (root) CMD (  /usr/share/msec/promisc_check.sh)
Jan  5 15:22:36 ticerosrv1 kernel: device ppp0 entered promiscuous mode
Jan  5 15:23:00 ticerosrv1 CROND[8662]: (root) CMD (  /usr/share/msec/promisc_check.sh)
Jan  5 15:24:00 ticerosrv1 CROND[8668]: (root) CMD (  /usr/share/msec/promisc_check.sh)

First question :
the tcpdump command says xxx paquets dropped and normally I should see this paquet on /var/log/messages. I'm shure this is working in my firewall configuration :
Code:

[root@ticerosrv1 root]# iptables-save
# Generated by iptables-save v1.2.7a on Mon Jan  5 15:40:48 2004
*filter
:INPUT DROP [758:46414]
:FORWARD DROP [0:0]
:OUTPUT DROP [0:0]
-A INPUT -p tcp -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -p udp -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 21 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 22 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 25 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 80 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 443 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 10000 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 110 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 137 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 138 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 139 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p udp -m udp --dport 137 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p udp -m udp --dport 138 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p udp -m udp --dport 139 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p tcp -m tcp --dport 901 -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.255.0 -i eth0 -p icmp -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -s 192.168.0.0/255.255.0.0 -i ppp0 -j DROP
-A INPUT -i ppp0 -p tcp -m tcp --dport 21 -j ACCEPT
-A INPUT -i ppp0 -p tcp -m tcp --dport 22 -j ACCEPT
-A INPUT -i ppp0 -p tcp -m tcp --dport 25 -j ACCEPT
-A INPUT -i ppp0 -p tcp -m tcp --dport 80 -j ACCEPT
-A INPUT -i ppp0 -p tcp -m tcp --dport 443 -j ACCEPT
-A INPUT -i ppp0 -p tcp -m tcp --dport 10000 -j ACCEPT
-A INPUT -i ppp0 -p tcp -m tcp --dport 110 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 53 -j ACCEPT
-A INPUT -p udp -m udp --dport 53 -j ACCEPT
-A INPUT -i ppp0 -p icmp -m limit --limit 1/sec -j ACCEPT
-A INPUT -m limit --limit 1/sec --limit-burst 3 -j LOG --log-prefix "IPTABLES-INPUT : " --log-level 3
-A FORWARD -p tcp -m state --state RELATED,ESTABLISHED -j ACCEPT
-A FORWARD -p udp -m state --state RELATED,ESTABLISHED -j ACCEPT
-A FORWARD -s 192.168.0.0/255.255.255.0 -i eth0 -o ppp0 -j ACCEPT
-A FORWARD -p icmp -j ACCEPT
-A FORWARD -m limit --limit 1/sec --limit-burst 3 -j LOG --log-prefix "IPTABLES-FORWARD : " --log-level 3
-A OUTPUT -p tcp -m state --state RELATED,ESTABLISHED -j ACCEPT
-A OUTPUT -p udp -m state --state RELATED,ESTABLISHED -j ACCEPT
-A OUTPUT -s 192.168.0.0/255.255.255.0 -o ppp0 -p tcp -m tcp --dport 21 -j ACCEPT
-A OUTPUT -s 192.168.0.0/255.255.255.0 -o ppp0 -p tcp -m tcp --dport 22 -j ACCEPT
-A OUTPUT -s 192.168.0.0/255.255.255.0 -o ppp0 -p tcp -m tcp --dport 25 -j ACCEPT
-A OUTPUT -s 192.168.0.0/255.255.255.0 -o ppp0 -p tcp -m tcp --dport 80 -j ACCEPT
-A OUTPUT -s 192.168.0.0/255.255.255.0 -o ppp0 -p tcp -m tcp --dport 443 -j ACCEPT
-A OUTPUT -o lo -j ACCEPT
-A OUTPUT -s 192.168.0.0/255.255.255.0 -o eth0 -p tcp -m tcp -j ACCEPT
-A OUTPUT -p udp -m udp --dport 53 -j ACCEPT
-A OUTPUT -p tcp -m tcp --dport 53 -j ACCEPT
-A OUTPUT -p icmp -j ACCEPT
-A OUTPUT -o ppp0 -p tcp -m tcp --dport 80 -j ACCEPT
-A OUTPUT -o ppp0 -p tcp -m tcp --dport 25 -j ACCEPT
-A OUTPUT -o ppp0 -p tcp -m tcp --dport 110 -j ACCEPT
-A OUTPUT -o ppp0 -p tcp -m tcp --dport 443 -j ACCEPT
-A OUTPUT -o ppp0 -p tcp -m tcp --dport 113 -j ACCEPT
-A OUTPUT -o ppp0 -p udp -m udp --dport 113 -j ACCEPT
-A OUTPUT -d 192.168.0.0/255.255.255.0 -o eth0 -p tcp -m tcp --dport 137:138 -j ACCEPT
-A OUTPUT -d 192.168.0.0/255.255.255.0 -o eth0 -p udp -m udp --dport 137:138 -j ACCEPT
-A OUTPUT -p tcp -m tcp --sport 20 -j ACCEPT
-A OUTPUT -m limit --limit 1/sec --limit-burst 3 -j LOG --log-prefix "IPTABLES-OUTPUT : " --log-level 3
COMMIT
# Completed on Mon Jan  5 15:40:48 2004
# Generated by iptables-save v1.2.7a on Mon Jan  5 15:40:48 2004
*mangle
:PREROUTING ACCEPT [39470:9001082]
:INPUT ACCEPT [34369:6434525]
:FORWARD ACCEPT [5035:2539065]
:OUTPUT ACCEPT [35248:10535825]
:POSTROUTING ACCEPT [40309:13075410]
COMMIT
# Completed on Mon Jan  5 15:40:48 2004
# Generated by iptables-save v1.2.7a on Mon Jan  5 15:40:48 2004
*nat
:PREROUTING ACCEPT [1972:148644]
:POSTROUTING ACCEPT [928:58597]
:OUTPUT ACCEPT [2190:149102]
-A POSTROUTING -o ppp0 -j MASQUERADE
COMMIT
# Completed on Mon Jan  5 15:40:48 2004

Thank's for all

yuray 01-06-2004 12:18 AM

>First question :
>the tcpdump command says xxx paquets dropped and normally I should see this paquet on >/var/log/messages. I'm shure this is working in my firewall configuration :
Check syslog.conf. Are you sure what --log-level 3 will be send to /var/log/messages ? (3 what is it ? debug, info or ?)
If syslog.conf is ok
- make all rules -j LOG first rules in tables
- shorter their.
Example
-A OUTPUT -j LOG --log-prefix "IPTABLES-OUTPUT : " --log-level 3

I am not understand www.nordparis.banquepopulaire.fr is "bad url" ?
It is work now ? How about fr.google.com ?

jmcollin92 01-06-2004 02:47 AM

Quote:

Originally posted by yuray
>First question :
>the tcpdump command says xxx paquets dropped and normally I should see this paquet on >/var/log/messages. I'm shure this is working in my firewall configuration :
Check syslog.conf. Are you sure what --log-level 3 will be send to /var/log/messages ? (3 what is it ? debug, info or ?)

The begining my syslog.conf is the following :
Code:

# Various entry
auth,authpriv.*                                                /var/log/auth.log
*.*;auth,authpriv.none                                          -/var/log/syslog
user.*                                                          -/var/log/user.log

# Log anything (except mail) of level info or higher.
# Don't log private authentication messages!
*.info;mail.none;;news.none;authpriv.none                                      -/var/log/messages
...

Do you think it's ok ?

Quote:

If syslog.conf is ok
- make all rules -j LOG first rules in tables
- shorter their.
Example
-A OUTPUT -j LOG --log-prefix "IPTABLES-OUTPUT : " --log-level 3
Ok I will do that. My goal was to have only the dropped packet. So I have to put the LOG rule at the end, just before the DROP. Am I wrong ?

Quote:


I am not understand www.nordparis.banquepopulaire.fr is "bad url" ?
It is work now ? How about fr.google.com ?

Ok I should give more explanations (sorry for that). www.nordparis.banquepopulaire.fr is a bad URL too. This URL is more easier to test because, all the site is not answering and not only one button in the site as with fr.yahoo.com (google is working without problem).

Can you give me the good configuration (firewall and syslog.conf) to have a log for each dropped packet ?

Thank you.

jmcollin92 01-06-2004 03:58 AM

Quote:

Originally posted by yuray
Hello.
I read a little more about iptables :)
Try to check very simple and insecure configuration.
iptables -F
iptables -t nat -F
iptables -t mangle -F
iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
( or iptables -t nat -A POSTROUTING -o ppp0 -j SNAT --to-source your_static_ip )
iptables -A FORWARD -j LOG --log-level info

In /var/log/messages (I don`t know where you syslog stored info, chekc /etc/syslog.conf ) you
will see requests and replys.

I've try with your commands and there were no more traffic in and out of the Linux box.....
So I've try with these rules :
Code:

# Generated by iptables-save v1.2.7a on Wed Nov 26 23:20:02 2003
*nat
:OUTPUT ACCEPT [0:0]
:PREROUTING ACCEPT [0:0]
:POSTROUTING ACCEPT [0:0]
-A POSTROUTING -o ppp0 -j MASQUERADE
COMMIT
# Completed on Wed Nov 26 23:20:02 2003
# Generated by iptables-save v1.2.7a on Wed Nov 26 23:20:02 2003
*mangle
:PREROUTING ACCEPT [246:38812]
:INPUT ACCEPT [246:38812]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [245:38575]
:POSTROUTING ACCEPT [245:38575]
COMMIT
# Completed on Wed Nov 26 23:20:02 2003
# Generated by iptables-save v1.2.7a on Wed Nov 26 23:20:02 2003
*filter
:FORWARD ACCEPT [0:0]
:INPUT ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
COMMIT
# Completed on Wed Nov 26 23:20:02 2003

and the problem is still the same.
The tcpdump trace says :
Code:

38 packets dropped by kernel
!!
How is it possible to have packets dropped with the rules showns before ?
How to see what packets are dropped (nothing in /var/log/messages) ?
Is there any incorrect packets wich are not traced ?

Answering those questions is certainly the beginning of the solution.

yuray 01-06-2004 06:03 AM

Quote:

Originally posted by jmcollin92
[B]The begining my syslog.conf is the following :
Code:

# Various entry
auth,authpriv.*                                                /var/log/auth.log
*.*;auth,authpriv.none                                          -/var/log/syslog
user.*                                                          -/var/log/user.log

# Log anything (except mail) of level info or higher.
# Don't log private authentication messages!
*.info;mail.none;;news.none;authpriv.none                                      -/var/log/messages
...

Do you think it's ok ?
You write --log-level 3 ---->
In syslog.h 3 define as LOG_ERROR (error) ----> you logs send to /var/log/syslog
Replace 3 - info and you must get logs into /var/log/messages
Quote:

Ok I will do that. My goal was to have only the dropped packet. So I have to put the LOG rule at the end, just before the DROP. Am I wrong ?
Oopss. Sorry, my fault, you right!
Quote:

Ok I should give more explanations (sorry for that). www.nordparis.banquepopulaire.fr is a bad URL too. This URL is more easier to test because, all the site is not answering and not only one button in the site as with fr.yahoo.com (google is working without problem).
My dump with (localhost linux)
-1 14:39:01.869264 admin414.33706 > 194.51.109.131.http: S [tcp sum ok] 1312746232:1312746232(0) win 5840 <mss 1460,sackOK,timestamp 2199983 0,nop,wscale 0> (DF) (ttl 64, id 31575, len 60)
-2 14:39:01.966707 194.51.109.131.http > admin414.33706: S [tcp sum ok] 2324403888:2324403888(0) ack 1312746233 win 65535 <mss 1460,nop,wscale 0,nop,nop,timestamp 0 0,nop,nop,sackOK> (DF) (ttl 104, id 21187, len 64)
-3 14:39:01.966741 admin414.33706 > 194.51.109.131.http: . [tcp sum ok] 1:1(0) ack 1 win 5840 <nop,nop,timestamp 2199993 0> (DF) (ttl 64, id 31576, len 52)
-4 14:39:01.966863 admin414.33706 > 194.51.109.131.http: P [tcp sum ok] 1:504(503) ack 1 win 5840 <nop,nop,timestamp 2199993 0> (DF) (ttl 64, id 31577, len 555)
-5 14:39:02.081956 194.51.109.131.http > admin414.33706: . [tcp sum ok] 1:1449(1448) ack 504 win 65032 <nop,nop,timestamp 220827 2199993> (DF) (ttl 104, id 21188, len 1500)

If compare with your dump will see what len of my packet number 5 is 1448 and your only 40! I don`t understand why so small ?
15:23:47.410162 194.51.109.131.http > 217.128.230.16.3197: . [tcp sum ok] 1:1(0) ack 367 win 65169 (DF) (ttl 118, id 13602, len 40)

Quote:

Can you give me the good configuration (firewall and syslog.conf) to have a log for each dropped packet ?
Sorry, we have not linux firewall :)

yuray 01-06-2004 06:11 AM

Quote:

Originally posted by jmcollin92
[B]I've try with your commands and there were no more traffic in and out of the Linux box.....
So I've try with these rules :
Code:

# Generated by iptables-save v1.2.7a on Wed Nov 26 23:20:02 2003
*nat
:OUTPUT ACCEPT [0:0]
:PREROUTING ACCEPT [0:0]
:POSTROUTING ACCEPT [0:0]
-A POSTROUTING -o ppp0 -j MASQUERADE
COMMIT
# Completed on Wed Nov 26 23:20:02 2003
# Generated by iptables-save v1.2.7a on Wed Nov 26 23:20:02 2003
*mangle
:PREROUTING ACCEPT [246:38812]
:INPUT ACCEPT [246:38812]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [245:38575]
:POSTROUTING ACCEPT [245:38575]
COMMIT
# Completed on Wed Nov 26 23:20:02 2003
# Generated by iptables-save v1.2.7a on Wed Nov 26 23:20:02 2003
*filter
:FORWARD ACCEPT [0:0]
:INPUT ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
COMMIT
# Completed on Wed Nov 26 23:20:02 2003


I dont see what you want log :
Code:

[root@admin414 sys]# /sbin/iptables -t nat -L
Chain PREROUTING (policy ACCEPT)
target    prot opt source              destination

Chain POSTROUTING (policy ACCEPT)
target    prot opt source              destination

Chain OUTPUT (policy ACCEPT)
target    prot opt source              destination
LOG        all  --  anywhere            anywhere          LOG level warning
[root@admin414 sys]#

Post iptables result -- not iptables-save

jmcollin92 01-06-2004 06:40 AM

Quote:

Originally posted by yuray
I dont see what you want log :
[/CODE]
Post iptables result -- not iptables-save

I just want to show you that with all rules at ACCEPT, the problem still occurs. So it's not a firewall problem.

The traces shows that there were Dropped packets whereas the firewall was accepting all packets. It's the problem we have to focus on, (I think).

How is it possible ? What are those packets ?
Can it be a hardware pb in the NIC ?

Best regards and thank's for all ......

jmcollin92 01-06-2004 07:14 AM

Quote:

Originally posted by yuray
You write --log-level 3 ---->
In syslog.h 3 define as LOG_ERROR (error) ----> you logs send to /var/log/syslog
Replace 3 - info and you must get logs into /var/log/messages

It's not a pb because Error is > than Info and so messages are in both files.
Quote:


If compare with your dump will see what len of my packet number 5 is 1448 and your only 40! I don`t understand why so small ?
15:23:47.410162 194.51.109.131.http > 217.128.230.16.3197: . [tcp sum ok] 1:1(0) ack 367 win 65169 (DF) (ttl 118, id 13602, len 40)

It's a response packet no ?. Is it possible to see what is in the packet ? Perhaps there is an error or something like in this packet.

jmcollin92 01-06-2004 03:53 PM

Here is another dialog with this site :
(from eth0) :
Code:

10:38:02.062004 ticeropo1.ticero.com.1028 > ticerosrv1.ticero.com.domain: [udp sum ok]  102+ A? www.nordparis.banquepopulaire.fr. (50) (ttl 128, id 22023, len 78)
10:38:02.226571 ticerosrv1.ticero.com.domain > ticeropo1.ticero.com.1028:  102 q: A? www.nordparis.banquepopulaire.fr. 1/3/2 www.nordparis.banquepopulaire.fr.[|domain] (DF) (ttl 64, id 0, len 190)
10:38:02.230095 ticeropo1.ticero.com.3174 > 194.51.109.131.http: S [tcp sum ok] 300623794:300623794(0) win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 128, id 22024, len 48)
10:38:02.354337 194.51.109.131.http > ticeropo1.ticero.com.3174: S [tcp sum ok] 3797335509:3797335509(0) ack 300623795 win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 117, id 3596, len 48)

10:38:02.354548 ticeropo1.ticero.com.3174 > 194.51.109.131.http: . [tcp sum ok] 1:1(0) ack 1 win 65535 (DF) (ttl 128, id 22026, len 40)
10:38:02.357818 ticeropo1.ticero.com.3174 > 194.51.109.131.http: P 1:226(225) ack 1 win 65535 (DF) (ttl 128, id 22027, len 265)
10:38:05.353416 ticeropo1.ticero.com.3174 > 194.51.109.131.http: P 1:226(225) ack 1 win 65535 (DF) (ttl 128, id 22029, len 265)

10:38:05.521736 194.51.109.131.http > ticeropo1.ticero.com.3174: . [tcp sum ok] 2921:2921(0) ack 226 win 65310 (DF) (ttl 117, id 3698, len 40)

It's seems to be 3 packets for one call id=22026, 22027 and 22029.
1. Is it a framented packet ?
2. Is it possible that this site refuse fragmented packet ?
3. We have 22026, 22027 and 22029 where is 22028 ?
4. what means the 'P' after http: ?

The same dialog viewed from ppp0 :
Code:

10:38:02.062347 217.128.230.16.32871 > 193.176.144.6.domain:  57209 [1au] A? www.nordparis.banquepopulaire.fr. ar: . (61) (DF) (ttl 64, id 0, len 89)

10:38:02.146333 193.176.144.6.domain > 217.128.230.16.32871:  57209-% q: A? www.nordparis.banquepopulaire.fr. 0/3/2 ns: banquepopulaire.fr.[|domain] (ttl 49, id 11372, len 169)
10:38:02.146605 217.128.230.16.32871 > 194.2.0.2.domain:  53037 [1au] A? www.nordparis.banquepopulaire.fr. ar: . (61) (DF) (ttl 64, id 0, len 89)
10:38:02.226317 194.2.0.2.domain > 217.128.230.16.32871:  53037*-% q: A? www.nordparis.banquepopulaire.fr. 1/3/4 www.nordparis.banquepopulaire.fr.[|domain] (DF) (ttl 59, id 0, len 217)

10:38:02.230129 217.128.230.16.3174 > 194.51.109.131.http: S [tcp sum ok] 300623794:300623794(0) win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 127, id 22024, len 48)

10:38:02.230623 217.128.230.16.32871 > 192.93.0.4.domain:  61426 [1au] PTR? 131.109.51.194.in-addr.arpa. ar: . (56) (DF) (ttl 64, id 0, len 84)
10:38:02.306303 192.93.0.4.domain > 217.128.230.16.32871:  61426- q: PTR? 131.109.51.194.in-addr.arpa. 0/5/1 ns: 51.194.in-addr.arpa.[|domain] (ttl 20, id 32408, len 203)
10:38:02.306565 217.128.230.16.32871 > 194.52.1.10.domain:  30713 [1au] PTR? 131.109.51.194.in-addr.arpa. ar: . (56) (DF) (ttl 64, id 0, len 84)

10:38:02.354302 194.51.109.131.http > 217.128.230.16.3174: S [tcp sum ok] 3797335509:3797335509(0) ack 300623795 win 65535 <mss 1460,nop,nop,sackOK> (DF) (ttl 118, id 3596, len 48)
10:38:02.354559 217.128.230.16.3174 > 194.51.109.131.http: . [tcp sum ok] 1:1(0) ack 1 win 65535 (DF) (ttl 127, id 22026, len 40)
10:38:02.357828 217.128.230.16.3174 > 194.51.109.131.http: P 1:226(225) ack 1 win 65535 (DF) (ttl 127, id 22027, len 265)

10:38:02.402279 194.52.1.10.domain > 217.128.230.16.32871:  30713 q: PTR? 131.109.51.194.in-addr.arpa. 0/2/3 ns: 109.51.194.in-addr.arpa.[|domain] (DF) (ttl 243, id 16067, len 161)
10:38:02.402568 217.128.230.16.32871 > 194.51.3.65.domain:  2727 [1au] PTR? 131.109.51.194.in-addr.arpa. ar: . (56) (DF) (ttl 64, id 0, len 84)
10:38:02.466270 194.51.3.65.domain > 217.128.230.16.32871:  2727 NXDomain*- q: PTR? 131.109.51.194.in-addr.arpa. 1/1/1 131.109.51.194.in-addr.arpa.[|domain] (DF) (ttl 248, id 54521, len 173)
10:38:02.466558 217.128.230.16.32871 > 194.51.3.49.domain:  36495 [1au][|domain] (DF) (ttl 64, id 0, len 92)
10:38:02.530261 194.51.3.49.domain > 217.128.230.16.32871:  36495- q:[|domain] (ttl 58, id 10281, len 181)
10:38:02.530642 217.128.230.16.32871 > 194.51.3.65.domain:  58871 [1au][|domain] (DF) (ttl 64, id 0, len 92)
10:38:02.530729 217.128.230.16.32871 > 192.93.0.1.domain: [udp sum ok]  64016 [1au] A? ceprox01.cerius.fr. ar: . OPT UDPsize=2048 (47) (DF) (ttl 64, id 0, len 75)
10:38:02.594253 194.51.3.65.domain > 217.128.230.16.32871:  58871 NXDomain*- q:[|domain] (DF) (ttl 248, id 54522, len 155)
10:38:02.594281 192.93.0.1.domain > 217.128.230.16.32871:  64016-% q: A? ceprox01.cerius.fr. 1/2/3 ceprox01.cerius.fr. A 194.51.109.157[|domain] (ttl 20, id 61307, len 162)

10:38:05.353444 217.128.230.16.3174 > 194.51.109.131.http: P 1:226(225) ack 1 win 65535 (DF) (ttl 127, id 22029, len 265)
10:38:05.521714 194.51.109.131.http > 217.128.230.16.3174: . [tcp sum ok] 2921:2921(0) ack 226 win 65310 (DF) (ttl 118, id 3698, len 40)

3. Why is there so much DNS request ? I understand the first one but why the others ?

jmcollin92 01-06-2004 04:50 PM

Here is a dialog which is OK directly from the server. This was obtained with :
Code:

telnet www.nordparis.banquepopulaire.fr 80
GET /

The dialog from ppp0 :
Code:

# tcpdump -vvv -i ppp0 port not ssh and port not pop3
tcpdump: listening on ppp0
23:38:17.740814 217.128.230.16.45532 > 194.51.109.131.http: S [tcp sum ok] 124488079:124488079(0) win 5808 <mss 1452,sackOK,timestamp 148389463 0,nop,wscale 0> (DF) [tos 0x10]  (ttl 64, id 47064, len 60)
23:38:17.833348 194.51.109.131.http > 217.128.230.16.45532: S [tcp sum ok] 2077187607:2077187607(0) ack 124488080 win 65535 <mss 1460,nop,wscale 0,nop,nop,timestamp 0 0,nop,nop,sackOK> (DF) (ttl 118, id 63086, len 64)
23:38:17.833371 217.128.230.16.45532 > 194.51.109.131.http: . [tcp sum ok] 1:1(0) ack 1 win 5808 <nop,nop,timestamp 148389472 0> (DF) [tos 0x10]  (ttl 64, id 47065, len 52)
23:38:21.384845 217.128.230.16.45532 > 194.51.109.131.http: P [tcp sum ok] 1:8(7) ack 1 win 5808 <nop,nop,timestamp 148389827 0> (DF) [tos 0x10]  (ttl 64, id 47066, len 59)
23:38:21.672681 194.51.109.131.http > 217.128.230.16.45532: . 1:1441(1440) ack 8 win 65528 <nop,nop,timestamp 390492 148389827> (DF) (ttl 118, id 63146, len 1492)
23:38:21.672709 217.128.230.16.45532 > 194.51.109.131.http: . [tcp sum ok] 8:8(0) ack 1441 win 8640 <nop,nop,timestamp 148389856 390492> (DF) [tos 0x10] (ttl 64, id 47067, len 52)
23:38:21.688696 194.51.109.131.http > 217.128.230.16.45532: . 1441:2881(1440) ack 8 win 65528 <nop,nop,timestamp 390492 148389827> (DF) (ttl 118, id 63147, len 1492)

In bold you've some differences with a nok dialog.


Can this help ?

yuray 01-08-2004 01:56 AM

Quote:

Originally posted by jmcollin92
It's not a pb because Error is > than Info and so messages are in both files.

It's a response packet no ?. Is it possible to see what is in the packet ? Perhaps there is an error or something like in this packet.

Save traffic to file
tcpdump -s 0 -w /file_name -i ppp0

Next step, gui ethereal.

yuray 01-08-2004 02:09 AM

Quote:

Originally posted by jmcollin92
[B]Here is another dialog with this site :
(from eth0) :
2921:2921(0) ack 226 win 65310 (DF) (ttl 117, id 3698, len 40)
[/CODE]

It's seems to be 3 packets for one call id=22026, 22027 and 22029.
1. Is it a framented packet ?
If I not wrong (DF) -disable fragmentation
Quote:

4. what means the 'P' after http: ?
P -push flag -- sent urgent data
Quote:


3. Why is there so much DNS request ? I understand the first one but why the others ?
It is tcpdump make resolving for output. Add flag -n

jmcollin92 01-08-2004 03:25 AM

Quote:

Originally posted by yuray
Save traffic to file
tcpdump -s 0 -w /file_name -i ppp0

Next step, gui ethereal.

Ok, I've got the file. What should I do with that ?

yuray 01-08-2004 03:47 AM

Quote:

Originally posted by jmcollin92
Here is a dialog which is OK directly from the server. This was obtained with :
Code:

telnet www.nordparis.banquepopulaire.fr 80
GET /

In bold you've some differences with a nok dialog.


Can this help ?

Try to send
GET / HTTP/1.1

yuray 01-08-2004 03:48 AM

Quote:

Originally posted by jmcollin92
Ok, I've got the file. What should I do with that ?
You need the program ethereal
This is GUI for showing file contents.

jmcollin92 01-08-2004 06:04 AM

Quote:

Originally posted by yuray
You need the program ethereal
This is GUI for showing file contents.

Is this a X window application or command line ?. Because I cannot export display on other X server.
If it is an X application, is there another way to inspect the packets ?

jmcollin92 01-08-2004 03:50 PM

Quote:

Originally posted by yuray
You need the program ethereal
This is GUI for showing file contents.

OK I've got it installed on a distant windows box.
I load a file generated on the Linux box and here is an extract of the interesting dialog (only packet at the begining and interesting packet are shown here. I can send the complete file to you if you want ...) :
Code:

Frame 50 (64 bytes on wire, 64 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.350905000
    Time delta from previous packet: 0.003661000 seconds
    Time since reference or first frame: 91.480258000 seconds
    Frame Number: 50
    Packet Length: 64 bytes
    Capture Length: 64 bytes
Linux cooked capture
    Packet type: Sent by us (4)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 217.128.230.16 (217.128.230.16), Dst Addr: 193.252.122.103 (193.252.122.103)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 48
    Identification: 0x3f3d (16189)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 127
    Protocol: TCP (0x06)
    Header checksum: 0xc095 (correct)
    Source: 217.128.230.16 (217.128.230.16)
    Destination: 193.252.122.103 (193.252.122.103)
Transmission Control Protocol, Src Port: 3153 (3153), Dst Port: http (80), Seq: 0, Ack: 0, Len: 0
    Source port: 3153 (3153)
    Destination port: http (80)
    Sequence number: 0
    Header length: 28 bytes
    Flags: 0x0002 (SYN)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...0 .... = Acknowledgment: Not set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..1. = Syn: Set
        .... ...0 = Fin: Not set
    Window size: 65535
    Checksum: 0x8272 (correct)
    Options: (8 bytes)
        Maximum segment size: 1460 bytes
        NOP
        NOP
        SACK permitted

Code:

Frame 56 (64 bytes on wire, 64 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.411793000
    Time delta from previous packet: 0.000059000 seconds
    Time since reference or first frame: 91.541146000 seconds
    Frame Number: 56
    Packet Length: 64 bytes
    Capture Length: 64 bytes
Linux cooked capture
    Packet type: Unicast to us (0)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 193.252.122.103 (193.252.122.103), Dst Addr: 217.128.230.16 (217.128.230.16)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 48
    Identification: 0x0000 (0)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 53
    Protocol: TCP (0x06)
    Header checksum: 0x49d3 (correct)
    Source: 193.252.122.103 (193.252.122.103)
    Destination: 217.128.230.16 (217.128.230.16)
Transmission Control Protocol, Src Port: http (80), Dst Port: 3153 (3153), Seq: 0, Ack: 1, Len: 0
    Source port: http (80)
    Destination port: 3153 (3153)
    Sequence number: 0
    Acknowledgement number: 1
    Header length: 28 bytes
    Flags: 0x0012 (SYN, ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..1. = Syn: Set
        .... ...0 = Fin: Not set
    Window size: 5840
    Checksum: 0xee81 (correct)
    Options: (8 bytes)
        Maximum segment size: 1460 bytes
        NOP
        NOP
        SACK permitted
    SEQ/ACK analysis
        This is an ACK to the segment in frame: 50
        The RTT to ACK the segment was: 0.060888000 seconds

Code:

Frame 58 (56 bytes on wire, 56 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.412127000
    Time delta from previous packet: 0.000290000 seconds
    Time since reference or first frame: 91.541480000 seconds
    Frame Number: 58
    Packet Length: 56 bytes
    Capture Length: 56 bytes
Linux cooked capture
    Packet type: Sent by us (4)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 217.128.230.16 (217.128.230.16), Dst Addr: 193.252.122.103 (193.252.122.103)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 40
    Identification: 0x3f41 (16193)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 127
    Protocol: TCP (0x06)
    Header checksum: 0xc099 (correct)
    Source: 217.128.230.16 (217.128.230.16)
    Destination: 193.252.122.103 (193.252.122.103)
Transmission Control Protocol, Src Port: 3153 (3153), Dst Port: http (80), Seq: 1, Ack: 1, Len: 0
    Source port: 3153 (3153)
    Destination port: http (80)
    Sequence number: 1
    Acknowledgement number: 1
    Header length: 20 bytes
    Flags: 0x0010 (ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 65535
    Checksum: 0x3216 (correct)
    SEQ/ACK analysis
        This is an ACK to the segment in frame: 56
        The RTT to ACK the segment was: 0.000334000 seconds

Code:

Frame 61 (263 bytes on wire, 263 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.419130000
    Time delta from previous packet: 0.001182000 seconds
    Time since reference or first frame: 91.548483000 seconds
    Frame Number: 61
    Packet Length: 263 bytes
    Capture Length: 263 bytes
Linux cooked capture
    Packet type: Sent by us (4)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 217.128.230.16 (217.128.230.16), Dst Addr: 193.252.122.103 (193.252.122.103)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 247
    Identification: 0x3f45 (16197)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 127
    Protocol: TCP (0x06)
    Header checksum: 0xbfc6 (correct)
    Source: 217.128.230.16 (217.128.230.16)
    Destination: 193.252.122.103 (193.252.122.103)
Transmission Control Protocol, Src Port: 3153 (3153), Dst Port: http (80), Seq: 1, Ack: 1, Len: 207
    Source port: 3153 (3153)
    Destination port: http (80)
    Sequence number: 1
    Next sequence number: 208
    Acknowledgement number: 1
    Header length: 20 bytes
    Flags: 0x0018 (PSH, ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 1... = Push: Set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 65535
    Checksum: 0x9c19 (correct)
Hypertext Transfer Protocol
    GET / HTTP/1.1\r\n
        Request Method: GET
    Accept: */*\r\n
    Accept-Language: fr\r\n
    Accept-Encoding: gzip, deflate\r\n
    User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; Wanadoo 5.6)\r\n
    Host: www.wanadoo.fr\r\n
    Connection: Keep-Alive\r\n
    \r\n

Code:

Frame 69 (1508 bytes on wire, 1508 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.587231000
    Time delta from previous packet: 0.063996000 seconds
    Time since reference or first frame: 91.716584000 seconds
    Frame Number: 69
    Packet Length: 1508 bytes
    Capture Length: 1508 bytes
Linux cooked capture
    Packet type: Unicast to us (0)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 193.252.122.103 (193.252.122.103), Dst Addr: 217.128.230.16 (217.128.230.16)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 1492
    Identification: 0xdc03 (56323)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 53
    Protocol: TCP (0x06)
    Header checksum: 0x682b (correct)
    Source: 193.252.122.103 (193.252.122.103)
    Destination: 217.128.230.16 (217.128.230.16)
Transmission Control Protocol, Src Port: http (80), Dst Port: 3153 (3153), Seq: 1, Ack: 208, Len: 1452
    Source port: http (80)
    Destination port: 3153 (3153)
    Sequence number: 1
    Next sequence number: 1453
    Acknowledgement number: 208
    Header length: 20 bytes
    Flags: 0x0010 (ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 6432
    Checksum: 0x18f7 (correct)
Hypertext Transfer Protocol
    HTTP/1.1 200 OK\r\n
        Response Code: 200
    Date: Thu, 08 Jan 2004 09:22:11 GMT\r\n
    Server: Apache\r\n
    Set-Cookie: webauth=02003ffd24c70000038400000000e1ac7cc4bddebcef505ac29f82921fe9d980e610anonyme;domain=.wanadoo.fr;path=/\r\n
    Keep-Alive: timeout=2, max=20\r\n
    Connection: Keep-Alive\r\n
    Content-Type: text/html\r\n
    Content-Encoding: gzip\r\n
    Content-Length: 8470\r\n
    \r\n
    Data (1131 bytes)

0000  1f 8b 08 00 00 00 00 00 00 03 ec 3d ed 52 db ca  ...........=.R..
0010  92 bf 43 d5 7d 87 b9 3a 75 00 5f b0 8d 0d 38 01  ..C.}..:u._...8.
...
0450  a9 16 8f 5c 9c cd 62 c6 7d 46 c2 e2 6f 2a b8 81  ...\..b.}F..o*..
0460  a6 63 67 f1 a9 27 bd 95 48 bb 11                  .cg..'..H..

Code:

Frame 76 (1508 bytes on wire, 1508 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.699201000
    Time delta from previous packet: 0.031994000 seconds
    Time since reference or first frame: 91.828554000 seconds
    Frame Number: 76
    Packet Length: 1508 bytes
    Capture Length: 1508 bytes
Linux cooked capture
    Packet type: Unicast to us (0)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 193.252.122.103 (193.252.122.103), Dst Addr: 217.128.230.16 (217.128.230.16)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 1492
    Identification: 0xdc06 (56326)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 53
    Protocol: TCP (0x06)
    Header checksum: 0x6828 (correct)
    Source: 193.252.122.103 (193.252.122.103)
    Destination: 217.128.230.16 (217.128.230.16)
Transmission Control Protocol, Src Port: http (80), Dst Port: 3153 (3153), Seq: 2921, Ack: 208, Len: 1452
    Source port: http (80)
    Destination port: 3153 (3153)
    Sequence number: 2921
    Next sequence number: 4373
    Acknowledgement number: 208
    Header length: 20 bytes
    Flags: 0x0010 (ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 6432
    Checksum: 0x93f1 (correct)
    SEQ/ACK analysis
        TCP Analysis Flags
            A segment before this frame was lost

Hypertext Transfer Protocol
    Data (1452 bytes)

0000  71 c8 0c 31 e8 d7 de a3 49 b1 8d ba ff 2d 7d c3  q..1....I....-}.
...
05a0  e1 67 c4 b1 5c 57 4f 4d ad b3 53 a2              .g..\WOM..S.

Code:

Frame 79 (68 bytes on wire, 68 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.699667000
    Time delta from previous packet: 0.000008000 seconds
    Time since reference or first frame: 91.829020000 seconds
    Frame Number: 79
    Packet Length: 68 bytes
    Capture Length: 68 bytes
Linux cooked capture
    Packet type: Sent by us (4)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 217.128.230.16 (217.128.230.16), Dst Addr: 193.252.122.103 (193.252.122.103)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 52
    Identification: 0x3f4a (16202)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 127
    Protocol: TCP (0x06)
    Header checksum: 0xc084 (correct)
    Source: 217.128.230.16 (217.128.230.16)
    Destination: 193.252.122.103 (193.252.122.103)
Transmission Control Protocol, Src Port: 3153 (3153), Dst Port: http (80), Seq: 208, Ack: 2913, Len: 0
    Source port: 3153 (3153)
    Destination port: http (80)
    Sequence number: 208
    Acknowledgement number: 2913
    Header length: 32 bytes
    Flags: 0x0010 (ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 64083
    Checksum: 0xded6 (correct)
    Options: (12 bytes)
        NOP
        NOP
        SACK:
            left edge = 3156462676
            right edge = 3156464136
    SEQ/ACK analysis
        TCP Analysis Flags
            This is a TCP duplicate ack
        Duplicate ACK #: 1
        Duplicate to the ACK in frame: 78
       

Code:

Frame 85 (64 bytes on wire, 64 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.763159000
    Time delta from previous packet: 0.015484000 seconds
    Time since reference or first frame: 91.892512000 seconds
    Frame Number: 85
    Packet Length: 64 bytes
    Capture Length: 64 bytes
Linux cooked capture
    Packet type: Unicast to us (0)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 193.252.122.103 (193.252.122.103), Dst Addr: 217.128.230.16 (217.128.230.16)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 48
    Identification: 0xdc08 (56328)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 53
    Protocol: TCP (0x06)
    Header checksum: 0x6dca (correct)
    Source: 193.252.122.103 (193.252.122.103)
    Destination: 217.128.230.16 (217.128.230.16)
Transmission Control Protocol, Src Port: http (80), Dst Port: 3153 (3153), Seq: 2913, Ack: 208, Len: 8
    Source port: http (80)
    Destination port: 3153 (3153)
    Sequence number: 2913
    Next sequence number: 2921
    Acknowledgement number: 208
    Header length: 20 bytes
    Flags: 0x0010 (ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 6432
    Checksum: 0x7b30 (correct)
    SEQ/ACK analysis
        TCP Analysis Flags
            This frame is a (suspected) retransmission
Hypertext Transfer Protocol
    Data (8 bytes)

0000  2e 81 91 2e 17 1a ba c4                          ........

Code:

Frame 86 (56 bytes on wire, 56 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.763312000
    Time delta from previous packet: 0.000153000 seconds
    Time since reference or first frame: 91.892665000 seconds
    Frame Number: 86
    Packet Length: 56 bytes
    Capture Length: 56 bytes
Linux cooked capture
    Packet type: Sent by us (4)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 217.128.230.16 (217.128.230.16), Dst Addr: 193.252.122.103 (193.252.122.103)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 40
    Identification: 0x3f4d (16205)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 127
    Protocol: TCP (0x06)
    Header checksum: 0xc08d (correct)
    Source: 217.128.230.16 (217.128.230.16)
    Destination: 193.252.122.103 (193.252.122.103)
Transmission Control Protocol, Src Port: 3153 (3153), Dst Port: http (80), Seq: 208, Ack: 4381, Len: 0
    Source port: 3153 (3153)
    Destination port: http (80)
    Sequence number: 208
    Acknowledgement number: 4381
    Header length: 20 bytes
    Flags: 0x0010 (ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 65535
    Checksum: 0x202b (correct)
    SEQ/ACK analysis
        This is an ACK to the segment in frame: 77
        The RTT to ACK the segment was: 0.064084000 seconds

Code:

Frame 87 (1508 bytes on wire, 1508 bytes captured)
    Arrival Time: Jan  8, 2004 10:24:11.779210000
    Time delta from previous packet: 0.015898000 seconds
    Time since reference or first frame: 91.908563000 seconds
    Frame Number: 87
    Packet Length: 1508 bytes
    Capture Length: 1508 bytes
Linux cooked capture
    Packet type: Unicast to us (0)
    Link-layer address type: 512
    Link-layer address length: 0
    Source: <MISSING>
    Protocol: IP (0x0800)
Internet Protocol, Src Addr: 193.252.122.103 (193.252.122.103), Dst Addr: 217.128.230.16 (217.128.230.16)
    Version: 4
    Header length: 20 bytes
    Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00)
        0000 00.. = Differentiated Services Codepoint: Default (0x00)
        .... ..0. = ECN-Capable Transport (ECT): 0
        .... ...0 = ECN-CE: 0
    Total Length: 1492
    Identification: 0xdc09 (56329)
    Flags: 0x04
        .1.. = Don't fragment: Set
        ..0. = More fragments: Not set
    Fragment offset: 0
    Time to live: 53
    Protocol: TCP (0x06)
    Header checksum: 0x6825 (correct)
    Source: 193.252.122.103 (193.252.122.103)
    Destination: 217.128.230.16 (217.128.230.16)
Transmission Control Protocol, Src Port: http (80), Dst Port: 3153 (3153), Seq: 4381, Ack: 208, Len: 1452
    Source port: http (80)
    Destination port: 3153 (3153)
    Sequence number: 4381
    Next sequence number: 5833
    Acknowledgement number: 208
    Header length: 20 bytes
    Flags: 0x0010 (ACK)
        0... .... = Congestion Window Reduced (CWR): Not set
        .0.. .... = ECN-Echo: Not set
        ..0. .... = Urgent: Not set
        ...1 .... = Acknowledgment: Set
        .... 0... = Push: Not set
        .... .0.. = Reset: Not set
        .... ..0. = Syn: Not set
        .... ...0 = Fin: Not set
    Window size: 6432
    Checksum: 0x0f72 (correct)
Hypertext Transfer Protocol
    Data (1452 bytes)

0000  9a 67 ea ea b1 3c 50 17 78 99 09 65 a2 c0 f4 16  .g...<P.x..e....
...
05a0  e6 a1 8f 03 61 11 83 8a 0e 01 73 1d              ....a.....s.

I've put in bold where there is something interesting (I think ...).
This is trace from ppp0 interface only. I don't have the traces from eth0 interface.

Sorry for the long, long listing....
I can send the tcpdump file to you if you want .

Many many thank's for your help.

yuray 01-09-2004 01:08 AM

Quote:

Originally posted by jmcollin92
Is this a X window application or command line ?. Because I cannot export display on other X server.
If it is an X application, is there another way to inspect the packets ?

X application. Copy file on another linux box.

jmcollin92 02-28-2004 09:58 AM

SOLUTION
 
It was an MTU/MRU or Clamp MSS problem.
The solution is to type this command :
iptables -t mangle -A FORWARD -p tcp --syn -j TCPMSS --clamp-mss-to-pmtu
or this command :
iptables -t mangle -A FORWARD -p tcp --syn -j TCPMSS --set-mss 1452

More informations are available on this link :
here

bluenirve 02-28-2004 10:12 PM

Quote:

Originally posted by slightcrazed
255 = broadcast, meaning that packets are sent to every host on the subnet.
Gates is right, 0 can be used as long as it is not the end of the host portion.
Sorry to be off topic, but man and I supprised to see a pro-MS comment like that in this forum :)


All times are GMT -5. The time now is 10:39 AM.