you can create local SDP offer or answer *manually* , then you can set any IP inside SDP. something like this pjmedia_sdp_session *sdp; pjmedia_sdp_media *m; pjmedia_sdp_attr *attr; /* Create and initialize basic SDP session */ sdp = (pjmedia_sdp_session *)pj_pool_zalloc(pool, sizeof(pjmedia_sdp_session)); SetSDPOrigin(call, sdp); sdp->name = pj_str("VOXMEDIA"); /* Since we only support one media stream at present, put the * SDP connection line in the session level. */ sdp->conn = (pjmedia_sdp_conn *)pj_pool_zalloc(pool, sizeof(pjmedia_sdp_conn)); sdp->conn->net_type = pj_str("IN"); sdp->conn->addr_type = pj_str("IP4"); sdp->conn->addr = pj_str(call->local_sdp_audio_ip); regards, Gang On Thu, Sep 18, 2008 at 8:32 PM, Mark Webster <mark.if webster+pjsip at gmail.com <webster%2Bpjsip at gmail.com>> wrote: > Just an update to this issue: If I specify the *a_name* of the bind > address in *pjsip_udp_transport_start*, then the Via: header reflects this > correctly, but the SDP still advertises the IP of first interface for > RTP/RTCP (even though I'm not bound to it). > > To clarify, the interfaces are on different subnets and the INVITEd party > can't reach my first interface. > > I'm sure I probably need to be doing something different after creating the > dialog, like *pjsip_dlg_set_transport*, but I can't quite work out how to > do that. When I use *pjsip_dlg_set_transport* to set the transport to the > one returned by *pjmedia_transport_udp_create*, it seems to invalidate the > dialog (although no error is returned). > > What am I missing? > > > On Thu, Sep 18, 2008 at 2:25 AM, Mark Webster < > mark.webster+pjsip at gmail.com <mark.webster%2Bpjsip at gmail.com>> wrote: > >> Hello again PJSIP people, forgive me if this has already been properly >> discussed or documented elsewhere, but I have searched and not found the >> answer. >> >> My app is running on a linux box with multiple interfaces. I'm not using >> PJSUA, rather just the base PJSIP/MEDIA/etc functions. >> >> What happens is during a SIP dialog, the SDP address and Via: fields are >> always automatically populated with the IP of the first interface. However, >> I am binding to another interface in *pjsip_udp_transport_start*. >> >> Ultimately I will be bridging calls across multiple interfaces, and I need >> a way of directly controlling the IP in the SDP and Via fields for each >> invite dialog. >> >> Could you point me to documentation or a quick example which explains how >> to do this? >> >> Thanks in advance. >> Mark >> > > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20080918/94562f0f/attachment.html