diff options
| author | David Gibson <david@gibson.dropbear.id.au> | 2025-04-17 11:55:42 +1000 |
|---|---|---|
| committer | Stefano Brivio <sbrivio@redhat.com> | 2025-04-22 12:42:03 +0200 |
| commit | 08e617ec2ba916d8250a41d3ac68183124a6ec3e (patch) | |
| tree | 824c8e0458cb8005d7ed1f14fb660deddff553f6 /doc | |
| parent | 4668e9137806b551f6ee44609064cc40243c2b6b (diff) | |
| download | passt-08e617ec2ba916d8250a41d3ac68183124a6ec3e.tar passt-08e617ec2ba916d8250a41d3ac68183124a6ec3e.tar.gz passt-08e617ec2ba916d8250a41d3ac68183124a6ec3e.tar.bz2 passt-08e617ec2ba916d8250a41d3ac68183124a6ec3e.tar.lz passt-08e617ec2ba916d8250a41d3ac68183124a6ec3e.tar.xz passt-08e617ec2ba916d8250a41d3ac68183124a6ec3e.tar.zst passt-08e617ec2ba916d8250a41d3ac68183124a6ec3e.zip | |
udp: Rework offender address handling in udp_sock_recverr()
Make a number of changes to udp_sock_recverr() to improve the robustness
of how we handle addresses.
* Get the "offender" address (source of the ICMP packet) using the
SO_EE_OFFENDER() macro, reducing assumptions about structure layout.
* Parse the offender sockaddr using inany_from_sockaddr()
* Check explicitly that the source and destination pifs are what we
expect. Previously we checked something that was probably equivalent
in practice, but isn't strictly speaking what we require for the rest
of the code.
* Verify that for an ICMPv4 error we also have an IPv4 source/offender
and destination/endpoint address
* Verify that for an ICMPv6 error we have an IPv6 endpoint
* Improve debug reporting of any failures
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'doc')
0 files changed, 0 insertions, 0 deletions
