[asterisk-bugs] [JIRA] (ASTERISK-27163) chan_sip: Dialplan function SIP_HEADERS() to complement SIP_HEADER().

Richard Mudgett (JIRA) noreply at issues.asterisk.org
Mon Jul 31 10:22:57 CDT 2017


     [ https://issues.asterisk.org/jira/browse/ASTERISK-27163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Richard Mudgett updated ASTERISK-27163:
---------------------------------------

    Description: 
SIP_HEADERS(\[prefix])

If the argument is specified, only the headers matching the given prefix are returned.

The function returns a comma-separated list of SIP header names from an incoming INVITE message. Multiple headers with the same name are included in the list only once. The returned list can be iterated over using the functions POP() and SIP_HEADER().

For example, '$\{SIP_HEADER(Co)}' might return the string 'Contact,Content-Length,Content-Type'. 

Practical use is rather '$\{SIP_HEADER(X-)}' to enumerate optional extended headers sent by a peer.

Submitting to Gerrit in a moment.

  was:
SIP_HEADERS([prefix])

If the argument is specified, only the headers matching the given prefix are returned.

The function returns a comma-separated list of SIP header names from an incoming INVITE message. Multiple headers with the same name are included in the list only once. The returned list can be iterated over using the functions POP() and SIP_HEADER().

For example, '${SIP_HEADER(Co)}' might return the string 'Contact,Content-Length,Content-Type'. 

Practical use is rather '${SIP_HEADER(X-)}' to enumerate optional extended headers sent by a peer.

Submitting to Gerrit in a moment.


> chan_sip: Dialplan function SIP_HEADERS() to complement SIP_HEADER().
> ---------------------------------------------------------------------
>
>                 Key: ASTERISK-27163
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-27163
>             Project: Asterisk
>          Issue Type: New Feature
>      Security Level: None
>            Reporter: Kirill Katsnelson
>
> SIP_HEADERS(\[prefix])
> If the argument is specified, only the headers matching the given prefix are returned.
> The function returns a comma-separated list of SIP header names from an incoming INVITE message. Multiple headers with the same name are included in the list only once. The returned list can be iterated over using the functions POP() and SIP_HEADER().
> For example, '$\{SIP_HEADER(Co)}' might return the string 'Contact,Content-Length,Content-Type'. 
> Practical use is rather '$\{SIP_HEADER(X-)}' to enumerate optional extended headers sent by a peer.
> Submitting to Gerrit in a moment.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list