alpha net-yy test failures due to port decode errors

Masatake YAMATO yamato at redhat.com
Mon Mar 2 08:10:01 UTC 2015


On Sun, 1 Mar 2015 04:05:33 -0500, Mike Frysinger <vapier at gentoo.org> wrote:
> 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.

I'd like to know about your "hack" exactly.
Could you show me it as a diff file?

I'm thiking about alignment.
However, `idiag_dport', the problematic field is at the middle of
structure.

    /* Socket identity */
    struct inet_diag_sockid {
	    __be16	idiag_sport;
	    __be16	idiag_dport;
	    __be32	idiag_src[4];
	    __be32	idiag_dst[4];
	    __u32	idiag_if;
	    __u32	idiag_cookie[2];
    #define INET_DIAG_NOCOOKIE (~0U)
    };

I cannot image the situation that idiag_dport holds incorrect value but
idiag_sport nad idiag_src hold correct values.

I will prepare a hexdump code for dumping inet_diag_sockid to /tmp/somwhere.

Regards,
Masatake YAMATO





More information about the Strace-devel mailing list