]> www.infradead.org Git - users/willy/xarray.git/commit
tipc: Return non-zero value from tipc_udp_addr2str() on error
authorShigeru Yoshida <syoshida@redhat.com>
Tue, 16 Jul 2024 02:09:05 +0000 (11:09 +0900)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Jul 2024 11:18:03 +0000 (12:18 +0100)
commitfa96c6baef1b5385e2f0c0677b32b3839e716076
treebb7e227d24bc827c44f3adcb67b68452863160f3
parent3ba359c0cd6eb5ea772125a7aededb4a2d516684
tipc: Return non-zero value from tipc_udp_addr2str() on error

tipc_udp_addr2str() should return non-zero value if the UDP media
address is invalid. Otherwise, a buffer overflow access can occur in
tipc_media_addr_printf(). Fix this by returning 1 on an invalid UDP
media address.

Fixes: d0f91938bede ("tipc: add ip/udp media type")
Signed-off-by: Shigeru Yoshida <syoshida@redhat.com>
Reviewed-by: Tung Nguyen <tung.q.nguyen@endava.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/udp_media.c