antirez / antirez/hping

hping packet mess when running same test on same machine

Aperta
#7 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
C
Stelle
1.7k
Fork
364
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

I noticed something related to hping3. Run the following command on the same machine on two different consoles:

sudo hping3 www.times.com -S -p 80

You will see a number of results with "rtt=0.0 ms" on both consoles, that they wouldn't be there if you were running only one command.

I think this is due to both processes catching each other's tcp packets. Since, they figure out they didn't send them, they print a rtt=0.0 ms.

The problem is in the function rtt() in rtt.c where it does *ms_delay = 0. Currently an hping3 process prints a 0.0 when it receives a packet that doesn't belong to it. However, I think in this case the packet should be ignored, and print nothing.

I would like to hear if there is a strong reason why it currently prints 0.0.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.