sleinen / samplicator

Send copies of (UDP) datagrams to multiple receivers, with optional sampling and spoofing
GNU General Public License v2.0
389 stars 132 forks source link

Spoofing mode doesn't work on lower-endian (Intel/AMD) Solaris #19

Closed sleinen closed 9 years ago

sleinen commented 9 years ago

From bsdreisb...@gmail.com on March 14, 2012 18:44:23

-S doesnt work on intel/amd solaris. I have attached a patch for review.

Attachment: rawsend.c.patch

Original issue: http://code.google.com/p/samplicator/issues/detail?id=20

sleinen commented 9 years ago

From simon.le...@gmail.com on March 14, 2012 11:19:49

Thanks for finding and fixing this long-standing bug. It is hard to find out on which systems ip_len (from struct ip) is in host byte order, and on which ones it is in network byte order. Linux and Solaris - and apparently newer versions of OpenBSD - have it in network byte order, but other BSD-based systems have it in host order. Your patch should improve life for Solaris-on-Intel/AMD users, without breaking it for anyone else. So I'll fold it into the source. Maybe I'll adapt the preceding comment a little. It would be great to have an autoconf macro for this...

Status: Started
Owner: simon.le...@gmail.com
Labels: OpSys-Solaris

sleinen commented 9 years ago

From simon.le...@gmail.com on March 14, 2012 14:34:59

This has now been added to the 1-3-maint branch as revision r133 , and released as samplicator-1.3.7-beta3. See also code review issue #21 for the complete patch. Please test and provide your feedback in the comments to this issue.

Status: Fixed