I'm trying to understand, once a packet reaches the WireGuard interface (wg0
) how is it sent to the UDP port from where it can be sent to the receiving peer.
I was reading the WireGuard whitepaper and it says
The interface itself has a private key and a UDP port on which it listens (more on that later), followed by a list of peers
I have only an elementary understanding of networking but I thought processes listen on ports so what does it mean for a network interface to listen on a UDP port?
If there is some way for a network interface to listen to a port, then on the receiving peer, the packet can likewise be received on the WireGuard interface from the UDP port. Is this a correct understanding?