Hello again, On Wed, 13 Sep 2006, Henrik Nordstrom wrote:
> Currently I use the same Contact for all identifies, and switching > identity based on To. But I have found some registrars dislikes multiple > identities registered with the same contact. I think being able to > specify a contact like sip:[EMAIL PROTECTED]:port] in register would solve > some > issues, and then reuse this in outgoing requests where needed. as an alternative to Pekka's NUTAG_M_USERNAME(), you can also disable Sofia-SIP's outbound logic (that rewrites the contact) altogether (NUTAG_OUTBOUND("no-natify") to nua_set_params()), and then pass SIPTAG_CONTACT_STR() to all nua operations (nua_register(), nua_invite(), nua_respond(), etc). To initialize the host:port part of the contact, you can query NTATAG_CONTACT_STR() in nua_r_get_params() callback. You need to call nua_get_params() after nua_create() to get this callback. I'm not 100% certain this will work (the danger is that the stack will rewrite the Contact in some cornercase), so Pekka's NUTAG_M_USERNAME() might be more future-proof (and allows to use the NAT traversal logic). But at least simple tests I did worked fine (I could pass my custom contact to nua_register() and that was also used in the message sent to network). -- under work: Sofia-SIP at http://sofia-sip.sf.net ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Sofia-sip-devel mailing list Sofia-sip-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel