Headers of UDP and TCP data are different. I have a use case, where I want to transfer the RTP media stream. Where first choice is UDP and then TCP.
Now imagine that the RTP packet is received to a local UDP port. This local machine attempts a connection with server using UDP first. If it's successful, then no further queries.
But if UDP wasn't possible then we make a TCP connection. Can I relay the local UDP port's data on TCP? Assume that, it will be finally fed to a peer UDP port. Our interest is only for relaying it.
Switch UDP port and TCP connection vice versa. Is that also possible?