chan_sip supported sending AOC-D and AOC-E information in SIP INFO messages in an "AOC" header in a format that was originally defined by Snom. In the meantime, ETSI TS 124 647 introduced an XML-based AOC format that is supported by devices from multiple vendors, including Snom phones with firmware >= 8.4.2 (released in 2010). This commit adds a new res_pjsip_aoc module that inserts AOC information into outgoing messages or sends SIP INFO messages as described below. It also fixes a small issue in res_pjsip_session which didn't always call session supplements on outgoing_response. * AOC-S in the 180/183/200 responses to an INVITE request * AOC-S in SIP INFO (if a 200 response has already been sent or if the INVITE was sent by Asterisk) * AOC-D in SIP INFO * AOC-D in the 200 response to a BYE request (if the client hangs up) * AOC-D in a BYE request (if Asterisk hangs up) * AOC-E in the 200 response to a BYE request (if the client hangs up) * AOC-E in a BYE request (if Asterisk hangs up) The specification defines one more, AOC-S in an INVITE request, which is not implemented here because it is not currently possible in Asterisk to have AOC data ready at this point in call setup. Once specifying AOC-S via the dialplan or passing it through from another SIP channel's INVITE is possible, that might be added. The SIP INFO requests are sent out immediately when the AOC indication is received. The others are inserted into an appropriate outgoing message whenever that is ready to be sent. In the latter case, the XML is stored in a channel variable at the time the AOC indication is received. Depending on where the AOC indications are coming from (e.g. PRI or AMI), it may not always be possible to guarantee that the AOC-E is available in time for the BYE. Successfully tested AOC-D and both variants of AOC-E with a Snom D735 running firmware 10.1.127.10. It does not appear to properly support AOC-S however, so that could only be tested by inspecting SIP traces. ASTERISK-21502 #close Reported-by: Matt Jordan <mjordan@digium.com> Change-Id: Iebb7ad0d5f88526bc6629d3a1f9f11665434d333
DO NOT REMOVE THIS FILE!
The only files that should be added to this directory are ones that will be used by the release script to update the CHANGES file automatically. The only time that it is necessary to add something to the CHANGES-staging directory is if you are either adding a new feature to Asterisk or adding new functionality to an existing feature. The file does not need to have a meaningful name, but it probably should. If there are multiple items that need documenting, you can add multiple files, each with their own description. If the message is going to be the same for each subject, then you can add multiple subject headers to one file. The "Subject: xxx" line is case sensitive! For example, if you are making a change to PJSIP, then you might add the file "res_pjsip_my_cool_feature.txt" to this directory, with a short description of what it does. The files must have the ".txt" suffix. If you are adding multiple entries, they should be done in the same commit to avoid merge conflicts. Here's an example:
Subject: res_pjsip Subject: Core
Here's a pretty good description of my new feature that explains exactly what it does and how to use it.
Here's a master-only example:
Subject: res_ari Master-Only: True
This change will only go into the master branch. The "Master-Only" header will never be in a change not in master.
Note that the second subject has another header: "Master-Only". Changes that go into the master branch and ONLY the master branch are the only ones that should have this header. Also, the value can only be "true" or "True". The "Master-Only" part of the header IS case-sensitive, however!
For more information, check out the wiki page: https://wiki.asterisk.org/wiki/display/AST/CHANGES+and+UPGRADE.txt