Jou, >-----Original Message----- >From: [EMAIL PROTECTED] >[mailto:[EMAIL PROTECTED] On Behalf >Of ext Kai Vehmanen >Sent: 11. tammikuuta 2006 20:34 >To: [email protected] >Subject: RE: [Sofia-sip-devel] STUN NAT type discovery works (?) > >On Wed, 11 Jan 2006 [EMAIL PROTECTED] wrote: > >> It was only a straight-forward implementation in stunc.c, but I now >> zapped unnecessary su_root_breaks and moved NAT type and lifetime >> determinations to start in callback after successful stun_bind_done. > >Ok great! > >Btw, one pretty serious issue: the STUN code never gives up >the socket - >this is pretty nasty once you really start to do something >with the brand >new socket STUN gave you - STUN module tries to parse each incoming >packet, and with RTP this results in a _lot_ of printed parse >errors. ;) > >Few ideas: >- add "stun_handle_release()" that unregisters the sockfds from > root, and cleans up handle state
added. > - stun_handle_destroy() is not that useful, as it closes to > sockfds >- check if the first two bits of each packet are zeroed; if not, > do not even try to parse as STUN (and drop silently, see rfc3489bis > draft); needed for ICE and sip-outbound use where STUN messages are > interleaved with SIP/RTP/RTCP done. >- add option not to bind() the socket in stun_bind() (you can already > pass a socket, but bind() is still always used) done. >- hmm, maybe still rename stun_bind() -- >stun_binding_discover() ? (with > a reference to RFC3489, sect 9.1 for clear definition of what > discovery means here) I'll try to figure out a sexy alternative for the current monster. > Lots of other changes done; several bug fixes in state machines, restructuring. All references to stun servers etc. are now kept inside stun_discovery objects. This way it's basically possible to use one stun_handle with different STUN servers (don't try yet;). Unique sockets can also be passed to different actions with STUNTAG_SOCKET() tag. If the socket is not registered, it will be su_root_registered. BR, Martti ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37&alloc_id865&op=click _______________________________________________ Sofia-sip-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel
