antirez / antirez/hping

hping packet mess when running same test on same machine

Open
#7 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
C
Stars
1.7k
Forks
364
PR merge metrics
No merged PRs in 30d

Description

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.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.