< Previous by Date Date Index Next by Date >
  Thread Index Next in Thread >

[reSIProcate] How can I specify or modify the Via that the stack creates?


My question is this: how can I specify or modify the Via that the stack creates?
 
I have been pretty successful at integrating the Resiprocate stack into a SIP UA.
Here is a summary of the Resiprocate functions that my UA uses:
 
When I initiate an INVITE:
     uacDum->send(uacDum->makeInviteSession());
 
Response to an INVITE:
     sis->provisional(180); // ringing
     sis->provideAnswer(sdp);
     sis->accept();
or:
     sis->reject(code); //  code 603 == "Decline"
 
Forward:
     sis->redirect(myContacts); // send status 302 Moved Temporarily
 
HangUp:
     sis->end();
 
Accepting a REFER:
     Helper::makeResponse(*response, msg, statusCode); 
     uacDum->send(response);
 
Sending a REFER:
    sis->refer(cNameAddrDest); // or cis->refer()
 
Register with proxy:
    regMessage = uacDum->makeRegistration();
    uacDum->send(regMessage);
 
Most of the Resiprocate functions that my UA uses construct the message for me, and it is not
clear how/if I can get access the Via that the stack creates for me.
My UA needs to modify the UDP port and IP address in the Via based on the outcome
of uPNP/firewall traversal probing.