Scott McNab
2009-Feb-05 08:05 UTC
[asterisk-users] Configure Asterisk to preserve SIP header?
Hello. Is it possible to configure Asterisk to preserve specific SIP INVITE headers when setting up a call? Specifically, I have a custom SIP client that sends an additional header in the INVITE request when originating a call. This is to request that the call is auto-answered by the destination phone. i.e. Call-Info: <sip:192.168.100.50>;answer-after=0 If I use wireshark to sniff the packets, I can see that this header is present in the original INVITE request from my SIP phone to Asterisk, however, in the INVITE message that Asterisk sends to the recipient phone, this header has been stripped. Is it possible to configure Asterisk so that it forwards this SIP header intact? I know that it is possible to set up a dialplan to insert this header for specific extensions, but I really would like to be able to generate this header using my client! Any ideas would be greatly appreciated! Thanks Scott -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090205/b4d16527/attachment.htm
Benny Amorsen
2009-Feb-05 12:10 UTC
[asterisk-users] Configure Asterisk to preserve SIP header?
Scott McNab <scott.mcnab at gmail.com> writes:> Call-Info: <sip:192.168.100.50>;answer-after=0 > > Is it possible to configure Asterisk so that it forwards this SIP header > intact?> I know that it is possible to set up a dialplan to insert this header for > specific extensions, but I really would like to be able to generate this > header using my client!exten => _X!,n,SIPAddHeader(${SIP_HEADER(Call-Info)}) Asterisk doesn't forward anything, it isn't a proxy, but you can achieve some of the effect by that dial plan rule. Syntax is from memory, completely untested. /Benny
Danny Nicholas
2009-Feb-05 14:25 UTC
[asterisk-users] Configure Asterisk to preserve SIP header?
Since this information is available in debug, it is obviously there for the taking and redistribution. Someone more versed than I will have to give you a real answer. The "Clunky/hack" way to get it would be a "teed" log read via AGI/AMI. _____ From: asterisk-users-bounces at lists.digium.com [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Scott McNab Sent: Thursday, February 05, 2009 2:06 AM To: asterisk-users at lists.digium.com Subject: [asterisk-users] Configure Asterisk to preserve SIP header? Hello. Is it possible to configure Asterisk to preserve specific SIP INVITE headers when setting up a call? Specifically, I have a custom SIP client that sends an additional header in the INVITE request when originating a call. This is to request that the call is auto-answered by the destination phone. i.e. Call-Info: <sip:192.168.100.50>;answer-after=0 If I use wireshark to sniff the packets, I can see that this header is present in the original INVITE request from my SIP phone to Asterisk, however, in the INVITE message that Asterisk sends to the recipient phone, this header has been stripped. Is it possible to configure Asterisk so that it forwards this SIP header intact? I know that it is possible to set up a dialplan to insert this header for specific extensions, but I really would like to be able to generate this header using my client! Any ideas would be greatly appreciated! Thanks Scott -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090205/652952ce/attachment.htm