On Fri, Jul 11, 2008 at 6:53 PM, Enrico De Razza <ederazza at yahoo.it> wrote: > Hello folk! > > I'm a student and I'm doing a research on the NAT traversal problem in > order to achieve a direct p2p communication. > After > the study of the relative RFC and Drafts, I've come to a solution for > my project, and now I'd like to use the pj_libraries for NAT traversal. > I've studied yet the version 0.8 of pjstun_client (in order to perform > NAT detection), but now I've to go further and try to traverse the NAT. > I > wished to use UDP Hole Punching, and ICE seems to work even better > because realize a UDP hole punch with the exchange of both local and > mapped address: is all right or I'm wrong? With regard to hole punching, probably it's not that much better since it's basically using the same technique. What makes it better is it offers choices of candidates to try so it should work with more NAT deployment scenarios. > My probem is that I don't know how to start using ICE after performing the > detection. > Moreover, > thanks to the changes made in the APIs version 0.9, I need to modify > the first part of the code... and a lot of attributes are lost (like > PJ_STUN_ATTR_REMOTE_ADDR, PJ_STUN_SET_ACTIVE_DESTINATION_REQUEST, > PJ_STUN_ATTR_REQ_PORT_PROPS..). > Would you please clarify me those aspects? These are TURN attributes, and have been deprecated in the newer TURN draft. > > Could anyone explain me how to proceed? > I think that: > I've to start with the pj_ice_strans_create(), and then call the > pj_ice_strans_init_ice() and finally pj_ice_strans_start_ice(). > Is that all right? Yes, that should be just about it. > > And what about the pj_ice_strans_cfg_default() and pj_ice_strans_send_to()? > Shall I've to call the pj_ice_strans_cfg_default() from within the > pj_ice_strans_init_ice()? No! You don't need to modify the library to use it. The pj_ice_strans_cfg_default() is used to initialize the pj_ice_strans_cfg with default values, before you set your setting pj_ice_strans_cfg. Then you'll give the setting to pj_ice_strans_create(). The pj_ice_strans_send_to() is to send RTP/RTCP packets. Cheers Benny -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20080712/6dc934c4/attachment.html