Switch to a connected UDP kernel socket. Comparing the local and remote IPs is no longer required and handling different IP versions and UDP types is automatic. The WTP logic needs to reopen the socket on demand now.
This is incomplete. There are several places left where a global variable is used (e.g. there can only be one AC session).