Commit Graph

1507 Commits

Author SHA1 Message Date
Harald Welte 3701992c74 ISUP: support transfer capability interworking with Q.931
A Q.931 call has the 'transfer-cap' attribute set to 'udi' for data
calls.  The ISUP module must pick this up and encode it in the
UseServiceInformation IE to preserve this vital information.  Inversely,
a call arriving via ISUP must put its transfer-capability into the
'transfer-cap' attribute, so that when it's routed to Q.931 it is
preserved.

Without this transfer-capability transparency, no UDI/RDI data calls
or ISDN video calls can transition on the Q931/ISUP boundary

See also https://github.com/yatevoip/yate/issues/12
2023-12-03 16:19:41 +01:00
Harald Welte 498dc6bcc7 processCalledNo: Fix typo / copy+paste error
Surely, the treatment of the *called* party type/plan should
not depend on the *calling* party type/plan.
2023-12-03 11:41:46 +01:00
Manawyrm 6fa07fb632 Add new clearmode codec support for data calls
This new codec will get handled like RFC4040 in yrtpchan, ysipchan
and will just be handled as alaw audio in zapcard/DAHDI.

The zapcard code will set the udi bearer cap to any calls with the
clearmode format (which would get sent via SIP/SDP).
2023-09-19 18:29:40 +02:00
Manawyrm 9ac675d324 miniwebrtc: add aarch64 support
miniwebrtc fails to compile on aarch64/arm64 because the architecture isn't known
this change adds the required configuration for arm64
2023-09-19 18:29:40 +02:00
Harald Welte 1bad0f5194 q931: If we're the network, channelID in ALERTING/CALL_PROC/CONNECT is mandatory
The user may suggest a given channel in the SETUP, but it's not legal
for the network to return a non-mandatory ChannelID.

See Q.931 Section 5.1.2 (B-channel selection - Originating):

The selected B-channel is indicated in the Channel identification information
element coded as "channel is indicated, no acceptable alternative" in the first
message returned by the network in response to the SETUP message (i.e. a SETUP
ACKNOWLEDGE or CALL PROCEEDING message)

In an earlier commit I had only fixed SETUP ACK, but missed that this is
a more general problem that needs addressing in whatever is the first
message containing a channelID yate sends in response to the SETUP.
2023-09-19 18:29:40 +02:00
Harald Welte 071d635fc6 iax: ENCRYPTION IE is 2 bytes, not 1 byte
yiax wrongly assumed that the ENCRYPTION IE is a single byte,
while in reality it is 16bit / 2 bytes.

It has been two bytes ever since it was introduced in Asterisk in 2004.

This misunderstanding probably arose from RFC5456 which erroneosly
states that the length of this IE is 0x01 while its body is 2 bytes
long (See Section 8.6.34 at https://datatracker.ietf.org/doc/html/rfc5456)
2023-09-19 18:29:40 +02:00
Harald Welte d313646712 iax: Support the new CALLINGANI2 IE
This was introduced in Asterisk IAX2 in
3072c540bb
2023-09-19 18:29:40 +02:00
Harald Welte f727a1dd3a q931: If we're the network, channelID in SETUP ACK is mandatory
The user may suggest a given channel in the SETUP, but it's not legal
for the network to return a non-mandatory ChannelID.

See Q.931 Section 5.1.2 (B-channel selection - Originating):

The selected B-channel is indicated in the Channel identification information
element coded as "channel is indicated, no acceptable alternative" in the first
message returned by the network in response to the SETUP message (i.e. a SETUP
ACKNOWLEDGE or CALL PROCEEDING message)
2023-09-19 18:29:40 +02:00
Harald Welte 3020ff51ed preserve transfer-capability in Q.931 -> Q.931 calls
This is important so udi/rdi doesn't get converted to speech.
2023-09-19 18:29:40 +02:00
Harald Welte 6f336a336a q931: sendSetupAck: Don't encode a BRI channel selection in PRI
If yate is operating in the 'network' role of a PRI interface,
it must send a valid ChannelID InformationElement in the SETUP ACK.

However, current yate code is encoding the channel selection field
of said information element wrong, as it unconditionally looks up
the s_dict_channelIDSelect_BRI (instead of _PRI).

This fixes a regression introduced in 2009 in the following commit:

commit 05b717e0b9
Author: paulc <paulc@acf43c95-373e-0410-b603-e72c3f656dc1>
Date:   Mon Mar 2 18:51:30 2009 +0000

ISDN BRI support, most Andrei's (andrei@null.ro) work.
Fixes and new features throughout the signalling engine.
it-svn-id: http://yate.null.ro/svn/yate/trunk@2505 acf43c95-373e-0410-b603-e72c3f656dc1
2023-09-19 18:29:40 +02:00
marian 7ca0164860 Moved formats changed debug message to a lower level. 2023-05-26 16:46:25 +03:00
marian c45f3a0345 Set debug enabler in SDP media.
Lowered debug level for media debug messages.
2023-05-26 15:28:49 +03:00
Ioana Stanciu c56216f5a8 Updated copyright notices. 2023-05-23 17:01:06 +03:00
Ioana Stanciu afc46246ca Import commercial version of YATE SIP and SDP implementation. 2023-05-23 15:16:31 +03:00
marian 3436092371 Added javascript support for callback function set when a message is enqueued by a script. Call the function after message was dispatched. 2023-03-15 16:58:21 +02:00
marian acdc469d00 Added deep copy support in Object::assignProps().
Added ExpOperVector class and JsObject support to extract stack arguments into it.
2023-03-06 13:07:02 +02:00
Ioana Stanciu ca129ad5ba Import SVN ignore propgs to git. 2023-02-17 16:53:39 +02:00
marian ac82b37198 Silenced compiler warning related to sprintf() usage.
git-svn-id: http://voip.null.ro/svn/yate@6566 acf43c95-373e-0410-b603-e72c3f656dc1
2022-10-11 08:13:58 +00:00
marian a774d99471 Silenced compiler warning.
git-svn-id: http://voip.null.ro/svn/yate@6561 acf43c95-373e-0410-b603-e72c3f656dc1
2022-06-27 06:36:36 +00:00
marian a494ca67a5 Added support for javascript Object.assign() method. Added method Object.assignProps(): copy properties using filter, may alter property names.
git-svn-id: http://voip.null.ro/svn/yate@6560 acf43c95-373e-0410-b603-e72c3f656dc1
2022-06-27 06:32:57 +00:00
marian 0a180e5fea Fixed bug: check pointer when initializing route parameters. Route parameters may be missing leading to segfault.
git-svn-id: http://voip.null.ro/svn/yate@6555 acf43c95-373e-0410-b603-e72c3f656dc1
2022-05-26 07:30:20 +00:00
oana 23327197a9 Fix documentation comments for a couple of methods.
git-svn-id: http://voip.null.ro/svn/yate@6551 acf43c95-373e-0410-b603-e72c3f656dc1
2022-03-08 12:05:27 +00:00
oana 94a2b7ce80 Add support for building and running multiple instances of the same script.
git-svn-id: http://voip.null.ro/svn/yate@6542 acf43c95-373e-0410-b603-e72c3f656dc1
2022-02-09 10:59:28 +00:00
marian 0196d2b8df Added array method used to push strings from list.
git-svn-id: http://voip.null.ro/svn/yate@6536 acf43c95-373e-0410-b603-e72c3f656dc1
2022-01-11 09:02:27 +00:00
marian 049f82dd2a Fixed JSON reference resolve string comparison bug revealed by new compiler.
git-svn-id: http://voip.null.ro/svn/yate@6528 acf43c95-373e-0410-b603-e72c3f656dc1
2021-11-25 18:02:25 +00:00
marian d36a8dddaf Fixed JSON replaceReferences bug: check if object was already found when no replacements are done in it. Improved debug.
git-svn-id: http://voip.null.ro/svn/yate@6526 acf43c95-373e-0410-b603-e72c3f656dc1
2021-10-27 12:43:59 +00:00
marian 27ba8dfbec Added support for JSON Path (find value in object by path). Fixed JSON.stringify(): avoid crashing on circular references, replace already found objects by their path reference. Report path in Engine.dump_r for already found objects.
git-svn-id: http://voip.null.ro/svn/yate@6525 acf43c95-373e-0410-b603-e72c3f656dc1
2021-10-27 10:22:53 +00:00
paulc 1972768171 Changed priority of the JS specific operators.
Fixes problems introduced by Rev. 6511


git-svn-id: http://voip.null.ro/svn/yate@6515 acf43c95-373e-0410-b603-e72c3f656dc1
2021-08-16 10:52:48 +00:00
paulc 5df80ff38a Added missing precedence of the nullish operator.
Aligned operators precedence with JS.


git-svn-id: http://voip.null.ro/svn/yate@6511 acf43c95-373e-0410-b603-e72c3f656dc1
2021-08-11 10:52:33 +00:00
marian 8f31d10b7c Improved debug.
git-svn-id: http://voip.null.ro/svn/yate@6509 acf43c95-373e-0410-b603-e72c3f656dc1
2021-08-04 07:35:53 +00:00
paulc d15456b72d Implemented the nullish concatenation and assignment operators.
Implemented the missing logical operation plus assignment.


git-svn-id: http://voip.null.ro/svn/yate@6504 acf43c95-373e-0410-b603-e72c3f656dc1
2021-07-08 14:53:44 +00:00
paulc f3a35a7e32 Be systemmatic in adding the Param_ prefix to unknown parameters.
git-svn-id: http://voip.null.ro/svn/yate@6503 acf43c95-373e-0410-b603-e72c3f656dc1
2021-07-06 11:54:01 +00:00
marian d2400f608a Fixed bug: put alaw/mulaw in rtpmap dictionary start for proper matching when parsing receivd SDP.
git-svn-id: http://voip.null.ro/svn/yate@6484 acf43c95-373e-0410-b603-e72c3f656dc1
2021-04-19 11:46:57 +00:00
marian 98e943c8b8 Added SDP support for stereo slin/alaw/mulaw.
git-svn-id: http://voip.null.ro/svn/yate@6483 acf43c95-373e-0410-b603-e72c3f656dc1
2021-04-19 10:02:58 +00:00
paulc e7fd449134 Add the "name" property to functions.
git-svn-id: http://voip.null.ro/svn/yate@6480 acf43c95-373e-0410-b603-e72c3f656dc1
2021-04-16 13:03:57 +00:00
paulc 41c654cc3f Added Object.global() to access the script's global object.
Write numbers to JSON using their internal string representation.


git-svn-id: http://voip.null.ro/svn/yate@6478 acf43c95-373e-0410-b603-e72c3f656dc1
2021-04-16 09:57:46 +00:00
oana f0b7849ee1 Clone a JsFunction when first assigned into another variable.
git-svn-id: http://voip.null.ro/svn/yate@6477 acf43c95-373e-0410-b603-e72c3f656dc1
2021-04-12 08:55:18 +00:00
paulc 3fc1647112 Made behavior of Math abs, min and max more consistent with the standard.
git-svn-id: http://voip.null.ro/svn/yate@6471 acf43c95-373e-0410-b603-e72c3f656dc1
2021-03-29 10:34:12 +00:00
paulc 8cbdd26b7f Added support for retrieving the call stack and the call context.
git-svn-id: http://voip.null.ro/svn/yate@6469 acf43c95-373e-0410-b603-e72c3f656dc1
2021-03-26 12:17:41 +00:00
oana 3208dc161f Add optional name parameter to ExpWrapper constructor.
git-svn-id: http://voip.null.ro/svn/yate@6468 acf43c95-373e-0410-b603-e72c3f656dc1
2021-03-26 12:01:58 +00:00
oana de4c2dd695 Fix Object.keys() evaluation on object of type Message of Engine.Hashlist: use the object list of field names when possible.
git-svn-id: http://voip.null.ro/svn/yate@6467 acf43c95-373e-0410-b603-e72c3f656dc1
2021-03-19 14:20:48 +00:00
marian b9612d8f4b Avoid crash in javascript array concat() called for array(s) with holes (missing indexes).
git-svn-id: http://voip.null.ro/svn/yate@6463 acf43c95-373e-0410-b603-e72c3f656dc1
2021-03-03 13:59:52 +00:00
paulc 8efa8d07cd Fixed several issues exposed by the Microsoft compiler.
git-svn-id: http://voip.null.ro/svn/yate@6459 acf43c95-373e-0410-b603-e72c3f656dc1
2021-02-09 14:08:19 +00:00
paulc f50a2ee152 Do not reset RTP timestamp offset after a sequence resync.
git-svn-id: http://voip.null.ro/svn/yate@6458 acf43c95-373e-0410-b603-e72c3f656dc1
2021-01-28 13:38:55 +00:00
oana 96a070a8f5 Fix issue introduced by commit 6442: make ExpNull::copy() method to have the same signature as the one from ExpWrapper in order to override it.
git-svn-id: http://voip.null.ro/svn/yate@6455 acf43c95-373e-0410-b603-e72c3f656dc1
2020-11-20 16:02:02 +00:00
oana 6c73b96287 Add hashing functions for uint32, uint64 and pointer types.
Use pointer hashing function in accessing list that tracks JS objects.



git-svn-id: http://voip.null.ro/svn/yate@6448 acf43c95-373e-0410-b603-e72c3f656dc1
2020-10-30 13:56:33 +00:00
oana 8b0aab86a8 Protect access to object tracking list of the script execution context.
Some objects are created outside of the context.



git-svn-id: http://voip.null.ro/svn/yate@6447 acf43c95-373e-0410-b603-e72c3f656dc1
2020-10-29 16:28:49 +00:00
oana 604e18f539 Bug fix: do not increase code line number when parsing '\n' from a string literal.
git-svn-id: http://voip.null.ro/svn/yate@6446 acf43c95-373e-0410-b603-e72c3f656dc1
2020-10-29 14:46:07 +00:00
oana 046cb195e9 Fix code line counting when parsing multi-line string.
git-svn-id: http://voip.null.ro/svn/yate@6444 acf43c95-373e-0410-b603-e72c3f656dc1
2020-10-23 08:11:53 +00:00
oana 83ef49437f Add tracking for Javascript object creation and destruction.
Add command that reports how many objects are still alive that have been created at the reported code line.
Fix constructor for ConfigFile.



git-svn-id: http://voip.null.ro/svn/yate@6442 acf43c95-373e-0410-b603-e72c3f656dc1
2020-10-21 11:01:31 +00:00