This commit is contained in:
raphael.thieffry
2025-02-03 11:40:41 +01:00
parent d82baff03b
commit 343d592215

View File

@@ -4,17 +4,20 @@
Raphaël, Ethan, Antonin Raphaël, Ethan, Antonin
## Sommaire ## Sommaire
- [Partie 1](#partie-1) - [TP 2 réseau](#tp-2-réseau)
- [Partie 2](#partie-2) - [Team](#team)
- [Sommaire](#sommaire)
- [Partie 1](#partie-1)
- [Partie 2](#partie-2)
- [Exercice 1](#exercice-1) - [Exercice 1](#exercice-1)
- [Exercice 2](#exercice-2) - [Exercice 2](#exercice-2)
- [Exercice 3](#exercice-3) - [Exercice 3](#exercice-3)
- [Exercice 4](#exercice-4) - [Exercice 4](#exercice-4)
- [Exercice 5](#exercice-5) - [Exercice 5](#exercice-5)
-------------------- --------------------
## Partie 1 ## Partie 1
Configuration de deux VM chez Ethan (Cynosure, Mikoshi) Configuration de deux machines chez Ethan (Cynosure, Mikoshi)
Machine | Cynosure | Mikoshi | Machine | Cynosure | Mikoshi |
|------------|--------------|--------------| |------------|--------------|--------------|
| IPAdress | 192.168.1.87 | 192.168.1.42 | | IPAdress | 192.168.1.87 | 192.168.1.42 |
@@ -89,9 +92,49 @@ Log ici :
09:37:59.557156 IP 192.168.1.42.53801 > cynosure.nsca: Flags [.], ack 2, win 502, options [nop,nop,TS val 3088549142 ecr 3686256455], length 0 09:37:59.557156 IP 192.168.1.42.53801 > cynosure.nsca: Flags [.], ack 2, win 502, options [nop,nop,TS val 3088549142 ecr 3686256455], length 0
```` ````
c) c)
````shell Il faut que le paquet tcp envoyé ait une taille inferieure à MSS.
Quand on envoit un paquet de 35 000 octets, on a un découpage qui s'opère alors, et les données sont reçues dans l'ordre, même si mal delimitées (flux).
On voit dans les logs ci dessous la reception non-pas d'un paquet tcp, mais bien de plusieurs de taille variables:
````shell
192.168.1.42.32783 > cynosure.nsca: Flags [S], cksum 0x0d1e (correct), seq 129520240, win 64240, options [mss 1460,sackOK,TS val 3089699739 ecr 0,nop,wscale 7], length 0
09:57:10.154360 IP (tos 0x0, ttl 64, id 0, offset 0, flags [DF], proto TCP (6), length 60) cynosure.nsca > 192.168.1.42.32783: Flags [S.], cksum 0x8400 (incorrect -> 0x3b63), seq 3461727828, ack 129520241, win 65160, options [mss 1460,sackOK,TS val 3687407005 ecr 3089699739,nop,wscale 7], length 0
09:57:10.154651 IP (tos 0x0, ttl 64, id 8639, offset 0, flags [DF], proto TCP (6), length 52)
192.168.1.42.32783 > cynosure.nsca: Flags [.], cksum 0x66c1 (correct), ack 1, win 502, options [nop,nop,TS val 3089699740 ecr 3687407005], length 0
09:57:10.155397 IP (tos 0x0, ttl 64, id 8640, offset 0, flags [DF], proto TCP (6), length 2948)
192.168.1.42.32783 > cynosure.nsca: Flags [.], cksum 0x8f48 (incorrect -> 0x3f25), seq 1:2897, ack 1, win 502, options [nop,nop,TS val 3089699740 ecr 3687407005], length 2896
09:57:10.155443 IP (tos 0x0, ttl 64, id 22477, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [.], cksum 0x83f8 (incorrect -> 0x5b15), ack 2897, win 546, options [nop,nop,TS val 3687407053 ecr 3089699740], length 0
09:57:10.155482 IP (tos 0x0, ttl 64, id 8642, offset 0, flags [DF], proto TCP (6), length 4396)
192.168.1.42.32783 > cynosure.nsca: Flags [P.], cksum 0x94f0 (incorrect -> 0x143b), seq 2897:7241, ack 1, win 502, options [nop,nop,TS val 3089699740 ecr 3687407005], length 4344
09:57:10.155482 IP (tos 0x0, ttl 64, id 8645, offset 0, flags [DF], proto TCP (6), length 7292)
192.168.1.42.32783 > cynosure.nsca: Flags [P.], cksum 0xa040 (incorrect -> 0x2924), seq 7241:14481, ack 1, win 502, options [nop,nop,TS val 3089699740 ecr 3687407005], length 7240
09:57:10.155504 IP (tos 0x0, ttl 64, id 22478, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [.], cksum 0x83f8 (incorrect -> 0x49d9), ack 7241, win 614, options [nop,nop,TS val 3687407053 ecr 3089699740], length 0
09:57:10.155562 IP (tos 0x0, ttl 64, id 22479, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [.], cksum 0x83f8 (incorrect -> 0x2d8f), ack 14481, win 616, options [nop,nop,TS val 3687407053 ecr 3089699740], length 0
09:57:10.155926 IP (tos 0x0, ttl 64, id 8650, offset 0, flags [DF], proto TCP (6), length 5844)
192.168.1.42.32783 > cynosure.nsca: Flags [P.], cksum 0x9a98 (incorrect -> 0x79ba), seq 14481:20273, ack 1, win 502, options [nop,nop,TS val 3089699741 ecr 3687407053], length 5792
09:57:10.155926 IP (tos 0x0, ttl 64, id 8654, offset 0, flags [DF], proto TCP (6), length 8740)
192.168.1.42.32783 > cynosure.nsca: Flags [P.], cksum 0xa5e8 (incorrect -> 0x88fb), seq 20273:28961, ack 1, win 502, options [nop,nop,TS val 3089699741 ecr 3687407053], length 8688
09:57:10.155972 IP (tos 0x0, ttl 64, id 22480, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [.], cksum 0x83f8 (incorrect -> 0x16ac), ack 20273, win 681, options [nop,nop,TS val 3687407054 ecr 3089699741], length 0
09:57:10.156003 IP (tos 0x0, ttl 64, id 22481, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [.], cksum 0x83f8 (incorrect -> 0xf4d1), ack 28961, win 659, options [nop,nop,TS val 3687407054 ecr 3089699741], length 0
09:57:10.156065 IP (tos 0x0, ttl 64, id 8660, offset 0, flags [DF], proto TCP (6), length 6092)
192.168.1.42.32783 > cynosure.nsca: Flags [FP.], cksum 0x9b90 (incorrect -> 0x1506), seq 28961:35001, ack 1, win 502, options [nop,nop,TS val 3089699741 ecr 3687407053], length 6040
09:57:10.156089 IP (tos 0x0, ttl 64, id 22482, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [.], cksum 0x83f8 (incorrect -> 0xdd2d), ack 35002, win 670, options [nop,nop,TS val 3687407054 ecr 3089699741], length 0
09:57:10.156175 IP (tos 0x0, ttl 64, id 22483, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [F.], cksum 0x83f8 (incorrect -> 0xdd21), seq 1, ack 35002, win 681, options [nop,nop,TS val 3687407054 ecr 3089699741], length 0
09:57:10.406685 IP (tos 0x0, ttl 64, id 22484, offset 0, flags [DF], proto TCP (6), length 52)
cynosure.nsca > 192.168.1.42.32783: Flags [F.], cksum 0x83f8 (incorrect -> 0xdc26), seq 1, ack 35002, win 681, options [nop,nop,TS val 3687407305 ecr 3089699741], length 0
09:57:10.407123 IP (tos 0x0, ttl 64, id 0, offset 0, flags [DF], proto TCP (6), length 52) 192.168.1.42.32783 > cynosure.nsca: Flags [.], cksum 0xdbde (correct), ack 2, win 502, options [nop,nop,TS val 3089699992 ecr 3687407305], length 0
```` ````
En revanche, si on regarde la MTU, on remarque que les chiffres ne concordent pas : 1500 de MTU en envoi, mais pourtant on reçoit des paquets de taille >6000.
Il semble qu'il faille configurer tcpdump (plus précisement, TCP Segmentation Offload), mais les machines utilisées étant critiques pour le réseau local de éthan, nous n'avons pas voulu prendre de risque.
### Exercice 4 ### Exercice 4
a) a)
b) b)