Commit Graph

108 Commits

Author SHA1 Message Date
Richard Mudgett
ed0d76d538 Add display ie text handling options.
The display ie handling can be controlled independently in the send and
receive directions with the following options:

* Block display text data.

* Use display text in SETUP/CONNECT messages for name.

* Use display text for COLP name updates (FACILITY/NOTIFY as appropriate).

* Pass arbitrary display text during a call.  Sent in INFORMATION
messages.  Received from any message that the display text was not used as
a name.

If the display options are not set then the options default to legacy
behavior.


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@2190 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2011-02-04 19:59:45 +00:00
Richard Mudgett
4b21faa82d Add pri_new_bri_cb() API - Create BRI D-channel with user defined I/O callbacks and data
There currently exists a pri_new_cb() API call that allows you to create a
PRI with user-defined I/O read and write callbacks, and option userdata.

Add the same capability for BRI interfaces by adding a pri_new_bri_cb()
API function.

(closes issue #16477)
Reported by: nic_bellamy
Patches:
      pri_new_bri_cb_api.patch uploaded by nic bellamy (license 299) (with minor cosmetic changes)


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1836 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-07-22 17:59:57 +00:00
David Vossel
660609c45b support for sending ETSI advice of charge
Review: https://reviewboard.asterisk.org/r/619/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1776 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-28 22:34:24 +00:00
Richard Mudgett
8c5eeeae79 ETSI Message Waiting Indication (MWI) support.
Add the ability to report waiting messages to ISDN endpoints (phones).

Relevant specification: EN 300 650 and EN 300 745

Review:	https://reviewboard.asterisk.org/r/600/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1767 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-28 21:50:14 +00:00
Richard Mudgett
0b28bf0aab ETSI Malicious Call ID support.
Add the ability to report malicious callers.

Relevant specification: EN 300 180

Review:	https://reviewboard.asterisk.org/r/575/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1757 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-28 20:26:23 +00:00
Richard Mudgett
e4b8bed7e9 ETSI Call Waiting support.
Add the ability to announce a call to an endpoint when there are no B
channels available.  A call waiting call is a SETUP message with no B
channel selected.

Relevant specification: EN 300 056, EN 300 057, EN 300 058

Review:	https://reviewboard.asterisk.org/r/569/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1746 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-28 18:43:57 +00:00
Richard Mudgett
9bb285fdc1 ETSI Advice Of Charge (AOC) event reporting.
This feature passes ETSI AOC-S, AOC-D, and AOC-E message information to
the upper layer (i.e.  Asterisk) for processing.

Relevant specification: EN 300 182

Consideration was made for the possible future addition of Q.SIG AOC
support (ECMA-212) with the events passed to the upper layer.

Review:	https://reviewboard.asterisk.org/r/538/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1737 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-28 18:03:38 +00:00
Richard Mudgett
382e7e5c86 Added ETSI Explicit Call Transfer (ECT) support.
Added ability to send and receive ETSI ECT messages to eliminate tromboned
calls.

Added ETSI support to an existing API call to send ECT messages when the
upper level indicates to transfer specified calls.

The libpri API was extended to indicate to the upper layer that the far
end requests the transfer of the indicated calls.

Review:	https://reviewboard.asterisk.org/r/521/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1723 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-28 15:19:08 +00:00
Richard Mudgett
6829faae06 Add Call Completion Suppplementary Service
Call Completion Supplementary Service (CCSS) added for the following 
switch types: ETSI PTMP, ETSI PTP, Q.SIG.  

Specifications:
ETS 300 359 CCBS for PTMP and PTP
ETS 301 065 CCNR for PTMP and PTP
ECMA-186 Call Completion for Q.SIG

Several support services were added to support CC:
Dummy Call Reference.
Q.931 REGISTER message.
Dynamic expansion of the number of available timers (up to 8192).
Enhanced facility message handling.

Current implementation limitations preclude the following:
CC service retention is not supported.
Q.SIG path reservation is not supported.

(closes issue #14292)
Reported by: tomaso
Tested by: rmudgett

JIRA SWP-1493

Review:	https://reviewboard.asterisk.org/r/522/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1714 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-26 16:01:10 +00:00
Richard Mudgett
d808143f8f Dialing an invalid extension causes incomplete hangup sequence.
Revision -r1489 corrected a deviation from Q.931 Section 5.3.2.  However,
this resulted in an unexpected behaviour change to the upper layer
(Asterisk).

This change restores the legacy hangup behaviour if the new API call is
not used.  Use pri_hangup_fix_enable() to follow Q.931 Section 5.3.2 call
hangup better.

(closes issue #17104)
Reported by: shawkris
Tested by: rmudgett


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1688 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-05-11 22:14:15 +00:00
Richard Mudgett
2ec071bae6 Minor comment changes.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1488 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2010-02-11 21:40:35 +00:00
Richard Mudgett
b698032e04 Reimplement callback mechanism to handle APDU response messages that we care about.
1) No sent messages will remain in the APDU queue unless they have an
active timer to remove them.  The dummy call reference call and global
call reference call structures will not act like a memory leak to sent
messages.

2) The new T-RESPONSE timer will be the generic response guard if the
standards do not otherwise specify a timer for a message response.

3) The callback will be called.  If it is called because of a response
message, then the callback has an opportunity to indicate if more
responses are expected.


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1322 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-11-14 00:20:53 +00:00
Richard Mudgett
62d35faf6b We now have 32 timers. No need to reserve minimum space anymore.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1316 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-11-13 23:46:57 +00:00
Richard Mudgett
e23ea9568c Add dummy call reference support.
Fixes problem where PTMP NT mode responds erroneously to a FACILITY
message from a phone on the dummy call reference.  LibPRI behaved as if
the dummy call reference were an invalid call reference and proceeded to
respond on the global call reference.


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1275 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-11-10 19:27:34 +00:00
Richard Mudgett
a2dcb6adba Add BRI PTMP NT mode, HOLD/RETRIEVE, Call rerouting/deflection, and keypad facility support.
* Added support for BRI PTMP NT mode.  (Overlap dialing NT -> TE not supported.)
* Added handling of received HOLD/RETRIEVE messages and the optional ability
  to transfer a held call on disconnect similar to an analog phone.
* Added CallRerouting/CallDeflection support for Q.SIG, ETSI PTP, ETSI PTMP.
  Will reroute/deflect an outgoing call when receive the message.
  Can use the DAHDISendCallreroutingFacility to send the message for the
  supported switches.
* Added ability to send/receive keypad digits in the SETUP message.
  Send keypad digits in SETUP message: Dial(DAHDI/g1[/K<keypad_digits>][/extension])
  Access any received keypad digits in SETUP message by: ${CHANNEL(keypad_digits)}

(closes issue #15048)
Tested by: rmudgett, mattf


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1242 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-10-23 19:50:45 +00:00
Richard Mudgett
a78ee730c9 Add support for calling and called subaddress. Partial support for COLP subaddress.
The Telecom Specs in NZ suggests that SUB ADDRESS is always on, so doing
"desk to desk" between offices each with an asterisk box over the ISDN
should then be possible, without a whole load of DDI numbers required.

(closes issue #15604)
Reported by: alecdavis
Patches:
      libpri_subaddr_trunk.diff11.txt uploaded by alecdavis (license 585)
      Some minor modificatons were made.
Tested by: alecdavis, rmudgett

Review:	https://reviewboard.asterisk.org/r/406/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1230 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-10-22 16:16:50 +00:00
Richard Mudgett
503ef0531a Make event channel parameter encoding consistent.
Also make sure that service maintenance messages have the channel id
parameters reinitialized for each message since they are sent over the
global call reference.


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1051 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-08-31 22:57:58 +00:00
Richard Mudgett
e7c9ecb1b2 Split justsignalling into cis_call and cis_auto_disconnect functionality.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@1042 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-08-31 17:24:19 +00:00
Richard Mudgett
dcd62e467f Add COLP support to libpri for ETSI PTP, ETSI PTMP, and Q.SIG.
Add Connected Line Presentation (COLP) support to chan_dahdi/libpri as an
addition to issue 8824.  This is the libpri portion.  COLP support is now
available for ETSI PTP, ETSI PTMP, and Q.SIG with this patch.

(closes issue #14068)
Tested by: rmudgett

Review: https://reviewboard.asterisk.org/r/339/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@982 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-08-18 23:53:32 +00:00
Richard Mudgett
4f0b3f3109 Doxygenify the timer comments.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@919 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-06-26 19:41:56 +00:00
Sean Bright
562e1fb7ca Add support for sending Reverse Charging Indication IE on ISDN PRI.
Add the ability to transmit a Reverse Charging Indication IE during a SETUP
message.  In passing, re-work some of the receive logic to be forwards
compatible with new RCI values that may be added in the future.  Also removed
the PRI_REVERSECHARGE_SUPPORT define that I added on the last commit since we
can just check for PRI_REVERSECHARGE_NONE or _REQUESTED on the Asterisk side to
determine support for this.

Special thanks to rmudgett who could have written this in half the time he spent
reviewing it, but instead talked me through it.  Much appreciated!

(issue #13760)
Reported by: mrgabu

Review: https://reviewboard.asterisk.org/r/292/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@907 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-06-25 18:53:38 +00:00
Richard Mudgett
c5cdc66b72 Convert PRI_TIMER_xxx to an enum so PRI_MAX_TIMERS can be automatically adjusted.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@901 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-06-25 17:35:23 +00:00
Richard Mudgett
2eaca806b9 Make it easier to add more timers/counters and vary the defaults based upon switchtype.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@894 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-06-24 21:45:04 +00:00
Sean Bright
7092459702 Capture and expose the Reverse Charging Indication IE on ISDN PRI.
(issue #13760)
Reported by: mrgabu
Patches:
      20090619_libpri_1.4.patch uploaded by seanbright (license 71)
Tested by: seanbright, pruonckk

Review: https://reviewboard.asterisk.org/r/291/


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@885 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-06-24 18:19:24 +00:00
Sean Bright
64fd25fcac Revert unintentional changes
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@879 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-06-23 23:15:56 +00:00
Sean Bright
16304b6a65 Set reviewboard property.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@878 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-06-23 23:15:04 +00:00
Kevin P. Fleming
39f7f72d8f Add 'const' qualifier to character string argument to keypad facility API calls
These API calls do not modify the string supplied, and should not be allowed to modify it, so this patch adds a 'const' qualifier to that argument to allow the compiler to enforce this restriction (and allow callers of the API that already have a 'const' pointer to be able to pass it to this API).



git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@798 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-05-13 15:17:08 +00:00
Richard Mudgett
ba45095c5a ROSE ASN.1 facility encode and decode rewrite of existing messages.
Several components are now parsed correctly.  Most notably:
PartyNumber and Q.SIG Name.


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@766 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-04-21 22:08:45 +00:00
Jeff Peeler
18fa4716a5 Add service maintenance message support
This adds support for two new message types: Service and Service Acknowledge.
When a channel receives a service message it will either take the channel in
or out of service and then send a service acknowledgment. Although not
enforced here (enforced in chan_dahdi), the service messages are only supported
with switch types 4ess/5ess. The required Asterisk changes will be coming next.

(issue #3450)
Reported by: cmaj


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@732 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-04-14 15:05:21 +00:00
Richard Mudgett
88551af7ef Comment changes to note what ISDN message type causes the event.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@715 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-03-26 16:01:45 +00:00
Leif Madsen
9ecdbed001 Fix a small spelling error.
(closes issue #14375)
Reported by: jeremy1

git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@687 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2009-02-02 20:18:03 +00:00
Matthew Fredrickson
e1bfec4b1e Merging in additional Q.SIG features in #13454. Includes Q.SIG physical/logical channel mapping support, extended coding of Q.SIG name operations (calling name), and call rerouting support via added dialplan application.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@636 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-10-17 16:13:42 +00:00
Kevin P. Fleming
64eaca5bfa Merged revisions 610 via svnmerge from
https://origsvn.digium.com/svn/libpri/branches/1.2

........
r610 | kpfleming | 2008-08-05 17:16:58 -0500 (Tue, 05 Aug 2008) | 2 lines

clean up license headers, and explicitly grant additional permissions when used with Asterisk

........


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@611 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-08-05 22:18:12 +00:00
Kevin P. Fleming
16df54e01a correct comments to match code
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@594 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-07-22 22:36:25 +00:00
Kevin P. Fleming
16719a5f74 rename API call and option (nothing has been released to use it yet so this should be safe) to be more accurate in describing what it does
(closes issue #13042)



git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@589 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-07-22 19:43:26 +00:00
Kevin P. Fleming
aad7c3e8f1 modify work done for issue #10552, making the support of inband audio after RELEASE a configurable option, since it is causing problems for a number of users
(closes issue #13042)


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@574 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-07-11 16:24:01 +00:00
Matthew Fredrickson
b9a6ab0c69 Moving trunk changes back into 1.4
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@557 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-05-07 19:51:44 +00:00
Brett Bryant
dee4c9ae0f Add new API call (pri_get_version) to show the current version of the branch for support purposes.
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@552 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-05-02 20:21:04 +00:00
Matthew Fredrickson
160be09f76 Improve transmission, receiving, and dumping of bearer capability IE (#11593)
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@524 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2008-02-18 20:31:38 +00:00
Jason Parker
595154da5a Fix an incorrect pri_event structure definition.
Issue 10832, patch by flefoll


git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@470 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2007-10-05 16:45:39 +00:00
Matthew Fredrickson
2a27c0f173 Fix for #10189. Make sure we properly report the user layer 1 for H.223 and H.245
git-svn-id: https://origsvn.digium.com/svn/libpri/branches/1.4@465 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2007-09-14 21:32:54 +00:00
Matthew Fredrickson
ed9c90a985 Make sure we pass the call back in setup_ack
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@328 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2006-04-27 16:09:11 +00:00
Matthew Fredrickson
e2091c29ef Cause code clarifications (Q.SIG versus non Q.SIG)
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@317 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2006-02-17 21:19:37 +00:00
Russell Bryant
9c8628715f change 'char *' to 'const char *' for useruserinfo to go along with the fixes
from r7327 in the asterisk trunk


git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@277 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2005-12-04 15:32:46 +00:00
Matthew Fredrickson
dd611af000 Modify the warning #define
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@272 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2005-12-01 18:06:20 +00:00
Matthew Fredrickson
8d6d58ab09 Add in keypad facility transmission support
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@271 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2005-12-01 17:59:56 +00:00
Kevin P. Fleming
cf8c723f8b remove extraneous svn:executable properties
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@266 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2005-11-29 18:39:18 +00:00
Matthew Fredrickson
89384a8472 Add protection block
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@254 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2005-10-21 21:21:22 +00:00
Matthew Fredrickson
e0de929e20 Updates so that one can do user to user IE transmission
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@253 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2005-10-21 20:20:22 +00:00
Mark Spencer
cfee7ff007 Add ability to restart PRI at Q.921 layer
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@247 2fbb986a-6c06-0410-b554-c9c1f0a7f128
2005-09-13 02:19:00 +00:00