title: SOCKS 5 and UDP (C/C++)
body: <p>I know that SOCKS 5 supports UDP and I have been over the structure of the packets that are sent/received in negotiating with a SOCKS proxy.</p>
  
  <p>The one thing I am not clear on is the procedure for setting up to register with a proxy to send/receive UDP packets.</p>
  
  <p>Specifically, my biggest question is, "Is the connection to the SOCKS proxy that is used to negotiate a UDP associate relationship still made with TCP/IP?". In other words, "Do you end up using a TCP/IP socket to receive UDP packets routed through a SOCKS proxy?"</p>
  
  <p>I would imagine that, if you used a TCP/IP connection to establish a pathway for UDP communication, you'd kind of be missing the whole point of establishing UDP communications.  However, on the other hand, if the negotiation were made using UDP (and resulted in a UDP socket), then how would the relationship be terminated when your application is shutting down and no longer needs the proxy to "remember" you?</p>
  
  <p>I have been all over the net looking for an example...but can't find anything. Any help (especially an example) would be appreciated.</p>