diff options
| author | David Gibson <david@gibson.dropbear.id.au> | 2025-04-10 17:16:38 +1000 |
|---|---|---|
| committer | Stefano Brivio <sbrivio@redhat.com> | 2025-04-10 19:45:59 +0200 |
| commit | f4b0dd8b06850bacb2da57c8576e3377daa88572 (patch) | |
| tree | 1a74fbd12c14b5fd483ccd9107be212437364682 /contrib | |
| parent | 6693fa115824d198b7cde46c272514be194500a9 (diff) | |
| download | passt-f4b0dd8b06850bacb2da57c8576e3377daa88572.tar passt-f4b0dd8b06850bacb2da57c8576e3377daa88572.tar.gz passt-f4b0dd8b06850bacb2da57c8576e3377daa88572.tar.bz2 passt-f4b0dd8b06850bacb2da57c8576e3377daa88572.tar.lz passt-f4b0dd8b06850bacb2da57c8576e3377daa88572.tar.xz passt-f4b0dd8b06850bacb2da57c8576e3377daa88572.tar.zst passt-f4b0dd8b06850bacb2da57c8576e3377daa88572.zip | |
udp: Use PKTINFO cmsgs to get destination address for received datagrams
Currently we get the source address for received datagrams from recvmsg(),
but we don't get the local destination address. Sometimes we implicitly
know this because the receiving socket is bound to a specific address, but
when listening on 0.0.0.0 or ::, we don't.
We need this information to properly direct replies to flows which come in
to a non-default local address. So, enable the IP_PKTINFO and IPV6_PKTINFO
control messages to obtain this information in udp_peek_addr(). For now
we log a trace messages but don't do anything more with the information.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'contrib')
0 files changed, 0 insertions, 0 deletions
