[SR-Users] Modify Reply Created

Alex Balashov abalashov at evaristesys.com
Wed Jan 24 19:57:26 CET 2018


Hi Duarte,

On Wed, Jan 24, 2018 at 06:55:27PM +0000, Duarte Rocha wrote:

> Right now i'm doing a redirect server and i'm trying to sinalize the
> redirection using a 3xx reply. In order to do that, according the RFC I
> need to add a Contact and Diversion header. How do i do that ? i'm creating
> the reply with send_reply() but i can't seem to find a way to add these
> parameters to the reply.

append_to_reply() (from textops) is your friend here:

   append_to_reply("Contact: <sip:duarte at sip.rocha.aq>\r\n");

-- Alex

-- 
Alex Balashov | Principal | Evariste Systems LLC

Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free) 
Web: http://www.evaristesys.com/, http://www.csrpswitch.com/



More information about the sr-users mailing list