alpha net-yy test failures due to port decode errors

Mike Frysinger vapier at gentoo.org
Sun Mar 1 09:05:33 UTC 2015


On 27 Feb 2015 01:06, Mike Frysinger wrote:
> vFAIL: test; alpha/64-bit/LSB linux-3.18.1 kernel-headers-3.19.0 glibc-2.20 gcc-4.9.2
> net-yy

there's some port decoding weirdness going on here.

the server does:
09:32:03.185497 accept(0<TCP:[127.0.0.1:55298]>, ...
[pid 25534] 09:32:03.205029 <... accept resumed> {sa_family=AF_INET, 
sin_port=htons(37777), sin_addr=inet_addr("127.0.0.1")}, [16]) = 
1<TCP:[127.0.0.1:55298->127.0.0.1:37632]>

the 37777 (0x9391) doesn't match the 37632 (0x9300).  running this multiple 
times shows the same issue -- the lower 16bits are always cleared in the later 
decoding lines.  checking the /proc/$pid/net/tcp lines shows that the 0x9391 is 
the correct port.

it looks like the logic in socketutils.c is off a bit.  maybe some of the 
buffers aren't correct ?  the large number marked "static" is a bit concerning.
if i hack inet_parse_response and increase zero_addr by an arbitrary 20 bytes,
the port gets decoded correctly and the test starts passing.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20150301/ee303df1/attachment.bin>


More information about the Strace-devel mailing list