[Home]

Summary:ASTERISK-12031: Unable to overwrite SIP Header using SipAddHeader()
Reporter:dimitripietro (dimitripietro)Labels:
Date Opened:2008-05-16 08:44:02Date Closed:2011-06-07 14:07:50
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Channels/chan_sip/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:I'm using the alert-info sip header to use distictive ringtone on Polycom phone. Basically, the polycom need to see a specific value in the alert-info field.

In Asterisk 1.2, I was using : Set(_ALERT_INFO=info=Custom 1) to set the ringtone and to overwrite it later, it was using the same thing with another value : Set(_ALERT_INFO=info=Custom 2)

In Asterisk 1.4, now I'm using : Sipaddheader(Alert-Info:Custom 1) but if I try to overwrite it later with Sipaddheader(Alert-Info:Custom 2) it won't work, it add a second header instead.

The polycom will now use the latest SIP Alert-Info header instead of the newest.

****** ADDITIONAL INFORMATION ******

I will include the wireshark debug as soon as possible.
Comments:By: Olle Johansson (oej) 2008-05-16 08:45:19

Run dumpchan() on the channel after you've added the first header, then change the channel variable that contains your header.

By: Olle Johansson (oej) 2008-05-16 08:45:59

sipaddheader does not check for duplicates, since you're allowed to have multiple headers with the same name.

By: Leif Madsen (lmadsen) 2008-05-16 10:17:27

How hard would it be to add an 'r' option for 'replace'?

I know this is a feature request, so feel free to ignore my idea :)

By: dimitripietro (dimitripietro) 2008-05-16 10:22:45

It's working fine, should it be added to the documentation ?

By: Olle Johansson (oej) 2008-05-16 10:26:59

File feature requests on http://www.asteriskideas.org - thank you!

Good to know that it's working. Documentation updates are always welcome!