@voicenter-team/opensips-js 1.0.133 → 1.0.134
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/opensips-js.cjs.js +36 -36
- package/dist/opensips-js.es.js +601 -592
- package/dist/opensips-js.iife.js +23 -23
- package/dist/opensips-js.umd.js +23 -23
- package/package.json +1 -1
package/dist/opensips-js.es.js
CHANGED
@@ -484,8 +484,8 @@ function os() {
|
|
484
484
|
DIGIT: T,
|
485
485
|
ALPHA: E,
|
486
486
|
HEXDIG: y,
|
487
|
-
WSP:
|
488
|
-
OCTET:
|
487
|
+
WSP: C,
|
488
|
+
OCTET: A,
|
489
489
|
DQUOTE: I,
|
490
490
|
SP: H,
|
491
491
|
HTAB: $,
|
@@ -512,13 +512,13 @@ function os() {
|
|
512
512
|
LPAREN: ge,
|
513
513
|
RPAREN: be,
|
514
514
|
RAQUOT: xe,
|
515
|
-
LAQUOT:
|
515
|
+
LAQUOT: Ae,
|
516
516
|
COMMA: le,
|
517
517
|
SEMI: ye,
|
518
518
|
COLON: nt,
|
519
519
|
LDQUOT: at,
|
520
520
|
RDQUOT: Ee,
|
521
|
-
comment:
|
521
|
+
comment: Ce,
|
522
522
|
ctext: Ie,
|
523
523
|
quoted_string: Oe,
|
524
524
|
quoted_string_clean: pe,
|
@@ -543,14 +543,14 @@ function os() {
|
|
543
543
|
h16: ae,
|
544
544
|
ls32: ot,
|
545
545
|
IPv4address: Wt,
|
546
|
-
dec_octet:
|
546
|
+
dec_octet: As,
|
547
547
|
port: Er,
|
548
548
|
uri_parameters: Un,
|
549
549
|
uri_parameter: Pn,
|
550
550
|
transport_param: Sr,
|
551
551
|
user_param: yr,
|
552
|
-
method_param:
|
553
|
-
ttl_param:
|
552
|
+
method_param: Cr,
|
553
|
+
ttl_param: Ar,
|
554
554
|
maddr_param: Rr,
|
555
555
|
lr_param: Ir,
|
556
556
|
other_param: br,
|
@@ -625,8 +625,8 @@ function os() {
|
|
625
625
|
x_token: Zr,
|
626
626
|
m_subtype: qn,
|
627
627
|
m_parameter: Vn,
|
628
|
-
m_value:
|
629
|
-
CSeq:
|
628
|
+
m_value: Cl,
|
629
|
+
CSeq: Al,
|
630
630
|
CSeq_value: Rl,
|
631
631
|
Expires: Qa,
|
632
632
|
Event: on,
|
@@ -683,9 +683,9 @@ function os() {
|
|
683
683
|
protocol_name: Ei,
|
684
684
|
transport: Si,
|
685
685
|
sent_by: yi,
|
686
|
-
via_host:
|
686
|
+
via_host: Ci,
|
687
687
|
via_port: tr,
|
688
|
-
ttl:
|
688
|
+
ttl: Ai,
|
689
689
|
WWW_Authenticate: lo,
|
690
690
|
Session_Expires: Ol,
|
691
691
|
s_e_expires: sr,
|
@@ -734,11 +734,11 @@ function os() {
|
|
734
734
|
var e;
|
735
735
|
return /^[0-9a-fA-F]/.test(a.charAt(r)) ? (e = a.charAt(r), r++) : (e = null, _("[0-9a-fA-F]")), e;
|
736
736
|
}
|
737
|
-
function
|
737
|
+
function C() {
|
738
738
|
var e;
|
739
739
|
return e = H(), e === null && (e = $()), e;
|
740
740
|
}
|
741
|
-
function
|
741
|
+
function A() {
|
742
742
|
var e;
|
743
743
|
return /^[\0-\xFF]/.test(a.charAt(r)) ? (e = a.charAt(r), r++) : (e = null, _("[\\0-\\xFF]")), e;
|
744
744
|
}
|
@@ -778,12 +778,12 @@ function os() {
|
|
778
778
|
}
|
779
779
|
function k() {
|
780
780
|
var e, l, u, f, p, m;
|
781
|
-
for (f = r, p = r, m = r, e = [], l =
|
782
|
-
e.push(l), l =
|
781
|
+
for (f = r, p = r, m = r, e = [], l = C(); l !== null; )
|
782
|
+
e.push(l), l = C();
|
783
783
|
if (e !== null ? (l = g(), l !== null ? e = [e, l] : (e = null, r = m)) : (e = null, r = m), e = e !== null ? e : "", e !== null) {
|
784
|
-
if (u =
|
784
|
+
if (u = C(), u !== null)
|
785
785
|
for (l = []; u !== null; )
|
786
|
-
l.push(u), u =
|
786
|
+
l.push(u), u = C();
|
787
787
|
else
|
788
788
|
l = null;
|
789
789
|
l !== null ? e = [e, l] : (e = null, r = p);
|
@@ -916,7 +916,7 @@ function os() {
|
|
916
916
|
return ">";
|
917
917
|
}()), e === null && (r = u), e;
|
918
918
|
}
|
919
|
-
function
|
919
|
+
function Ae() {
|
920
920
|
var e, l, u, f;
|
921
921
|
return u = r, f = r, e = D(), e !== null ? (a.charCodeAt(r) === 60 ? (l = "<", r++) : (l = null, _('"<"')), l !== null ? e = [e, l] : (e = null, r = f)) : (e = null, r = f), e !== null && (e = function(p) {
|
922
922
|
return "<";
|
@@ -952,11 +952,11 @@ function os() {
|
|
952
952
|
return '"';
|
953
953
|
}()), e === null && (r = u), e;
|
954
954
|
}
|
955
|
-
function
|
955
|
+
function Ce() {
|
956
956
|
var e, l, u, f;
|
957
957
|
if (f = r, e = ge(), e !== null) {
|
958
|
-
for (l = [], u = Ie(), u === null && (u = _e(), u === null && (u =
|
959
|
-
l.push(u), u = Ie(), u === null && (u = _e(), u === null && (u =
|
958
|
+
for (l = [], u = Ie(), u === null && (u = _e(), u === null && (u = Ce())); u !== null; )
|
959
|
+
l.push(u), u = Ie(), u === null && (u = _e(), u === null && (u = Ce()));
|
960
960
|
l !== null ? (u = be(), u !== null ? e = [e, l, u] : (e = null, r = f)) : (e = null, r = f);
|
961
961
|
} else
|
962
962
|
e = null, r = f;
|
@@ -1128,11 +1128,11 @@ function os() {
|
|
1128
1128
|
}
|
1129
1129
|
function Wt() {
|
1130
1130
|
var e, l, u, f, p, m, v, S, O;
|
1131
|
-
return S = r, O = r, e =
|
1131
|
+
return S = r, O = r, e = As(), e !== null ? (a.charCodeAt(r) === 46 ? (l = ".", r++) : (l = null, _('"."')), l !== null ? (u = As(), u !== null ? (a.charCodeAt(r) === 46 ? (f = ".", r++) : (f = null, _('"."')), f !== null ? (p = As(), p !== null ? (a.charCodeAt(r) === 46 ? (m = ".", r++) : (m = null, _('"."')), m !== null ? (v = As(), v !== null ? e = [e, l, u, f, p, m, v] : (e = null, r = O)) : (e = null, r = O)) : (e = null, r = O)) : (e = null, r = O)) : (e = null, r = O)) : (e = null, r = O)) : (e = null, r = O), e !== null && (e = function(ie) {
|
1132
1132
|
return w.host_type = "IPv4", a.substring(r, ie);
|
1133
1133
|
}(S)), e === null && (r = S), e;
|
1134
1134
|
}
|
1135
|
-
function
|
1135
|
+
function As() {
|
1136
1136
|
var e, l, u, f;
|
1137
1137
|
return f = r, a.substr(r, 2) === "25" ? (e = "25", r += 2) : (e = null, _('"25"')), e !== null ? (/^[0-5]/.test(a.charAt(r)) ? (l = a.charAt(r), r++) : (l = null, _("[0-5]")), l !== null ? e = [e, l] : (e = null, r = f)) : (e = null, r = f), e === null && (f = r, a.charCodeAt(r) === 50 ? (e = "2", r++) : (e = null, _('"2"')), e !== null ? (/^[0-4]/.test(a.charAt(r)) ? (l = a.charAt(r), r++) : (l = null, _("[0-4]")), l !== null ? (u = T(), u !== null ? e = [e, l, u] : (e = null, r = f)) : (e = null, r = f)) : (e = null, r = f), e === null && (f = r, a.charCodeAt(r) === 49 ? (e = "1", r++) : (e = null, _('"1"')), e !== null ? (l = T(), l !== null ? (u = T(), u !== null ? e = [e, l, u] : (e = null, r = f)) : (e = null, r = f)) : (e = null, r = f), e === null && (f = r, /^[1-9]/.test(a.charAt(r)) ? (e = a.charAt(r), r++) : (e = null, _("[1-9]")), e !== null ? (l = T(), l !== null ? e = [e, l] : (e = null, r = f)) : (e = null, r = f), e === null && (e = T())))), e;
|
1138
1138
|
}
|
@@ -1150,7 +1150,7 @@ function os() {
|
|
1150
1150
|
}
|
1151
1151
|
function Pn() {
|
1152
1152
|
var e;
|
1153
|
-
return e = Sr(), e === null && (e = yr(), e === null && (e =
|
1153
|
+
return e = Sr(), e === null && (e = yr(), e === null && (e = Cr(), e === null && (e = Ar(), e === null && (e = Rr(), e === null && (e = Ir(), e === null && (e = br())))))), e;
|
1154
1154
|
}
|
1155
1155
|
function Sr() {
|
1156
1156
|
var e, l, u, f;
|
@@ -1164,15 +1164,15 @@ function os() {
|
|
1164
1164
|
w.uri_params || (w.uri_params = {}), w.uri_params.user = m.toLowerCase();
|
1165
1165
|
}(u, e[1])), e === null && (r = u), e;
|
1166
1166
|
}
|
1167
|
-
function
|
1167
|
+
function Cr() {
|
1168
1168
|
var e, l, u, f;
|
1169
1169
|
return u = r, f = r, a.substr(r, 7).toLowerCase() === "method=" ? (e = a.substr(r, 7), r += 7) : (e = null, _('"method="')), e !== null ? (l = rn(), l !== null ? e = [e, l] : (e = null, r = f)) : (e = null, r = f), e !== null && (e = function(p, m) {
|
1170
1170
|
w.uri_params || (w.uri_params = {}), w.uri_params.method = m;
|
1171
1171
|
}(u, e[1])), e === null && (r = u), e;
|
1172
1172
|
}
|
1173
|
-
function
|
1173
|
+
function Ar() {
|
1174
1174
|
var e, l, u, f;
|
1175
|
-
return u = r, f = r, a.substr(r, 4).toLowerCase() === "ttl=" ? (e = a.substr(r, 4), r += 4) : (e = null, _('"ttl="')), e !== null ? (l =
|
1175
|
+
return u = r, f = r, a.substr(r, 4).toLowerCase() === "ttl=" ? (e = a.substr(r, 4), r += 4) : (e = null, _('"ttl="')), e !== null ? (l = Ai(), l !== null ? e = [e, l] : (e = null, r = f)) : (e = null, r = f), e !== null && (e = function(p, m) {
|
1176
1176
|
w.params || (w.params = {}), w.params.ttl = m;
|
1177
1177
|
}(u, e[1])), e === null && (r = u), e;
|
1178
1178
|
}
|
@@ -1528,7 +1528,7 @@ function os() {
|
|
1528
1528
|
}
|
1529
1529
|
function Ht() {
|
1530
1530
|
var e, l, u, f, p;
|
1531
|
-
return p = r, e = Us(), e = e !== null ? e : "", e !== null ? (l =
|
1531
|
+
return p = r, e = Us(), e = e !== null ? e : "", e !== null ? (l = Ae(), l !== null ? (u = Ne(), u !== null ? (f = xe(), f !== null ? e = [e, l, u, f] : (e = null, r = p)) : (e = null, r = p)) : (e = null, r = p)) : (e = null, r = p), e;
|
1532
1532
|
}
|
1533
1533
|
function Us() {
|
1534
1534
|
var e, l, u, f, p, m, v;
|
@@ -1678,13 +1678,13 @@ function os() {
|
|
1678
1678
|
}
|
1679
1679
|
function Vn() {
|
1680
1680
|
var e, l, u, f;
|
1681
|
-
return f = r, e = P(), e !== null ? (l = re(), l !== null ? (u =
|
1681
|
+
return f = r, e = P(), e !== null ? (l = re(), l !== null ? (u = Cl(), u !== null ? e = [e, l, u] : (e = null, r = f)) : (e = null, r = f)) : (e = null, r = f), e;
|
1682
1682
|
}
|
1683
|
-
function
|
1683
|
+
function Cl() {
|
1684
1684
|
var e;
|
1685
1685
|
return e = P(), e === null && (e = Oe()), e;
|
1686
1686
|
}
|
1687
|
-
function
|
1687
|
+
function Al() {
|
1688
1688
|
var e, l, u, f;
|
1689
1689
|
return f = r, e = Rl(), e !== null ? (l = k(), l !== null ? (u = rn(), u !== null ? e = [e, l, u] : (e = null, r = f)) : (e = null, r = f)) : (e = null, r = f), e;
|
1690
1690
|
}
|
@@ -1776,7 +1776,7 @@ function os() {
|
|
1776
1776
|
for (S = r, O = r, e = [], l = Us(); l !== null; )
|
1777
1777
|
e.push(l), l = Us();
|
1778
1778
|
if (e !== null)
|
1779
|
-
if (l =
|
1779
|
+
if (l = Ae(), l !== null)
|
1780
1780
|
if (u = Ne(), u !== null)
|
1781
1781
|
if (f = xe(), f !== null) {
|
1782
1782
|
for (p = [], ie = r, m = ye(), m !== null ? (v = We(), v !== null ? m = [m, v] : (m = null, r = ie)) : (m = null, r = ie); m !== null; )
|
@@ -2157,7 +2157,7 @@ function os() {
|
|
2157
2157
|
}
|
2158
2158
|
function di() {
|
2159
2159
|
var e, l, u, f, p;
|
2160
|
-
return f = r, p = r, a.substr(r, 3).toLowerCase() === "ttl" ? (e = a.substr(r, 3), r += 3) : (e = null, _('"ttl"')), e !== null ? (l = re(), l !== null ? (u =
|
2160
|
+
return f = r, p = r, a.substr(r, 3).toLowerCase() === "ttl" ? (e = a.substr(r, 3), r += 3) : (e = null, _('"ttl"')), e !== null ? (l = re(), l !== null ? (u = Ai(), u !== null ? e = [e, l, u] : (e = null, r = p)) : (e = null, r = p)) : (e = null, r = p), e !== null && (e = function(m, v) {
|
2161
2161
|
w.ttl = v;
|
2162
2162
|
}(f, e[2])), e === null && (r = f), e;
|
2163
2163
|
}
|
@@ -2207,9 +2207,9 @@ function os() {
|
|
2207
2207
|
}
|
2208
2208
|
function yi() {
|
2209
2209
|
var e, l, u, f, p;
|
2210
|
-
return f = r, e =
|
2210
|
+
return f = r, e = Ci(), e !== null ? (p = r, l = nt(), l !== null ? (u = tr(), u !== null ? l = [l, u] : (l = null, r = p)) : (l = null, r = p), l = l !== null ? l : "", l !== null ? e = [e, l] : (e = null, r = f)) : (e = null, r = f), e;
|
2211
2211
|
}
|
2212
|
-
function
|
2212
|
+
function Ci() {
|
2213
2213
|
var e, l;
|
2214
2214
|
return l = r, e = Wt(), e === null && (e = zs(), e === null && (e = Js())), e !== null && (e = function(u) {
|
2215
2215
|
w.host = a.substring(r, u);
|
@@ -2221,7 +2221,7 @@ function os() {
|
|
2221
2221
|
w.port = parseInt(O.join(""));
|
2222
2222
|
}(m, e)), e === null && (r = m), e;
|
2223
2223
|
}
|
2224
|
-
function
|
2224
|
+
function Ai() {
|
2225
2225
|
var e, l, u, f, p;
|
2226
2226
|
return f = r, p = r, e = T(), e !== null ? (l = T(), l = l !== null ? l : "", l !== null ? (u = T(), u = u !== null ? u : "", u !== null ? e = [e, l, u] : (e = null, r = p)) : (e = null, r = p)) : (e = null, r = p), e !== null && (e = function(m, v) {
|
2227
2227
|
return parseInt(v.join(""));
|
@@ -2269,8 +2269,8 @@ function os() {
|
|
2269
2269
|
}
|
2270
2270
|
function ao() {
|
2271
2271
|
var e, l;
|
2272
|
-
for (e = [], l =
|
2273
|
-
e.push(l), l =
|
2272
|
+
for (e = [], l = A(); l !== null; )
|
2273
|
+
e.push(l), l = A();
|
2274
2274
|
return e;
|
2275
2275
|
}
|
2276
2276
|
function Pl() {
|
@@ -2418,19 +2418,19 @@ function Ks() {
|
|
2418
2418
|
throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
2419
2419
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
2420
2420
|
}
|
2421
|
-
var
|
2421
|
+
var C = !0, A = !1, I;
|
2422
2422
|
return { s: function() {
|
2423
2423
|
T = _[Symbol.iterator]();
|
2424
2424
|
}, n: function() {
|
2425
2425
|
var $ = T.next();
|
2426
|
-
return
|
2426
|
+
return C = $.done, $;
|
2427
2427
|
}, e: function($) {
|
2428
|
-
|
2428
|
+
A = !0, I = $;
|
2429
2429
|
}, f: function() {
|
2430
2430
|
try {
|
2431
|
-
!
|
2431
|
+
!C && T.return != null && T.return();
|
2432
2432
|
} finally {
|
2433
|
-
if (
|
2433
|
+
if (A)
|
2434
2434
|
throw I;
|
2435
2435
|
}
|
2436
2436
|
} };
|
@@ -2479,14 +2479,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2479
2479
|
}
|
2480
2480
|
}]);
|
2481
2481
|
function _(g, T, E, y) {
|
2482
|
-
var
|
2482
|
+
var C = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : {}, A = arguments.length > 5 && arguments[5] !== void 0 ? arguments[5] : {};
|
2483
2483
|
if (a(this, _), !E)
|
2484
2484
|
throw new TypeError('missing or invalid "host" parameter');
|
2485
2485
|
this._parameters = {}, this._headers = {}, this._scheme = g || r.SIP, this._user = T, this._host = E, this._port = y;
|
2486
|
-
for (var I in
|
2487
|
-
Object.prototype.hasOwnProperty.call(
|
2488
|
-
for (var H in
|
2489
|
-
Object.prototype.hasOwnProperty.call(
|
2486
|
+
for (var I in C)
|
2487
|
+
Object.prototype.hasOwnProperty.call(C, I) && this.setParam(I, C[I]);
|
2488
|
+
for (var H in A)
|
2489
|
+
Object.prototype.hasOwnProperty.call(A, H) && this.setHeader(H, A[H]);
|
2490
2490
|
}
|
2491
2491
|
return s(_, [{
|
2492
2492
|
key: "setParam",
|
@@ -2560,18 +2560,18 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2560
2560
|
this._user && (E += "".concat(d.escapeUser(this._user), "@")), E += this._host, (this._port || this._port === 0) && (E += ":".concat(this._port));
|
2561
2561
|
for (var y in this._parameters)
|
2562
2562
|
Object.prototype.hasOwnProperty.call(this._parameters, y) && (E += ";".concat(y), this._parameters[y] !== null && (E += "=".concat(this._parameters[y])));
|
2563
|
-
for (var
|
2564
|
-
if (Object.prototype.hasOwnProperty.call(this._headers,
|
2565
|
-
var
|
2563
|
+
for (var C in this._headers)
|
2564
|
+
if (Object.prototype.hasOwnProperty.call(this._headers, C)) {
|
2565
|
+
var A = c(this._headers[C]), I;
|
2566
2566
|
try {
|
2567
|
-
for (
|
2567
|
+
for (A.s(); !(I = A.n()).done; ) {
|
2568
2568
|
var H = I.value;
|
2569
|
-
T.push("".concat(
|
2569
|
+
T.push("".concat(C, "=").concat(H));
|
2570
2570
|
}
|
2571
2571
|
} catch ($) {
|
2572
|
-
|
2572
|
+
A.e($);
|
2573
2573
|
} finally {
|
2574
|
-
|
2574
|
+
A.f();
|
2575
2575
|
}
|
2576
2576
|
}
|
2577
2577
|
return T.length > 0 && (E += "?".concat(T.join("&"))), E;
|
@@ -2635,28 +2635,28 @@ function bt() {
|
|
2635
2635
|
if (typeof Symbol > "u" || g[Symbol.iterator] == null) {
|
2636
2636
|
if (Array.isArray(g) || (E = n(g)) || T && g && typeof g.length == "number") {
|
2637
2637
|
E && (g = E);
|
2638
|
-
var y = 0,
|
2638
|
+
var y = 0, C = function() {
|
2639
2639
|
};
|
2640
|
-
return { s:
|
2640
|
+
return { s: C, n: function() {
|
2641
2641
|
return y >= g.length ? { done: !0 } : { done: !1, value: g[y++] };
|
2642
2642
|
}, e: function(oe) {
|
2643
2643
|
throw oe;
|
2644
|
-
}, f:
|
2644
|
+
}, f: C };
|
2645
2645
|
}
|
2646
2646
|
throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
2647
2647
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
2648
2648
|
}
|
2649
|
-
var
|
2649
|
+
var A = !0, I = !1, H;
|
2650
2650
|
return { s: function() {
|
2651
2651
|
E = g[Symbol.iterator]();
|
2652
2652
|
}, n: function() {
|
2653
2653
|
var oe = E.next();
|
2654
|
-
return
|
2654
|
+
return A = oe.done, oe;
|
2655
2655
|
}, e: function(oe) {
|
2656
2656
|
I = !0, H = oe;
|
2657
2657
|
}, f: function() {
|
2658
2658
|
try {
|
2659
|
-
!
|
2659
|
+
!A && E.return != null && E.return();
|
2660
2660
|
} finally {
|
2661
2661
|
if (I)
|
2662
2662
|
throw H;
|
@@ -2696,18 +2696,18 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2696
2696
|
}, Ze.hasMethods = function(g) {
|
2697
2697
|
for (var T = arguments.length, E = new Array(T > 1 ? T - 1 : 0), y = 1; y < T; y++)
|
2698
2698
|
E[y - 1] = arguments[y];
|
2699
|
-
for (var
|
2700
|
-
var I = C
|
2699
|
+
for (var C = 0, A = E; C < A.length; C++) {
|
2700
|
+
var I = A[C];
|
2701
2701
|
if (d(g[I]))
|
2702
2702
|
return !1;
|
2703
2703
|
}
|
2704
2704
|
return !0;
|
2705
2705
|
};
|
2706
2706
|
var h = Ze.createRandomToken = function(g) {
|
2707
|
-
var T = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 32, E, y,
|
2707
|
+
var T = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 32, E, y, C = "";
|
2708
2708
|
for (E = 0; E < g; E++)
|
2709
|
-
y = Math.random() * T | 0,
|
2710
|
-
return
|
2709
|
+
y = Math.random() * T | 0, C += y.toString(T);
|
2710
|
+
return C;
|
2711
2711
|
};
|
2712
2712
|
Ze.newTag = function() {
|
2713
2713
|
return h(10);
|
@@ -2732,22 +2732,22 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2732
2732
|
if (g instanceof s)
|
2733
2733
|
return g;
|
2734
2734
|
if (typeof g == "string") {
|
2735
|
-
var E = g.split("@"), y,
|
2735
|
+
var E = g.split("@"), y, C;
|
2736
2736
|
switch (E.length) {
|
2737
2737
|
case 1:
|
2738
2738
|
if (!T)
|
2739
2739
|
return;
|
2740
|
-
y = g,
|
2740
|
+
y = g, C = T;
|
2741
2741
|
break;
|
2742
2742
|
case 2:
|
2743
|
-
y = E[0],
|
2743
|
+
y = E[0], C = E[1];
|
2744
2744
|
break;
|
2745
2745
|
default:
|
2746
|
-
y = E.slice(0, E.length - 1).join("@"),
|
2746
|
+
y = E.slice(0, E.length - 1).join("@"), C = E[E.length - 1];
|
2747
2747
|
}
|
2748
|
-
y = y.replace(/^(sips?|tel):/i, ""), /^[-.()]*\+?[0-9\-.()]+$/.test(y) && (y = y.replace(/[-.()]/g, "")), g = "".concat(o.SIP, ":").concat(_(y), "@").concat(
|
2749
|
-
var
|
2750
|
-
return (
|
2748
|
+
y = y.replace(/^(sips?|tel):/i, ""), /^[-.()]*\+?[0-9\-.()]+$/.test(y) && (y = y.replace(/[-.()]/g, "")), g = "".concat(o.SIP, ":").concat(_(y), "@").concat(C);
|
2749
|
+
var A;
|
2750
|
+
return (A = s.parse(g)) ? A : void 0;
|
2751
2751
|
} else
|
2752
2752
|
return;
|
2753
2753
|
} else
|
@@ -2757,9 +2757,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2757
2757
|
"Call-Id": "Call-ID",
|
2758
2758
|
Cseq: "CSeq",
|
2759
2759
|
"Www-Authenticate": "WWW-Authenticate"
|
2760
|
-
}, E = g.toLowerCase().replace(/_/g, "-").split("-"), y = "",
|
2761
|
-
for (
|
2762
|
-
|
2760
|
+
}, E = g.toLowerCase().replace(/_/g, "-").split("-"), y = "", C = E.length, A;
|
2761
|
+
for (A = 0; A < C; A++)
|
2762
|
+
A !== 0 && (y += "-"), y += E[A].charAt(0).toUpperCase() + E[A].substring(1);
|
2763
2763
|
return T[y] && (y = T[y]), y;
|
2764
2764
|
}, Ze.sipErrorCause = function(g) {
|
2765
2765
|
for (var T in o.SIP_ERROR_CAUSES)
|
@@ -2782,10 +2782,10 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2782
2782
|
function y(pe, ue, _e) {
|
2783
2783
|
return pe & ue | ~pe & _e;
|
2784
2784
|
}
|
2785
|
-
function
|
2785
|
+
function C(pe, ue, _e) {
|
2786
2786
|
return pe & _e | ue & ~_e;
|
2787
2787
|
}
|
2788
|
-
function
|
2788
|
+
function A(pe, ue, _e) {
|
2789
2789
|
return pe ^ ue ^ _e;
|
2790
2790
|
}
|
2791
2791
|
function I(pe, ue, _e) {
|
@@ -2795,10 +2795,10 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2795
2795
|
return pe = E(pe, E(E(y(ue, _e, we), Ne), Le)), E(T(pe, Qe), ue);
|
2796
2796
|
}
|
2797
2797
|
function $(pe, ue, _e, we, Ne, Qe, Le) {
|
2798
|
-
return pe = E(pe, E(E(
|
2798
|
+
return pe = E(pe, E(E(C(ue, _e, we), Ne), Le)), E(T(pe, Qe), ue);
|
2799
2799
|
}
|
2800
2800
|
function oe(pe, ue, _e, we, Ne, Qe, Le) {
|
2801
|
-
return pe = E(pe, E(E(
|
2801
|
+
return pe = E(pe, E(E(A(ue, _e, we), Ne), Le)), E(T(pe, Qe), ue);
|
2802
2802
|
}
|
2803
2803
|
function N(pe, ue, _e, we, Ne, Qe, Le) {
|
2804
2804
|
return pe = E(pe, E(E(I(ue, _e, we), Ne), Le)), E(T(pe, Qe), ue);
|
@@ -2821,9 +2821,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2821
2821
|
}
|
2822
2822
|
return ue;
|
2823
2823
|
}
|
2824
|
-
var k = [], D, B, V, J, F, X, U, P, se, st = 7, ee = 12, W = 17, G = 22, re = 5, ge = 9, be = 14, xe = 20,
|
2824
|
+
var k = [], D, B, V, J, F, X, U, P, se, st = 7, ee = 12, W = 17, G = 22, re = 5, ge = 9, be = 14, xe = 20, Ae = 4, le = 11, ye = 16, nt = 23, at = 6, Ee = 10, Ce = 15, Ie = 21;
|
2825
2825
|
for (g = ve(g), k = j(g), X = 1732584193, U = 4023233417, P = 2562383102, se = 271733878, D = 0; D < k.length; D += 16)
|
2826
|
-
B = X, V = U, J = P, F = se, X = H(X, U, P, se, k[D + 0], st, 3614090360), se = H(se, X, U, P, k[D + 1], ee, 3905402710), P = H(P, se, X, U, k[D + 2], W, 606105819), U = H(U, P, se, X, k[D + 3], G, 3250441966), X = H(X, U, P, se, k[D + 4], st, 4118548399), se = H(se, X, U, P, k[D + 5], ee, 1200080426), P = H(P, se, X, U, k[D + 6], W, 2821735955), U = H(U, P, se, X, k[D + 7], G, 4249261313), X = H(X, U, P, se, k[D + 8], st, 1770035416), se = H(se, X, U, P, k[D + 9], ee, 2336552879), P = H(P, se, X, U, k[D + 10], W, 4294925233), U = H(U, P, se, X, k[D + 11], G, 2304563134), X = H(X, U, P, se, k[D + 12], st, 1804603682), se = H(se, X, U, P, k[D + 13], ee, 4254626195), P = H(P, se, X, U, k[D + 14], W, 2792965006), U = H(U, P, se, X, k[D + 15], G, 1236535329), X = $(X, U, P, se, k[D + 1], re, 4129170786), se = $(se, X, U, P, k[D + 6], ge, 3225465664), P = $(P, se, X, U, k[D + 11], be, 643717713), U = $(U, P, se, X, k[D + 0], xe, 3921069994), X = $(X, U, P, se, k[D + 5], re, 3593408605), se = $(se, X, U, P, k[D + 10], ge, 38016083), P = $(P, se, X, U, k[D + 15], be, 3634488961), U = $(U, P, se, X, k[D + 4], xe, 3889429448), X = $(X, U, P, se, k[D + 9], re, 568446438), se = $(se, X, U, P, k[D + 14], ge, 3275163606), P = $(P, se, X, U, k[D + 3], be, 4107603335), U = $(U, P, se, X, k[D + 8], xe, 1163531501), X = $(X, U, P, se, k[D + 13], re, 2850285829), se = $(se, X, U, P, k[D + 2], ge, 4243563512), P = $(P, se, X, U, k[D + 7], be, 1735328473), U = $(U, P, se, X, k[D + 12], xe, 2368359562), X = oe(X, U, P, se, k[D + 5],
|
2826
|
+
B = X, V = U, J = P, F = se, X = H(X, U, P, se, k[D + 0], st, 3614090360), se = H(se, X, U, P, k[D + 1], ee, 3905402710), P = H(P, se, X, U, k[D + 2], W, 606105819), U = H(U, P, se, X, k[D + 3], G, 3250441966), X = H(X, U, P, se, k[D + 4], st, 4118548399), se = H(se, X, U, P, k[D + 5], ee, 1200080426), P = H(P, se, X, U, k[D + 6], W, 2821735955), U = H(U, P, se, X, k[D + 7], G, 4249261313), X = H(X, U, P, se, k[D + 8], st, 1770035416), se = H(se, X, U, P, k[D + 9], ee, 2336552879), P = H(P, se, X, U, k[D + 10], W, 4294925233), U = H(U, P, se, X, k[D + 11], G, 2304563134), X = H(X, U, P, se, k[D + 12], st, 1804603682), se = H(se, X, U, P, k[D + 13], ee, 4254626195), P = H(P, se, X, U, k[D + 14], W, 2792965006), U = H(U, P, se, X, k[D + 15], G, 1236535329), X = $(X, U, P, se, k[D + 1], re, 4129170786), se = $(se, X, U, P, k[D + 6], ge, 3225465664), P = $(P, se, X, U, k[D + 11], be, 643717713), U = $(U, P, se, X, k[D + 0], xe, 3921069994), X = $(X, U, P, se, k[D + 5], re, 3593408605), se = $(se, X, U, P, k[D + 10], ge, 38016083), P = $(P, se, X, U, k[D + 15], be, 3634488961), U = $(U, P, se, X, k[D + 4], xe, 3889429448), X = $(X, U, P, se, k[D + 9], re, 568446438), se = $(se, X, U, P, k[D + 14], ge, 3275163606), P = $(P, se, X, U, k[D + 3], be, 4107603335), U = $(U, P, se, X, k[D + 8], xe, 1163531501), X = $(X, U, P, se, k[D + 13], re, 2850285829), se = $(se, X, U, P, k[D + 2], ge, 4243563512), P = $(P, se, X, U, k[D + 7], be, 1735328473), U = $(U, P, se, X, k[D + 12], xe, 2368359562), X = oe(X, U, P, se, k[D + 5], Ae, 4294588738), se = oe(se, X, U, P, k[D + 8], le, 2272392833), P = oe(P, se, X, U, k[D + 11], ye, 1839030562), U = oe(U, P, se, X, k[D + 14], nt, 4259657740), X = oe(X, U, P, se, k[D + 1], Ae, 2763975236), se = oe(se, X, U, P, k[D + 4], le, 1272893353), P = oe(P, se, X, U, k[D + 7], ye, 4139469664), U = oe(U, P, se, X, k[D + 10], nt, 3200236656), X = oe(X, U, P, se, k[D + 13], Ae, 681279174), se = oe(se, X, U, P, k[D + 0], le, 3936430074), P = oe(P, se, X, U, k[D + 3], ye, 3572445317), U = oe(U, P, se, X, k[D + 6], nt, 76029189), X = oe(X, U, P, se, k[D + 9], Ae, 3654602809), se = oe(se, X, U, P, k[D + 12], le, 3873151461), P = oe(P, se, X, U, k[D + 15], ye, 530742520), U = oe(U, P, se, X, k[D + 2], nt, 3299628645), X = N(X, U, P, se, k[D + 0], at, 4096336452), se = N(se, X, U, P, k[D + 7], Ee, 1126891415), P = N(P, se, X, U, k[D + 14], Ce, 2878612391), U = N(U, P, se, X, k[D + 5], Ie, 4237533241), X = N(X, U, P, se, k[D + 12], at, 1700485571), se = N(se, X, U, P, k[D + 3], Ee, 2399980690), P = N(P, se, X, U, k[D + 10], Ce, 4293915773), U = N(U, P, se, X, k[D + 1], Ie, 2240044497), X = N(X, U, P, se, k[D + 8], at, 1873313359), se = N(se, X, U, P, k[D + 15], Ee, 4264355552), P = N(P, se, X, U, k[D + 6], Ce, 2734768916), U = N(U, P, se, X, k[D + 13], Ie, 1309151649), X = N(X, U, P, se, k[D + 4], at, 4149444226), se = N(se, X, U, P, k[D + 11], Ee, 3174756917), P = N(P, se, X, U, k[D + 2], Ce, 718787259), U = N(U, P, se, X, k[D + 9], Ie, 3951481745), X = E(X, B), U = E(U, V), P = E(P, J), se = E(se, F);
|
2827
2827
|
var Oe = Se(X) + Se(U) + Se(P) + Se(se);
|
2828
2828
|
return Oe.toLowerCase();
|
2829
2829
|
}, Ze.closeMediaStream = function(g) {
|
@@ -2835,8 +2835,8 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2835
2835
|
var E = t(T), y;
|
2836
2836
|
try {
|
2837
2837
|
for (E.s(); !(y = E.n()).done; ) {
|
2838
|
-
var
|
2839
|
-
|
2838
|
+
var C = y.value;
|
2839
|
+
C.stop();
|
2840
2840
|
}
|
2841
2841
|
} catch (j) {
|
2842
2842
|
E.e(j);
|
@@ -2845,16 +2845,16 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
2845
2845
|
}
|
2846
2846
|
} else {
|
2847
2847
|
T = g.getAudioTracks();
|
2848
|
-
var
|
2848
|
+
var A = t(T), I;
|
2849
2849
|
try {
|
2850
|
-
for (
|
2850
|
+
for (A.s(); !(I = A.n()).done; ) {
|
2851
2851
|
var H = I.value;
|
2852
2852
|
H.stop();
|
2853
2853
|
}
|
2854
2854
|
} catch (j) {
|
2855
|
-
|
2855
|
+
A.e(j);
|
2856
2856
|
} finally {
|
2857
|
-
|
2857
|
+
A.f();
|
2858
2858
|
}
|
2859
2859
|
T = g.getVideoTracks();
|
2860
2860
|
var $ = t(T), oe;
|
@@ -3181,8 +3181,8 @@ function _d() {
|
|
3181
3181
|
return T >= a ? _(g, T, a, "day") : T >= n ? _(g, T, n, "hour") : T >= t ? _(g, T, t, "minute") : T >= c ? _(g, T, c, "second") : g + " ms";
|
3182
3182
|
}
|
3183
3183
|
function _(g, T, E, y) {
|
3184
|
-
var
|
3185
|
-
return Math.round(g / E) + " " + y + (
|
3184
|
+
var C = T >= E * 1.5;
|
3185
|
+
return Math.round(g / E) + " " + y + (C ? "s" : "");
|
3186
3186
|
}
|
3187
3187
|
return _o;
|
3188
3188
|
}
|
@@ -3198,11 +3198,11 @@ function pd(c) {
|
|
3198
3198
|
}
|
3199
3199
|
n.selectColor = t;
|
3200
3200
|
function n(g) {
|
3201
|
-
let T, E = null, y,
|
3202
|
-
function
|
3203
|
-
if (!
|
3201
|
+
let T, E = null, y, C;
|
3202
|
+
function A(...I) {
|
3203
|
+
if (!A.enabled)
|
3204
3204
|
return;
|
3205
|
-
const H =
|
3205
|
+
const H = A, $ = Number(/* @__PURE__ */ new Date()), oe = $ - (T || $);
|
3206
3206
|
H.diff = oe, H.prev = T, H.curr = $, T = $, I[0] = n.coerce(I[0]), typeof I[0] != "string" && I.unshift("%O");
|
3207
3207
|
let N = 0;
|
3208
3208
|
I[0] = I[0].replace(/%([a-zA-Z%])/g, (Se, ve) => {
|
@@ -3217,14 +3217,14 @@ function pd(c) {
|
|
3217
3217
|
return Se;
|
3218
3218
|
}), n.formatArgs.call(H, I), (H.log || n.log).apply(H, I);
|
3219
3219
|
}
|
3220
|
-
return
|
3220
|
+
return A.namespace = g, A.useColors = n.useColors(), A.color = n.selectColor(g), A.extend = a, A.destroy = n.destroy, Object.defineProperty(A, "enabled", {
|
3221
3221
|
enumerable: !0,
|
3222
3222
|
configurable: !1,
|
3223
|
-
get: () => E !== null ? E : (y !== n.namespaces && (y = n.namespaces,
|
3223
|
+
get: () => E !== null ? E : (y !== n.namespaces && (y = n.namespaces, C = n.enabled(g)), C),
|
3224
3224
|
set: (I) => {
|
3225
3225
|
E = I;
|
3226
3226
|
}
|
3227
|
-
}), typeof n.init == "function" && n.init(
|
3227
|
+
}), typeof n.init == "function" && n.init(A), A;
|
3228
3228
|
}
|
3229
3229
|
function a(g, T) {
|
3230
3230
|
const E = n(this.namespace + (typeof T > "u" ? ":" : T) + g);
|
@@ -3899,10 +3899,10 @@ var Zf = Qf.exports;
|
|
3899
3899
|
return d.split(/(\r\n|\r|\n)/).filter(s).forEach(function(T) {
|
3900
3900
|
var E = T[0], y = T.slice(2);
|
3901
3901
|
E === "m" && (_.push({ rtp: [], fmtp: [] }), g = _[_.length - 1]);
|
3902
|
-
for (var
|
3903
|
-
var
|
3904
|
-
if (
|
3905
|
-
return a(
|
3902
|
+
for (var C = 0; C < (o[E] || []).length; C += 1) {
|
3903
|
+
var A = o[E][C];
|
3904
|
+
if (A.reg.test(y))
|
3905
|
+
return a(A, g, y);
|
3906
3906
|
}
|
3907
3907
|
}), h.media = _, h;
|
3908
3908
|
};
|
@@ -3979,7 +3979,7 @@ var po = Zf, vd = /%[sdv%]/g, Ed = function(c) {
|
|
3979
3979
|
"r",
|
3980
3980
|
"z",
|
3981
3981
|
"a"
|
3982
|
-
], yd = ["i", "c", "b", "a"],
|
3982
|
+
], yd = ["i", "c", "b", "a"], Cd = function(c, t) {
|
3983
3983
|
t = t || {}, c.version == null && (c.version = 0), c.name == null && (c.name = " "), c.media.forEach(function(s) {
|
3984
3984
|
s.payloads == null && (s.payloads = "");
|
3985
3985
|
});
|
@@ -4001,8 +4001,8 @@ var po = Zf, vd = /%[sdv%]/g, Ed = function(c) {
|
|
4001
4001
|
}), o.join(`\r
|
4002
4002
|
`) + `\r
|
4003
4003
|
`;
|
4004
|
-
}, bn = Xf,
|
4005
|
-
xt.write =
|
4004
|
+
}, bn = Xf, Ad = Cd;
|
4005
|
+
xt.write = Ad;
|
4006
4006
|
xt.parse = bn.parse;
|
4007
4007
|
xt.parseParams = bn.parseParams;
|
4008
4008
|
xt.parseFmtpConfig = bn.parseFmtpConfig;
|
@@ -4143,8 +4143,8 @@ var eh = xt, Od = ht, Et = lt, rt = bt(), nc = Ou(), Dd = os(), mo = new Od("SIP
|
|
4143
4143
|
typeof o.from_display_name < "u" ? E = o.from_display_name : a.configuration.display_name ? E = a.configuration.display_name : E = null, this.from = new nc(g, E, T), this.setHeader("from", this.from.toString());
|
4144
4144
|
var y = o.call_id || a.configuration.jssip_id + rt.createRandomToken(15);
|
4145
4145
|
this.call_id = y, this.setHeader("call-id", y);
|
4146
|
-
var
|
4147
|
-
this.cseq =
|
4146
|
+
var C = o.cseq || Math.floor(Math.random() * 1e4);
|
4147
|
+
this.cseq = C, this.setHeader("cseq", "".concat(C, " ").concat(t));
|
4148
4148
|
}
|
4149
4149
|
return Ba(c, [{
|
4150
4150
|
key: "setHeader",
|
@@ -4493,17 +4493,17 @@ var eh = xt, Od = ht, Et = lt, rt = bt(), nc = Ou(), Dd = os(), mo = new Od("SIP
|
|
4493
4493
|
var E = "SIP/2.0 ".concat(o, " ").concat(s, `\r
|
4494
4494
|
`);
|
4495
4495
|
if (this.method === Et.INVITE && o > 100 && o <= 200) {
|
4496
|
-
var y = this.getHeaders("record-route"),
|
4496
|
+
var y = this.getHeaders("record-route"), C = Bt(y), A;
|
4497
4497
|
try {
|
4498
|
-
for (
|
4499
|
-
var I =
|
4498
|
+
for (C.s(); !(A = C.n()).done; ) {
|
4499
|
+
var I = A.value;
|
4500
4500
|
E += "Record-Route: ".concat(I, `\r
|
4501
4501
|
`);
|
4502
4502
|
}
|
4503
4503
|
} catch (D) {
|
4504
|
-
|
4504
|
+
C.e(D);
|
4505
4505
|
} finally {
|
4506
|
-
|
4506
|
+
C.f();
|
4507
4507
|
}
|
4508
4508
|
}
|
4509
4509
|
var H = this.getHeaders("via"), $ = Bt(H), oe;
|
@@ -4581,8 +4581,8 @@ var eh = xt, Od = ht, Et = lt, rt = bt(), nc = Ou(), Dd = os(), mo = new Od("SIP
|
|
4581
4581
|
d += "Via: ".concat(g, `\r
|
4582
4582
|
`);
|
4583
4583
|
}
|
4584
|
-
} catch (
|
4585
|
-
h.e(
|
4584
|
+
} catch (A) {
|
4585
|
+
h.e(A);
|
4586
4586
|
} finally {
|
4587
4587
|
h.f();
|
4588
4588
|
}
|
@@ -4595,12 +4595,12 @@ var eh = xt, Od = ht, Et = lt, rt = bt(), nc = Ou(), Dd = os(), mo = new Od("SIP
|
|
4595
4595
|
var E = Bt(this.ua.configuration.extra_headers), y;
|
4596
4596
|
try {
|
4597
4597
|
for (E.s(); !(y = E.n()).done; ) {
|
4598
|
-
var
|
4599
|
-
d += "".concat(
|
4598
|
+
var C = y.value;
|
4599
|
+
d += "".concat(C.trim(), `\r
|
4600
4600
|
`);
|
4601
4601
|
}
|
4602
|
-
} catch (
|
4603
|
-
E.e(
|
4602
|
+
} catch (A) {
|
4603
|
+
E.e(A);
|
4604
4604
|
} finally {
|
4605
4605
|
E.f();
|
4606
4606
|
}
|
@@ -5341,8 +5341,8 @@ var t_ = ht, vo = bt(), pn = lt, dc = Ss, _c = dl, Ni = new t_("Registrator"), j
|
|
5341
5341
|
Ni.debug("no Contact header in response to REGISTER, response ignored");
|
5342
5342
|
break;
|
5343
5343
|
}
|
5344
|
-
var h = d.headers.Contact.reduce(function(y,
|
5345
|
-
return y.concat(
|
5344
|
+
var h = d.headers.Contact.reduce(function(y, C) {
|
5345
|
+
return y.concat(C.parsed);
|
5346
5346
|
}, []), _ = h.find(function(y) {
|
5347
5347
|
return n._sipInstance === y.getParam("+sip.instance") && n._reg_id === parseInt(y.getParam("reg-id"));
|
5348
5348
|
});
|
@@ -5538,7 +5538,7 @@ function mc(c, t) {
|
|
5538
5538
|
function gc(c, t, n) {
|
5539
5539
|
return t && mc(c.prototype, t), n && mc(c, n), c;
|
5540
5540
|
}
|
5541
|
-
var o_ = ht, Tc = Ss, Ms = lt, Ui = hl, u_ = l_, yo = bt(),
|
5541
|
+
var o_ = ht, Tc = Ss, Ms = lt, Ui = hl, u_ = l_, yo = bt(), Co = new o_("Dialog"), Ls = {
|
5542
5542
|
// Dialog states.
|
5543
5543
|
STATUS_EARLY: 1,
|
5544
5544
|
STATUS_CONFIRMED: 2,
|
@@ -5573,7 +5573,7 @@ var o_ = ht, Tc = Ss, Ms = lt, Ui = hl, u_ = l_, yo = bt(), Ao = new o_("Dialog"
|
|
5573
5573
|
toString: function() {
|
5574
5574
|
return this.call_id + this.local_tag + this.remote_tag;
|
5575
5575
|
}
|
5576
|
-
}, this._state = o, this._local_seqnum = n.cseq, this._local_uri = n.parseHeader("from").uri, this._remote_uri = n.parseHeader("to").uri, this._remote_target = s.uri, this._route_set = n.getHeaders("record-route").reverse(), this._ack_seqnum = null), this._ua.newDialog(this),
|
5576
|
+
}, this._state = o, this._local_seqnum = n.cseq, this._local_uri = n.parseHeader("from").uri, this._remote_uri = n.parseHeader("to").uri, this._remote_target = s.uri, this._route_set = n.getHeaders("record-route").reverse(), this._ack_seqnum = null), this._ua.newDialog(this), Co.debug("new ".concat(a, " dialog created with status ").concat(this._state === Ls.STATUS_EARLY ? "EARLY" : "CONFIRMED"));
|
5577
5577
|
}
|
5578
5578
|
return gc(c, [{
|
5579
5579
|
key: "isTerminated",
|
@@ -5583,12 +5583,12 @@ var o_ = ht, Tc = Ss, Ms = lt, Ui = hl, u_ = l_, yo = bt(), Ao = new o_("Dialog"
|
|
5583
5583
|
}, {
|
5584
5584
|
key: "update",
|
5585
5585
|
value: function(n, a) {
|
5586
|
-
this._state = Ls.STATUS_CONFIRMED,
|
5586
|
+
this._state = Ls.STATUS_CONFIRMED, Co.debug("dialog ".concat(this._id.toString(), " changed to CONFIRMED state")), a === "UAC" && (this._route_set = n.getHeaders("record-route").reverse());
|
5587
5587
|
}
|
5588
5588
|
}, {
|
5589
5589
|
key: "terminate",
|
5590
5590
|
value: function() {
|
5591
|
-
|
5591
|
+
Co.debug("dialog ".concat(this._id.toString(), " deleted")), this._ua.destroyDialog(this), this._state = Ls.STATUS_TERMINATED;
|
5592
5592
|
}
|
5593
5593
|
}, {
|
5594
5594
|
key: "sendRequest",
|
@@ -5855,7 +5855,7 @@ Pu.exports = /* @__PURE__ */ function(c) {
|
|
5855
5855
|
}]), n;
|
5856
5856
|
}(T_);
|
5857
5857
|
Pu.exports.C = rh;
|
5858
|
-
var
|
5858
|
+
var C_ = Pu.exports;
|
5859
5859
|
function Sa(c) {
|
5860
5860
|
"@babel/helpers - typeof";
|
5861
5861
|
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? Sa = function(n) {
|
@@ -5864,7 +5864,7 @@ function Sa(c) {
|
|
5864
5864
|
return n && typeof Symbol == "function" && n.constructor === Symbol && n !== Symbol.prototype ? "symbol" : typeof n;
|
5865
5865
|
}, Sa(c);
|
5866
5866
|
}
|
5867
|
-
function
|
5867
|
+
function A_(c, t) {
|
5868
5868
|
if (!(c instanceof t))
|
5869
5869
|
throw new TypeError("Cannot call a class as a function");
|
5870
5870
|
}
|
@@ -5929,7 +5929,7 @@ var N_ = ft.EventEmitter, U_ = lt, P_ = Ws, x_ = bt(), k_ = /* @__PURE__ */ func
|
|
5929
5929
|
var t = b_(n);
|
5930
5930
|
function n(a) {
|
5931
5931
|
var o;
|
5932
|
-
return
|
5932
|
+
return A_(this, n), o = t.call(this), o._session = a, o._direction = null, o._contentType = null, o._body = null, o;
|
5933
5933
|
}
|
5934
5934
|
return R_(n, [{
|
5935
5935
|
key: "send",
|
@@ -6007,22 +6007,22 @@ function yc(c, t) {
|
|
6007
6007
|
function L_(c, t, n) {
|
6008
6008
|
return t && yc(c.prototype, t), n && yc(c, n), c;
|
6009
6009
|
}
|
6010
|
-
var $_ = ht,
|
6010
|
+
var $_ = ht, Cc = lt, H_ = new $_("RTCSession:ReferNotifier"), Ao = {
|
6011
6011
|
event_type: "refer",
|
6012
6012
|
body_type: "message/sipfrag;version=2.0",
|
6013
6013
|
expires: 300
|
6014
6014
|
}, F_ = /* @__PURE__ */ function() {
|
6015
6015
|
function c(t, n, a) {
|
6016
|
-
M_(this, c), this._session = t, this._id = n, this._expires = a ||
|
6016
|
+
M_(this, c), this._session = t, this._id = n, this._expires = a || Ao.expires, this._active = !0, this.notify(100);
|
6017
6017
|
}
|
6018
6018
|
return L_(c, [{
|
6019
6019
|
key: "notify",
|
6020
6020
|
value: function(n, a) {
|
6021
6021
|
if (H_.debug("notify()"), this._active !== !1) {
|
6022
|
-
a = a ||
|
6022
|
+
a = a || Cc.REASON_PHRASE[n] || "";
|
6023
6023
|
var o;
|
6024
|
-
n >= 200 ? o = "terminated;reason=noresource" : o = "active;expires=".concat(this._expires), this._session.sendRequest(
|
6025
|
-
extraHeaders: ["Event: ".concat(
|
6024
|
+
n >= 200 ? o = "terminated;reason=noresource" : o = "active;expires=".concat(this._expires), this._session.sendRequest(Cc.NOTIFY, {
|
6025
|
+
extraHeaders: ["Event: ".concat(Ao.event_type, ";id=").concat(this._id), "Subscription-State: ".concat(o), "Content-Type: ".concat(Ao.body_type)],
|
6026
6026
|
body: "SIP/2.0 ".concat(n, " ").concat(a),
|
6027
6027
|
eventHandlers: {
|
6028
6028
|
// If a negative response is received, subscription is canceled.
|
@@ -6047,14 +6047,14 @@ function j_(c, t) {
|
|
6047
6047
|
if (!(c instanceof t))
|
6048
6048
|
throw new TypeError("Cannot call a class as a function");
|
6049
6049
|
}
|
6050
|
-
function
|
6050
|
+
function Ac(c, t) {
|
6051
6051
|
for (var n = 0; n < t.length; n++) {
|
6052
6052
|
var a = t[n];
|
6053
6053
|
a.enumerable = a.enumerable || !1, a.configurable = !0, "value" in a && (a.writable = !0), Object.defineProperty(c, a.key, a);
|
6054
6054
|
}
|
6055
6055
|
}
|
6056
6056
|
function q_(c, t, n) {
|
6057
|
-
return t &&
|
6057
|
+
return t && Ac(c.prototype, t), n && Ac(c, n), c;
|
6058
6058
|
}
|
6059
6059
|
function V_(c, t) {
|
6060
6060
|
if (typeof t != "function" && t !== null)
|
@@ -6121,8 +6121,8 @@ var Y_ = ft.EventEmitter, J_ = ht, Pi = lt, z_ = os(), Rc = bt(), mn = new J_("R
|
|
6121
6121
|
var g = null;
|
6122
6122
|
r.replaces && (g = r.replaces._request.call_id, g += ";to-tag=".concat(r.replaces._to_tag), g += ";from-tag=".concat(r.replaces._from_tag), g = encodeURIComponent(g));
|
6123
6123
|
var T = "Refer-To: <".concat(o).concat(g ? "?Replaces=".concat(g) : "", ">");
|
6124
|
-
if (d.push(T), !d.some(function(
|
6125
|
-
return
|
6124
|
+
if (d.push(T), !d.some(function(C) {
|
6125
|
+
return C.toLowerCase().startsWith("referred-by:");
|
6126
6126
|
})) {
|
6127
6127
|
var E = "Referred-By: <".concat(this._session._ua._configuration.uri._scheme, ":").concat(this._session._ua._configuration.uri._user, "@").concat(this._session._ua._configuration.uri._host, ">");
|
6128
6128
|
d.push(E);
|
@@ -6131,11 +6131,11 @@ var Y_ = ft.EventEmitter, J_ = ht, Pi = lt, z_ = os(), Rc = bt(), mn = new J_("R
|
|
6131
6131
|
var y = this._session.sendRequest(Pi.REFER, {
|
6132
6132
|
extraHeaders: d,
|
6133
6133
|
eventHandlers: {
|
6134
|
-
onSuccessResponse: function(
|
6135
|
-
s._requestSucceeded(
|
6134
|
+
onSuccessResponse: function(A) {
|
6135
|
+
s._requestSucceeded(A);
|
6136
6136
|
},
|
6137
|
-
onErrorResponse: function(
|
6138
|
-
s._requestFailed(
|
6137
|
+
onErrorResponse: function(A) {
|
6138
|
+
s._requestFailed(A, Pi.causes.REJECTED);
|
6139
6139
|
},
|
6140
6140
|
onTransportError: function() {
|
6141
6141
|
s._requestFailed(null, Pi.causes.CONNECTION_ERROR);
|
@@ -6210,13 +6210,13 @@ var Y_ = ft.EventEmitter, J_ = ht, Pi = lt, z_ = os(), Rc = bt(), mn = new J_("R
|
|
6210
6210
|
}
|
6211
6211
|
}]), n;
|
6212
6212
|
}(Y_);
|
6213
|
-
function
|
6213
|
+
function Ca(c) {
|
6214
6214
|
"@babel/helpers - typeof";
|
6215
|
-
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ?
|
6215
|
+
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? Ca = function(n) {
|
6216
6216
|
return typeof n;
|
6217
|
-
} :
|
6217
|
+
} : Ca = function(n) {
|
6218
6218
|
return n && typeof Symbol == "function" && n.constructor === Symbol && n !== Symbol.prototype ? "symbol" : typeof n;
|
6219
|
-
},
|
6219
|
+
}, Ca(c);
|
6220
6220
|
}
|
6221
6221
|
function _s(c, t) {
|
6222
6222
|
var n;
|
@@ -6304,7 +6304,7 @@ function tp(c) {
|
|
6304
6304
|
};
|
6305
6305
|
}
|
6306
6306
|
function sp(c, t) {
|
6307
|
-
return t && (
|
6307
|
+
return t && (Ca(t) === "object" || typeof t == "function") ? t : np(c);
|
6308
6308
|
}
|
6309
6309
|
function np(c) {
|
6310
6310
|
if (c === void 0)
|
@@ -6328,7 +6328,7 @@ function xa(c) {
|
|
6328
6328
|
return n.__proto__ || Object.getPrototypeOf(n);
|
6329
6329
|
}, xa(c);
|
6330
6330
|
}
|
6331
|
-
var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt(), xi = nh, ap = Ss, Vl = c_, op = dl, kt =
|
6331
|
+
var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt(), xi = nh, ap = Ss, Vl = c_, op = dl, kt = C_, Nc = k_, up = F_, cp = X_, Uc = Ks(), K = new lp("RTCSession"), Q = {
|
6332
6332
|
// RTCSession states.
|
6333
6333
|
STATUS_NULL: 0,
|
6334
6334
|
STATUS_INVITE_SENT: 1,
|
@@ -6433,8 +6433,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6433
6433
|
video: !0
|
6434
6434
|
}), T = s.mediaStream || null, E = Ve.cloneObject(s.pcConfig, {
|
6435
6435
|
iceServers: []
|
6436
|
-
}), y = s.rtcConstraints || null,
|
6437
|
-
if (this._rtcOfferConstraints =
|
6436
|
+
}), y = s.rtcConstraints || null, C = s.rtcOfferConstraints || null;
|
6437
|
+
if (this._rtcOfferConstraints = C, this._rtcAnswerConstraints = s.rtcAnswerConstraints || null, this._data = s.data || this._data, o === void 0)
|
6438
6438
|
throw new TypeError("Not enough arguments");
|
6439
6439
|
if (this._status !== Q.STATUS_NULL)
|
6440
6440
|
throw new gn.InvalidStateError(this._status);
|
@@ -6443,8 +6443,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6443
6443
|
if (o = this._ua.normalizeTarget(o), !o)
|
6444
6444
|
throw new TypeError("Invalid target: ".concat(d));
|
6445
6445
|
this._sessionTimers.enabled && Ve.isDecimal(s.sessionTimersExpires) && (s.sessionTimersExpires >= ce.MIN_SESSION_EXPIRES ? this._sessionTimers.defaultExpires = s.sessionTimersExpires : this._sessionTimers.defaultExpires = ce.SESSION_EXPIRES);
|
6446
|
-
for (var
|
6447
|
-
Object.prototype.hasOwnProperty.call(h,
|
6446
|
+
for (var A in h)
|
6447
|
+
Object.prototype.hasOwnProperty.call(h, A) && this.on(A, h[A]);
|
6448
6448
|
this._from_tag = Ve.newTag();
|
6449
6449
|
var I = s.anonymous || !1, H = {
|
6450
6450
|
from_tag: this._from_tag
|
@@ -6452,7 +6452,7 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6452
6452
|
this._contact = this._ua.contact.toString({
|
6453
6453
|
anonymous: I,
|
6454
6454
|
outbound: !0
|
6455
|
-
}), I ? (H.from_display_name = "Anonymous", H.from_uri = new Uc("sip", "anonymous", "anonymous.invalid"), _.push("P-Preferred-Identity: ".concat(this._ua.configuration.uri.toString())), _.push("Privacy: id")) : s.fromUserName && (H.from_uri = new Uc("sip", s.fromUserName, this._ua.configuration.uri.host), _.push("P-Preferred-Identity: ".concat(this._ua.configuration.uri.toString()))), s.fromDisplayName && (H.from_display_name = s.fromDisplayName), _.push("Contact: ".concat(this._contact)), _.push("Content-Type: application/sdp"), this._sessionTimers.enabled && _.push("Session-Expires: ".concat(this._sessionTimers.defaultExpires).concat(this._ua.configuration.session_timers_force_refresher ? ";refresher=uac" : "")), this._request = new ap.InitialOutgoingInviteRequest(o, this._ua, H, _), this._id = this._request.call_id + this._from_tag, this._createRTCConnection(E, y), this._direction = "outgoing", this._local_identity = this._request.from, this._remote_identity = this._request.to, r && r(this), this._newRTCSession("local", this._request), this._sendInitialRequest(g,
|
6455
|
+
}), I ? (H.from_display_name = "Anonymous", H.from_uri = new Uc("sip", "anonymous", "anonymous.invalid"), _.push("P-Preferred-Identity: ".concat(this._ua.configuration.uri.toString())), _.push("Privacy: id")) : s.fromUserName && (H.from_uri = new Uc("sip", s.fromUserName, this._ua.configuration.uri.host), _.push("P-Preferred-Identity: ".concat(this._ua.configuration.uri.toString()))), s.fromDisplayName && (H.from_display_name = s.fromDisplayName), _.push("Contact: ".concat(this._contact)), _.push("Content-Type: application/sdp"), this._sessionTimers.enabled && _.push("Session-Expires: ".concat(this._sessionTimers.defaultExpires).concat(this._ua.configuration.session_timers_force_refresher ? ";refresher=uac" : "")), this._request = new ap.InitialOutgoingInviteRequest(o, this._ua, H, _), this._id = this._request.call_id + this._from_tag, this._createRTCConnection(E, y), this._direction = "outgoing", this._local_identity = this._request.from, this._remote_identity = this._request.to, r && r(this), this._newRTCSession("local", this._request), this._sendInitialRequest(g, C, T);
|
6456
6456
|
}
|
6457
6457
|
}, {
|
6458
6458
|
key: "init_incoming",
|
@@ -6484,7 +6484,7 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6484
6484
|
K.debug("answer()");
|
6485
6485
|
var r = this._request, d = Ve.cloneArray(s.extraHeaders), h = Ve.cloneObject(s.mediaConstraints), _ = s.mediaStream || null, g = Ve.cloneObject(s.pcConfig, {
|
6486
6486
|
iceServers: []
|
6487
|
-
}), T = s.rtcConstraints || null, E = s.rtcAnswerConstraints || null, y = Ve.cloneObject(s.rtcOfferConstraints),
|
6487
|
+
}), T = s.rtcConstraints || null, E = s.rtcAnswerConstraints || null, y = Ve.cloneObject(s.rtcOfferConstraints), C, A = !1, I = !1, H = !1, $ = !1;
|
6488
6488
|
if (this._rtcAnswerConstraints = E, this._rtcOfferConstraints = s.rtcOfferConstraints || null, this._data = s.data || this._data, this._direction !== "incoming")
|
6489
6489
|
throw new gn.NotSupportedError('"answer" not supported for outgoing RTCSession');
|
6490
6490
|
if (this._status !== Q.STATUS_WAITING_FOR_ANSWER)
|
@@ -6500,7 +6500,7 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6500
6500
|
try {
|
6501
6501
|
for (N.s(); !(j = N.n()).done; ) {
|
6502
6502
|
var Se = j.value;
|
6503
|
-
Se.type === "audio" && (
|
6503
|
+
Se.type === "audio" && (A = !0, (!Se.direction || Se.direction === "sendrecv") && (H = !0)), Se.type === "video" && (I = !0, (!Se.direction || Se.direction === "sendrecv") && ($ = !0));
|
6504
6504
|
}
|
6505
6505
|
} catch (F) {
|
6506
6506
|
N.e(F);
|
@@ -6508,8 +6508,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6508
6508
|
N.f();
|
6509
6509
|
}
|
6510
6510
|
if (_ && h.audio === !1) {
|
6511
|
-
|
6512
|
-
var ve = _s(
|
6511
|
+
C = _.getAudioTracks();
|
6512
|
+
var ve = _s(C), k;
|
6513
6513
|
try {
|
6514
6514
|
for (ve.s(); !(k = ve.n()).done; ) {
|
6515
6515
|
var D = k.value;
|
@@ -6522,8 +6522,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6522
6522
|
}
|
6523
6523
|
}
|
6524
6524
|
if (_ && h.video === !1) {
|
6525
|
-
|
6526
|
-
var B = _s(
|
6525
|
+
C = _.getVideoTracks();
|
6526
|
+
var B = _s(C), V;
|
6527
6527
|
try {
|
6528
6528
|
for (B.s(); !(V = B.n()).done; ) {
|
6529
6529
|
var J = V.value;
|
@@ -6535,7 +6535,7 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6535
6535
|
B.f();
|
6536
6536
|
}
|
6537
6537
|
}
|
6538
|
-
!_ && h.audio === void 0 && (h.audio = H), !_ && h.video === void 0 && (h.video = $), !_ && !
|
6538
|
+
!_ && h.audio === void 0 && (h.audio = H), !_ && h.video === void 0 && (h.video = $), !_ && !A && !y.offerToReceiveAudio && (h.audio = !1), !_ && !I && !y.offerToReceiveVideo && (h.video = !1), this._createRTCConnection(g, T), Promise.resolve().then(function() {
|
6539
6539
|
if (_)
|
6540
6540
|
return _;
|
6541
6541
|
if (h.audio || h.video)
|
@@ -6618,8 +6618,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6618
6618
|
if (g && d.push("Reason: SIP ;cause=".concat(g, '; text="').concat(T, '"')), this._status === Q.STATUS_WAITING_FOR_ACK && this._direction === "incoming" && this._request.server_transaction.state !== Dc.C.STATUS_TERMINATED) {
|
6619
6619
|
var E = this._dialog;
|
6620
6620
|
this.receiveRequest = function(y) {
|
6621
|
-
var
|
6622
|
-
|
6621
|
+
var C = y.method;
|
6622
|
+
C === ce.ACK && (o.sendRequest(ce.BYE, {
|
6623
6623
|
extraHeaders: d,
|
6624
6624
|
body: h
|
6625
6625
|
}), E.terminate());
|
@@ -6670,16 +6670,16 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
6670
6670
|
this._tones = null;
|
6671
6671
|
return;
|
6672
6672
|
}
|
6673
|
-
var
|
6674
|
-
if (r += 1,
|
6673
|
+
var C = this._tones[r];
|
6674
|
+
if (r += 1, C === ",")
|
6675
6675
|
y = 2e3;
|
6676
6676
|
else {
|
6677
|
-
var
|
6677
|
+
var A = new kt(this);
|
6678
6678
|
s.eventHandlers = {
|
6679
6679
|
onFailed: function() {
|
6680
6680
|
E._tones = null;
|
6681
6681
|
}
|
6682
|
-
},
|
6682
|
+
}, A.send(C, s), y = d + h;
|
6683
6683
|
}
|
6684
6684
|
setTimeout(T.bind(this), y);
|
6685
6685
|
}
|
@@ -7066,7 +7066,7 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7066
7066
|
return new Promise(function(g) {
|
7067
7067
|
var T = !1, E, y;
|
7068
7068
|
r._iceReady = !1;
|
7069
|
-
var
|
7069
|
+
var C = function() {
|
7070
7070
|
d.removeEventListener("icecandidate", E), d.removeEventListener("icegatheringstatechange", y), T = !0, r._rtcReady = !0, r._iceReady = !0;
|
7071
7071
|
var I = {
|
7072
7072
|
originator: "local",
|
@@ -7079,10 +7079,10 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7079
7079
|
var H = I.candidate;
|
7080
7080
|
H ? r.emit("icecandidate", {
|
7081
7081
|
candidate: H,
|
7082
|
-
ready:
|
7083
|
-
}) : T ||
|
7082
|
+
ready: C
|
7083
|
+
}) : T || C();
|
7084
7084
|
}), d.addEventListener("icegatheringstatechange", y = function() {
|
7085
|
-
d.iceGatheringState === "complete" && !T &&
|
7085
|
+
d.iceGatheringState === "complete" && !T && C();
|
7086
7086
|
});
|
7087
7087
|
});
|
7088
7088
|
});
|
@@ -7117,12 +7117,12 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7117
7117
|
function _() {
|
7118
7118
|
var T = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
7119
7119
|
h = !0;
|
7120
|
-
var E = T.status_code || 403, y = T.reason_phrase || "",
|
7120
|
+
var E = T.status_code || 403, y = T.reason_phrase || "", C = Ve.cloneArray(T.extraHeaders);
|
7121
7121
|
if (this._status !== Q.STATUS_CONFIRMED)
|
7122
7122
|
return !1;
|
7123
7123
|
if (E < 300 || E >= 700)
|
7124
7124
|
throw new TypeError("Invalid status_code: ".concat(E));
|
7125
|
-
o.reply(E, y,
|
7125
|
+
o.reply(E, y, C);
|
7126
7126
|
}
|
7127
7127
|
if (this.emit("reinvite", d), h)
|
7128
7128
|
return;
|
@@ -7168,12 +7168,12 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7168
7168
|
function _() {
|
7169
7169
|
var T = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
7170
7170
|
h = !0;
|
7171
|
-
var E = T.status_code || 403, y = T.reason_phrase || "",
|
7171
|
+
var E = T.status_code || 403, y = T.reason_phrase || "", C = Ve.cloneArray(T.extraHeaders);
|
7172
7172
|
if (this._status !== Q.STATUS_CONFIRMED)
|
7173
7173
|
return !1;
|
7174
7174
|
if (E < 300 || E >= 700)
|
7175
7175
|
throw new TypeError("Invalid status_code: ".concat(E));
|
7176
|
-
o.reply(E, y,
|
7176
|
+
o.reply(E, y, C);
|
7177
7177
|
}
|
7178
7178
|
if (this.emit("update", d), h)
|
7179
7179
|
return;
|
@@ -7214,8 +7214,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7214
7214
|
}
|
7215
7215
|
}
|
7216
7216
|
}
|
7217
|
-
} catch (
|
7218
|
-
h.e(
|
7217
|
+
} catch (C) {
|
7218
|
+
h.e(C);
|
7219
7219
|
} finally {
|
7220
7220
|
h.f();
|
7221
7221
|
}
|
@@ -7232,8 +7232,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7232
7232
|
return this._connectionPromiseQueue = this._connectionPromiseQueue.then(function() {
|
7233
7233
|
if (s._status === Q.STATUS_TERMINATED)
|
7234
7234
|
throw new Error("terminated");
|
7235
|
-
return s._connection.setRemoteDescription(y).catch(function(
|
7236
|
-
throw o.reply(488), K.warn('emit "peerconnection:setremotedescriptionfailed" [error:%o]',
|
7235
|
+
return s._connection.setRemoteDescription(y).catch(function(C) {
|
7236
|
+
throw o.reply(488), K.warn('emit "peerconnection:setremotedescriptionfailed" [error:%o]', C), s.emit("peerconnection:setremotedescriptionfailed", C), C;
|
7237
7237
|
});
|
7238
7238
|
}).then(function() {
|
7239
7239
|
if (s._status === Q.STATUS_TERMINATED)
|
@@ -7242,11 +7242,11 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7242
7242
|
}).then(function() {
|
7243
7243
|
if (s._status === Q.STATUS_TERMINATED)
|
7244
7244
|
throw new Error("terminated");
|
7245
|
-
return s._createLocalDescription("answer", s._rtcAnswerConstraints).catch(function(
|
7246
|
-
throw o.reply(500), K.warn('emit "peerconnection:createtelocaldescriptionfailed" [error:%o]',
|
7245
|
+
return s._createLocalDescription("answer", s._rtcAnswerConstraints).catch(function(C) {
|
7246
|
+
throw o.reply(500), K.warn('emit "peerconnection:createtelocaldescriptionfailed" [error:%o]', C), C;
|
7247
7247
|
});
|
7248
|
-
}).catch(function(
|
7249
|
-
K.warn("_processInDialogSdpOffer() failed [error: %o]",
|
7248
|
+
}).catch(function(C) {
|
7249
|
+
K.warn("_processInDialogSdpOffer() failed [error: %o]", C);
|
7250
7250
|
}), this._connectionPromiseQueue;
|
7251
7251
|
}
|
7252
7252
|
/**
|
@@ -7281,14 +7281,14 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7281
7281
|
return !1;
|
7282
7282
|
var T = new n(this._ua);
|
7283
7283
|
if (T.on("progress", function(y) {
|
7284
|
-
var
|
7285
|
-
r.notify(
|
7284
|
+
var C = y.response;
|
7285
|
+
r.notify(C.status_code, C.reason_phrase);
|
7286
7286
|
}), T.on("accepted", function(y) {
|
7287
|
-
var
|
7288
|
-
r.notify(
|
7287
|
+
var C = y.response;
|
7288
|
+
r.notify(C.status_code, C.reason_phrase);
|
7289
7289
|
}), T.on("_failed", function(y) {
|
7290
|
-
var
|
7291
|
-
|
7290
|
+
var C = y.message, A = y.cause;
|
7291
|
+
C ? r.notify(C.status_code, C.reason_phrase) : r.notify(487, A);
|
7292
7292
|
}), o.refer_to.uri.hasHeader("replaces")) {
|
7293
7293
|
var E = decodeURIComponent(o.refer_to.uri.getHeader("replaces"));
|
7294
7294
|
g.extraHeaders = Ve.cloneArray(g.extraHeaders), g.extraHeaders.push("Replaces: ".concat(E));
|
@@ -7538,11 +7538,11 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7538
7538
|
extraHeaders: r,
|
7539
7539
|
body: E,
|
7540
7540
|
eventHandlers: {
|
7541
|
-
onSuccessResponse: function(
|
7542
|
-
g.call(o,
|
7541
|
+
onSuccessResponse: function(A) {
|
7542
|
+
g.call(o, A), _ = !0;
|
7543
7543
|
},
|
7544
|
-
onErrorResponse: function(
|
7545
|
-
T.call(o,
|
7544
|
+
onErrorResponse: function(A) {
|
7545
|
+
T.call(o, A);
|
7546
7546
|
},
|
7547
7547
|
onTransportError: function() {
|
7548
7548
|
o.onTransportError();
|
@@ -7570,18 +7570,18 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7570
7570
|
T.call(this);
|
7571
7571
|
return;
|
7572
7572
|
}
|
7573
|
-
var
|
7573
|
+
var C = {
|
7574
7574
|
originator: "remote",
|
7575
7575
|
type: "answer",
|
7576
7576
|
sdp: E.body
|
7577
7577
|
};
|
7578
|
-
K.debug('emit "sdp"'), this.emit("sdp",
|
7579
|
-
var
|
7578
|
+
K.debug('emit "sdp"'), this.emit("sdp", C);
|
7579
|
+
var A = new RTCSessionDescription({
|
7580
7580
|
type: "answer",
|
7581
|
-
sdp:
|
7581
|
+
sdp: C.sdp
|
7582
7582
|
});
|
7583
7583
|
this._connectionPromiseQueue = this._connectionPromiseQueue.then(function() {
|
7584
|
-
return y._connection.setRemoteDescription(
|
7584
|
+
return y._connection.setRemoteDescription(A);
|
7585
7585
|
}).then(function() {
|
7586
7586
|
d.succeeded && d.succeeded(E);
|
7587
7587
|
}).catch(function(I) {
|
@@ -7606,12 +7606,12 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7606
7606
|
return o._createLocalDescription("offer", h);
|
7607
7607
|
}).then(function(y) {
|
7608
7608
|
y = o._mangleOffer(y);
|
7609
|
-
var
|
7609
|
+
var C = {
|
7610
7610
|
originator: "local",
|
7611
7611
|
type: "offer",
|
7612
7612
|
sdp: y
|
7613
7613
|
};
|
7614
|
-
K.debug('emit "sdp"'), o.emit("sdp",
|
7614
|
+
K.debug('emit "sdp"'), o.emit("sdp", C), o.sendRequest(ce.UPDATE, {
|
7615
7615
|
extraHeaders: r,
|
7616
7616
|
body: y,
|
7617
7617
|
eventHandlers: {
|
@@ -7637,11 +7637,11 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7637
7637
|
})) : this.sendRequest(ce.UPDATE, {
|
7638
7638
|
extraHeaders: r,
|
7639
7639
|
eventHandlers: {
|
7640
|
-
onSuccessResponse: function(
|
7641
|
-
T.call(o,
|
7640
|
+
onSuccessResponse: function(C) {
|
7641
|
+
T.call(o, C);
|
7642
7642
|
},
|
7643
|
-
onErrorResponse: function(
|
7644
|
-
E.call(o,
|
7643
|
+
onErrorResponse: function(C) {
|
7644
|
+
E.call(o, C);
|
7645
7645
|
},
|
7646
7646
|
onTransportError: function() {
|
7647
7647
|
o.onTransportError();
|
@@ -7655,7 +7655,7 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7655
7655
|
}
|
7656
7656
|
});
|
7657
7657
|
function T(y) {
|
7658
|
-
var
|
7658
|
+
var C = this;
|
7659
7659
|
if (this._status !== Q.STATUS_TERMINATED && !g)
|
7660
7660
|
if (this._handleSessionTimersInIncomingResponse(y), _) {
|
7661
7661
|
if (y.body) {
|
@@ -7667,22 +7667,22 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7667
7667
|
E.call(this);
|
7668
7668
|
return;
|
7669
7669
|
}
|
7670
|
-
var
|
7670
|
+
var A = {
|
7671
7671
|
originator: "remote",
|
7672
7672
|
type: "answer",
|
7673
7673
|
sdp: y.body
|
7674
7674
|
};
|
7675
|
-
K.debug('emit "sdp"'), this.emit("sdp",
|
7675
|
+
K.debug('emit "sdp"'), this.emit("sdp", A);
|
7676
7676
|
var I = new RTCSessionDescription({
|
7677
7677
|
type: "answer",
|
7678
|
-
sdp:
|
7678
|
+
sdp: A.sdp
|
7679
7679
|
});
|
7680
7680
|
this._connectionPromiseQueue = this._connectionPromiseQueue.then(function() {
|
7681
|
-
return
|
7681
|
+
return C._connection.setRemoteDescription(I);
|
7682
7682
|
}).then(function() {
|
7683
7683
|
d.succeeded && d.succeeded(y);
|
7684
7684
|
}).catch(function(H) {
|
7685
|
-
E.call(
|
7685
|
+
E.call(C), K.warn('emit "peerconnection:setremotedescriptionfailed" [error:%o]', H), C.emit("peerconnection:setremotedescriptionfailed", H);
|
7686
7686
|
});
|
7687
7687
|
} else
|
7688
7688
|
d.succeeded && d.succeeded(y);
|
@@ -7716,8 +7716,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7716
7716
|
var d = r.value;
|
7717
7717
|
Bl.indexOf(d.type) !== -1 && (d.direction ? d.direction === "sendrecv" ? d.direction = "sendonly" : d.direction === "recvonly" && (d.direction = "inactive") : d.direction = "sendonly");
|
7718
7718
|
}
|
7719
|
-
} catch (
|
7720
|
-
s.e(
|
7719
|
+
} catch (C) {
|
7720
|
+
s.e(C);
|
7721
7721
|
} finally {
|
7722
7722
|
s.f();
|
7723
7723
|
}
|
@@ -7729,8 +7729,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7729
7729
|
var g = _.value;
|
7730
7730
|
Bl.indexOf(g.type) !== -1 && (g.direction = "inactive");
|
7731
7731
|
}
|
7732
|
-
} catch (
|
7733
|
-
h.e(
|
7732
|
+
} catch (C) {
|
7733
|
+
h.e(C);
|
7734
7734
|
} finally {
|
7735
7735
|
h.f();
|
7736
7736
|
}
|
@@ -7742,8 +7742,8 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7742
7742
|
var y = E.value;
|
7743
7743
|
Bl.indexOf(y.type) !== -1 && (y.direction ? y.direction === "sendrecv" ? y.direction = "recvonly" : y.direction === "recvonly" && (y.direction = "inactive") : y.direction = "recvonly");
|
7744
7744
|
}
|
7745
|
-
} catch (
|
7746
|
-
T.e(
|
7745
|
+
} catch (C) {
|
7746
|
+
T.e(C);
|
7747
7747
|
} finally {
|
7748
7748
|
T.f();
|
7749
7749
|
}
|
@@ -7989,13 +7989,13 @@ var ip = ft.EventEmitter, Oc = xt, lp = ht, ce = lt, gn = Ws, Dc = hl, Ve = bt()
|
|
7989
7989
|
}
|
7990
7990
|
}]), n;
|
7991
7991
|
}(ip);
|
7992
|
-
function
|
7992
|
+
function Aa(c) {
|
7993
7993
|
"@babel/helpers - typeof";
|
7994
|
-
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ?
|
7994
|
+
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? Aa = function(n) {
|
7995
7995
|
return typeof n;
|
7996
|
-
} :
|
7996
|
+
} : Aa = function(n) {
|
7997
7997
|
return n && typeof Symbol == "function" && n.constructor === Symbol && n !== Symbol.prototype ? "symbol" : typeof n;
|
7998
|
-
},
|
7998
|
+
}, Aa(c);
|
7999
7999
|
}
|
8000
8000
|
function hp(c, t) {
|
8001
8001
|
if (!(c instanceof t))
|
@@ -8033,7 +8033,7 @@ function pp(c) {
|
|
8033
8033
|
};
|
8034
8034
|
}
|
8035
8035
|
function mp(c, t) {
|
8036
|
-
return t && (
|
8036
|
+
return t && (Aa(t) === "object" || typeof t == "function") ? t : gp(c);
|
8037
8037
|
}
|
8038
8038
|
function gp(c) {
|
8039
8039
|
if (c === void 0)
|
@@ -8057,7 +8057,7 @@ function ka(c) {
|
|
8057
8057
|
return n.__proto__ || Object.getPrototypeOf(n);
|
8058
8058
|
}, ka(c);
|
8059
8059
|
}
|
8060
|
-
var vp = ft.EventEmitter, Ep = ht, Ro = lt, Sp = Ss, ki = bt(), yp = dl, xc = Ws,
|
8060
|
+
var vp = ft.EventEmitter, Ep = ht, Ro = lt, Sp = Ss, ki = bt(), yp = dl, xc = Ws, Cp = Ks(), Gl = new Ep("Message"), Ap = /* @__PURE__ */ function(c) {
|
8061
8061
|
_p(n, c);
|
8062
8062
|
var t = pp(n);
|
8063
8063
|
function n(a) {
|
@@ -8073,11 +8073,11 @@ var vp = ft.EventEmitter, Ep = ht, Ro = lt, Sp = Ss, ki = bt(), yp = dl, xc = Ws
|
|
8073
8073
|
if (o = this._ua.normalizeTarget(o), !o)
|
8074
8074
|
throw new TypeError("Invalid target: ".concat(h));
|
8075
8075
|
var _ = ki.cloneArray(d.extraHeaders), g = ki.cloneObject(d.eventHandlers), T = d.contentType || "text/plain", E = {};
|
8076
|
-
d.fromUserName && (E.from_uri = new
|
8076
|
+
d.fromUserName && (E.from_uri = new Cp("sip", d.fromUserName, this._ua.configuration.uri.host), _.push("P-Preferred-Identity: ".concat(this._ua.configuration.uri.toString()))), d.fromDisplayName && (E.from_display_name = d.fromDisplayName);
|
8077
8077
|
for (var y in g)
|
8078
8078
|
Object.prototype.hasOwnProperty.call(g, y) && this.on(y, g[y]);
|
8079
8079
|
_.push("Content-Type: ".concat(T)), this._request = new Sp.OutgoingRequest(Ro.MESSAGE, o, this._ua, E, _), s && (this._request.body = s);
|
8080
|
-
var
|
8080
|
+
var C = new yp(this._ua, this._request, {
|
8081
8081
|
onRequestTimeout: function() {
|
8082
8082
|
r._onRequestTimeout();
|
8083
8083
|
},
|
@@ -8088,7 +8088,7 @@ var vp = ft.EventEmitter, Ep = ht, Ro = lt, Sp = Ss, ki = bt(), yp = dl, xc = Ws
|
|
8088
8088
|
r._receiveResponse(I);
|
8089
8089
|
}
|
8090
8090
|
});
|
8091
|
-
this._newMessage("local", this._request),
|
8091
|
+
this._newMessage("local", this._request), C.send();
|
8092
8092
|
}
|
8093
8093
|
}, {
|
8094
8094
|
key: "init_incoming",
|
@@ -8297,8 +8297,8 @@ var Up = ft.EventEmitter, Pp = ht, Io = lt, xp = Ss, Mi = bt(), kp = dl, Mc = Ws
|
|
8297
8297
|
onTransportError: function() {
|
8298
8298
|
r._onTransportError();
|
8299
8299
|
},
|
8300
|
-
onReceiveResponse: function(
|
8301
|
-
r._receiveResponse(
|
8300
|
+
onReceiveResponse: function(A) {
|
8301
|
+
r._receiveResponse(A);
|
8302
8302
|
}
|
8303
8303
|
});
|
8304
8304
|
this._newOptions("local", this._request), y.send();
|
@@ -8760,8 +8760,8 @@ function Kp(c, t, n, a) {
|
|
8760
8760
|
var g = _.value;
|
8761
8761
|
c.addHeader("record-route", d.substring(g.possition, g.offset)), c.headers["Record-Route"][c.getHeaders("record-route").length - 1].parsed = g.parsed;
|
8762
8762
|
}
|
8763
|
-
} catch (
|
8764
|
-
h.e(
|
8763
|
+
} catch (C) {
|
8764
|
+
h.e(C);
|
8765
8765
|
} finally {
|
8766
8766
|
h.f();
|
8767
8767
|
}
|
@@ -8782,8 +8782,8 @@ function Kp(c, t, n, a) {
|
|
8782
8782
|
var y = E.value;
|
8783
8783
|
c.addHeader("contact", d.substring(y.possition, y.offset)), c.headers.Contact[c.getHeaders("contact").length - 1].parsed = y.parsed;
|
8784
8784
|
}
|
8785
|
-
} catch (
|
8786
|
-
T.e(
|
8785
|
+
} catch (C) {
|
8786
|
+
T.e(C);
|
8787
8787
|
} finally {
|
8788
8788
|
T.f();
|
8789
8789
|
}
|
@@ -8881,8 +8881,8 @@ function jc(c, t) {
|
|
8881
8881
|
a[n] = c[n];
|
8882
8882
|
return a;
|
8883
8883
|
}
|
8884
|
-
var Jp = ht, lh = lt, qc = Ss, ku = bt(), Mu = new Jp("sanityCheck"), zp = [lm], Xp = [em, tm, sm, nm], Qp = [rm, im],
|
8885
|
-
|
8884
|
+
var Jp = ht, lh = lt, qc = Ss, ku = bt(), Mu = new Jp("sanityCheck"), zp = [lm], Xp = [em, tm, sm, nm], Qp = [rm, im], Fe, rs, ah, Zp = function(c, t, n) {
|
8885
|
+
Fe = c, rs = t, ah = n;
|
8886
8886
|
var a = Ia(zp), o;
|
8887
8887
|
try {
|
8888
8888
|
for (a.s(); !(o = a.n()).done; ) {
|
@@ -8895,7 +8895,7 @@ var Jp = ht, lh = lt, qc = Ss, ku = bt(), Mu = new Jp("sanityCheck"), zp = [lm],
|
|
8895
8895
|
} finally {
|
8896
8896
|
a.f();
|
8897
8897
|
}
|
8898
|
-
if (
|
8898
|
+
if (Fe instanceof qc.IncomingRequest) {
|
8899
8899
|
var r = Ia(Xp), d;
|
8900
8900
|
try {
|
8901
8901
|
for (r.s(); !(d = r.n()).done; ) {
|
@@ -8908,7 +8908,7 @@ var Jp = ht, lh = lt, qc = Ss, ku = bt(), Mu = new Jp("sanityCheck"), zp = [lm],
|
|
8908
8908
|
} finally {
|
8909
8909
|
r.f();
|
8910
8910
|
}
|
8911
|
-
} else if (
|
8911
|
+
} else if (Fe instanceof qc.IncomingResponse) {
|
8912
8912
|
var _ = Ia(Qp), g;
|
8913
8913
|
try {
|
8914
8914
|
for (_.s(); !(g = _.n()).done; ) {
|
@@ -8925,29 +8925,29 @@ var Jp = ht, lh = lt, qc = Ss, ku = bt(), Mu = new Jp("sanityCheck"), zp = [lm],
|
|
8925
8925
|
return !0;
|
8926
8926
|
};
|
8927
8927
|
function em() {
|
8928
|
-
if (
|
8928
|
+
if (Fe.s("to").uri.scheme !== "sip")
|
8929
8929
|
return tl(416), !1;
|
8930
8930
|
}
|
8931
8931
|
function tm() {
|
8932
|
-
if (!
|
8932
|
+
if (!Fe.to_tag && Fe.call_id.substr(0, 5) === rs.configuration.jssip_id)
|
8933
8933
|
return tl(482), !1;
|
8934
8934
|
}
|
8935
8935
|
function sm() {
|
8936
|
-
var c = ku.str_utf8_length(
|
8936
|
+
var c = ku.str_utf8_length(Fe.body), t = Fe.getHeader("content-length");
|
8937
8937
|
if (c < t)
|
8938
8938
|
return tl(400), !1;
|
8939
8939
|
}
|
8940
8940
|
function nm() {
|
8941
|
-
var c =
|
8942
|
-
if (!
|
8943
|
-
if (
|
8944
|
-
if (rs._transactions.ist[
|
8941
|
+
var c = Fe.from_tag, t = Fe.call_id, n = Fe.cseq, a;
|
8942
|
+
if (!Fe.to_tag)
|
8943
|
+
if (Fe.method === lh.INVITE) {
|
8944
|
+
if (rs._transactions.ist[Fe.via_branch])
|
8945
8945
|
return !1;
|
8946
8946
|
for (var o in rs._transactions.ist)
|
8947
8947
|
if (Object.prototype.hasOwnProperty.call(rs._transactions.ist, o) && (a = rs._transactions.ist[o], a.request.from_tag === c && a.request.call_id === t && a.request.cseq === n))
|
8948
8948
|
return tl(482), !1;
|
8949
8949
|
} else {
|
8950
|
-
if (rs._transactions.nist[
|
8950
|
+
if (rs._transactions.nist[Fe.via_branch])
|
8951
8951
|
return !1;
|
8952
8952
|
for (var s in rs._transactions.nist)
|
8953
8953
|
if (Object.prototype.hasOwnProperty.call(rs._transactions.nist, s) && (a = rs._transactions.nist[s], a.request.from_tag === c && a.request.call_id === t && a.request.cseq === n))
|
@@ -8955,23 +8955,23 @@ function nm() {
|
|
8955
8955
|
}
|
8956
8956
|
}
|
8957
8957
|
function rm() {
|
8958
|
-
if (
|
8958
|
+
if (Fe.getHeaders("via").length > 1)
|
8959
8959
|
return Mu.debug("more than one Via header field present in the response, dropping the response"), !1;
|
8960
8960
|
}
|
8961
8961
|
function im() {
|
8962
|
-
var c = ku.str_utf8_length(
|
8962
|
+
var c = ku.str_utf8_length(Fe.body), t = Fe.getHeader("content-length");
|
8963
8963
|
if (c < t)
|
8964
8964
|
return Mu.debug("message body length is lower than the value in Content-Length header field, dropping the response"), !1;
|
8965
8965
|
}
|
8966
8966
|
function lm() {
|
8967
8967
|
for (var c = ["from", "to", "call_id", "cseq", "via"], t = 0, n = c; t < n.length; t++) {
|
8968
8968
|
var a = n[t];
|
8969
|
-
if (!
|
8969
|
+
if (!Fe.hasHeader(a))
|
8970
8970
|
return Mu.debug("missing mandatory header field : ".concat(a, ", dropping the response")), !1;
|
8971
8971
|
}
|
8972
8972
|
}
|
8973
8973
|
function tl(c) {
|
8974
|
-
var t =
|
8974
|
+
var t = Fe.getHeaders("via"), n, a = "SIP/2.0 ".concat(c, " ").concat(lh.REASON_PHRASE[c], `\r
|
8975
8975
|
`), o = Ia(t), s;
|
8976
8976
|
try {
|
8977
8977
|
for (o.s(); !(s = o.n()).done; ) {
|
@@ -8984,10 +8984,10 @@ function tl(c) {
|
|
8984
8984
|
} finally {
|
8985
8985
|
o.f();
|
8986
8986
|
}
|
8987
|
-
n =
|
8988
|
-
`), a += "From: ".concat(
|
8989
|
-
`), a += "Call-ID: ".concat(
|
8990
|
-
`), a += "CSeq: ".concat(
|
8987
|
+
n = Fe.getHeader("To"), Fe.to_tag || (n += ";tag=".concat(ku.newTag())), a += "To: ".concat(n, `\r
|
8988
|
+
`), a += "From: ".concat(Fe.getHeader("From"), `\r
|
8989
|
+
`), a += "Call-ID: ".concat(Fe.call_id, `\r
|
8990
|
+
`), a += "CSeq: ".concat(Fe.cseq, " ").concat(Fe.method, `\r
|
8991
8991
|
`), a += `\r
|
8992
8992
|
`, ah.send(a);
|
8993
8993
|
}
|
@@ -9312,7 +9312,7 @@ function La(c) {
|
|
9312
9312
|
return n.__proto__ || Object.getPrototypeOf(n);
|
9313
9313
|
}, La(c);
|
9314
9314
|
}
|
9315
|
-
var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc =
|
9315
|
+
var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Ap, zc = Mp, No = hl, mm = Vp, Jl = bt(), gm = Ws, Tm = Ks(), vm = ih, Uo = Ss, Em = Zp, Po = Lu, qe = new _m("UA"), Tt = {
|
9316
9316
|
// UA status codes.
|
9317
9317
|
STATUS_INIT: 0,
|
9318
9318
|
STATUS_READY: 1,
|
@@ -9333,7 +9333,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9333
9333
|
}]);
|
9334
9334
|
function n(a) {
|
9335
9335
|
var o;
|
9336
|
-
if (om(this, n),
|
9336
|
+
if (om(this, n), console.log("constructor es5"), qe.debug("new() [configuration:%o]", a), o = t.call(this), o._cache = {
|
9337
9337
|
credentials: {}
|
9338
9338
|
}, o._configuration = Object.assign({}, Po.settings), o._dynConfiguration = {}, o._dialogs = {}, o._applicants = {}, o._sessions = {}, o._transport = null, o._contact = null, o._status = Tt.STATUS_INIT, o._error = null, o._transactions = {
|
9339
9339
|
nist: {},
|
@@ -9359,7 +9359,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9359
9359
|
* Resume UA after being closed.
|
9360
9360
|
*/
|
9361
9361
|
value: function() {
|
9362
|
-
|
9362
|
+
qe.debug("start()"), this._status === Tt.STATUS_INIT ? this._transport.connect() : this._status === Tt.STATUS_USER_CLOSED ? (qe.debug("restarting UA"), this._closeTimer !== null && (clearTimeout(this._closeTimer), this._closeTimer = null, this._transport.disconnect()), this._status = Tt.STATUS_INIT, this._transport.connect()) : this._status === Tt.STATUS_READY ? qe.debug("UA is in READY status, not restarted") : qe.debug("ERROR: connection is down, Auto-Recovery system is trying to reconnect"), this._dynConfiguration.register = this._configuration.register;
|
9363
9363
|
}
|
9364
9364
|
/**
|
9365
9365
|
* Register.
|
@@ -9367,7 +9367,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9367
9367
|
}, {
|
9368
9368
|
key: "register",
|
9369
9369
|
value: function() {
|
9370
|
-
|
9370
|
+
qe.debug("register()"), this._dynConfiguration.register = !0, this._registrator.register();
|
9371
9371
|
}
|
9372
9372
|
/**
|
9373
9373
|
* Unregister.
|
@@ -9375,7 +9375,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9375
9375
|
}, {
|
9376
9376
|
key: "unregister",
|
9377
9377
|
value: function(o) {
|
9378
|
-
|
9378
|
+
qe.debug("unregister()"), this._dynConfiguration.register = !1, this._registrator.unregister(o);
|
9379
9379
|
}
|
9380
9380
|
/**
|
9381
9381
|
* Get the Registrator instance.
|
@@ -9413,7 +9413,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9413
9413
|
}, {
|
9414
9414
|
key: "call",
|
9415
9415
|
value: function(o, s) {
|
9416
|
-
|
9416
|
+
qe.debug("call()");
|
9417
9417
|
var r = new Yc(this);
|
9418
9418
|
return r.connect(o, s), r;
|
9419
9419
|
}
|
@@ -9430,7 +9430,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9430
9430
|
}, {
|
9431
9431
|
key: "sendMessage",
|
9432
9432
|
value: function(o, s, r) {
|
9433
|
-
|
9433
|
+
qe.debug("sendMessage()");
|
9434
9434
|
var d = new Jc(this);
|
9435
9435
|
return d.send(o, s, r), d;
|
9436
9436
|
}
|
@@ -9447,7 +9447,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9447
9447
|
}, {
|
9448
9448
|
key: "sendOptions",
|
9449
9449
|
value: function(o, s, r) {
|
9450
|
-
|
9450
|
+
qe.debug("sendOptions()");
|
9451
9451
|
var d = new zc(this);
|
9452
9452
|
return d.send(o, s, r), d;
|
9453
9453
|
}
|
@@ -9457,7 +9457,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9457
9457
|
}, {
|
9458
9458
|
key: "terminateSessions",
|
9459
9459
|
value: function(o) {
|
9460
|
-
|
9460
|
+
qe.debug("terminateSessions()");
|
9461
9461
|
for (var s in this._sessions)
|
9462
9462
|
this._sessions[s].isEnded() || this._sessions[s].terminate(o);
|
9463
9463
|
}
|
@@ -9469,15 +9469,15 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9469
9469
|
key: "stop",
|
9470
9470
|
value: function() {
|
9471
9471
|
var o = this;
|
9472
|
-
if (
|
9473
|
-
|
9472
|
+
if (qe.debug("stop()"), this._dynConfiguration = {}, this._status === Tt.STATUS_USER_CLOSED) {
|
9473
|
+
qe.debug("UA already closed");
|
9474
9474
|
return;
|
9475
9475
|
}
|
9476
9476
|
this._registrator.close();
|
9477
9477
|
var s = Object.keys(this._sessions).length;
|
9478
9478
|
for (var r in this._sessions)
|
9479
9479
|
if (Object.prototype.hasOwnProperty.call(this._sessions, r)) {
|
9480
|
-
|
9480
|
+
qe.debug("closing session ".concat(r));
|
9481
9481
|
try {
|
9482
9482
|
this._sessions[r].terminate();
|
9483
9483
|
} catch {
|
@@ -9521,7 +9521,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9521
9521
|
case "authorization_jwt":
|
9522
9522
|
return this._configuration.authorization_jwt;
|
9523
9523
|
default:
|
9524
|
-
|
9524
|
+
qe.warn('get() | cannot get "%s" parameter in runtime', o);
|
9525
9525
|
return;
|
9526
9526
|
}
|
9527
9527
|
}
|
@@ -9558,7 +9558,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9558
9558
|
break;
|
9559
9559
|
}
|
9560
9560
|
default:
|
9561
|
-
return
|
9561
|
+
return qe.warn('set() | cannot set "%s" parameter in runtime', o), !1;
|
9562
9562
|
}
|
9563
9563
|
return !0;
|
9564
9564
|
}
|
@@ -9674,9 +9674,10 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9674
9674
|
}, {
|
9675
9675
|
key: "receiveRequest",
|
9676
9676
|
value: function(o) {
|
9677
|
+
console.log("receiveRequest");
|
9677
9678
|
var s = o.method;
|
9678
9679
|
if (o.ruri.user !== this._configuration.uri.user && o.ruri.user !== this._contact.uri.user) {
|
9679
|
-
|
9680
|
+
qe.debug("Request-URI does not point to us"), o.method !== pt.ACK && o.reply_sl(404);
|
9680
9681
|
return;
|
9681
9682
|
}
|
9682
9683
|
if (o.ruri.scheme === pt.SIPS) {
|
@@ -9685,7 +9686,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9685
9686
|
}
|
9686
9687
|
if (!No.checkTransaction(this, o)) {
|
9687
9688
|
if (s === pt.INVITE ? new No.InviteServerTransaction(this, this._transport, o) : s !== pt.ACK && s !== pt.CANCEL && new No.NonInviteServerTransaction(this, this._transport, o), s === pt.OPTIONS) {
|
9688
|
-
if (this.listeners("newOptions").length === 0) {
|
9689
|
+
if (console.log("OPPP in option"), this.listeners("newOptions").length === 0) {
|
9689
9690
|
o.reply(200);
|
9690
9691
|
return;
|
9691
9692
|
}
|
@@ -9704,7 +9705,7 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9704
9705
|
}
|
9705
9706
|
var h, _;
|
9706
9707
|
if (o.to_tag)
|
9707
|
-
h = this._findDialog(o.call_id, o.from_tag, o.to_tag), h ? h.receiveRequest(o) : s === pt.NOTIFY ? (_ = this._findSession(o), _ ? _.receiveRequest(o) : (
|
9708
|
+
h = this._findDialog(o.call_id, o.from_tag, o.to_tag), h ? h.receiveRequest(o) : s === pt.NOTIFY ? (_ = this._findSession(o), _ ? _.receiveRequest(o) : (qe.debug("received NOTIFY request for a non existent subscription"), o.reply(481, "Subscription does not exist"))) : s !== pt.ACK && o.reply(481);
|
9708
9709
|
else
|
9709
9710
|
switch (s) {
|
9710
9711
|
case pt.INVITE:
|
@@ -9715,13 +9716,13 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9715
9716
|
} else
|
9716
9717
|
_ = new Yc(this), _.init_incoming(o);
|
9717
9718
|
else
|
9718
|
-
|
9719
|
+
qe.warn("INVITE received but WebRTC is not supported"), o.reply(488);
|
9719
9720
|
break;
|
9720
9721
|
case pt.BYE:
|
9721
9722
|
o.reply(481);
|
9722
9723
|
break;
|
9723
9724
|
case pt.CANCEL:
|
9724
|
-
_ = this._findSession(o), _ ? _.receiveRequest(o) :
|
9725
|
+
_ = this._findSession(o), _ ? _.receiveRequest(o) : qe.debug("received CANCEL request for a non existent session");
|
9725
9726
|
break;
|
9726
9727
|
case pt.ACK:
|
9727
9728
|
break;
|
@@ -9774,9 +9775,9 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9774
9775
|
// Recovery options.
|
9775
9776
|
max_interval: this._configuration.connection_recovery_max_interval,
|
9776
9777
|
min_interval: this._configuration.connection_recovery_min_interval
|
9777
|
-
}), this._transport.onconnecting = ym.bind(this), this._transport.onconnect =
|
9778
|
+
}), this._transport.onconnecting = ym.bind(this), this._transport.onconnect = Cm.bind(this), this._transport.ondisconnect = Am.bind(this), this._transport.ondata = Rm.bind(this);
|
9778
9779
|
} catch (g) {
|
9779
|
-
throw
|
9780
|
+
throw qe.warn(g), new gm.ConfigurationError("sockets", this._configuration.sockets);
|
9780
9781
|
}
|
9781
9782
|
if (delete this._configuration.sockets, this._configuration.authorization_user || (this._configuration.authorization_user = this._configuration.uri.user), !this._configuration.registrar_server) {
|
9782
9783
|
var r = this._configuration.uri.clone();
|
@@ -9789,8 +9790,8 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9789
9790
|
temp_gruu: null,
|
9790
9791
|
uri: this._configuration.contact_uri,
|
9791
9792
|
toString: function() {
|
9792
|
-
var T = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, E = T.anonymous || null, y = T.outbound || null,
|
9793
|
-
return E ?
|
9793
|
+
var T = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, E = T.anonymous || null, y = T.outbound || null, C = "<";
|
9794
|
+
return E ? C += this.temp_gruu || "sip:anonymous@anonymous.invalid;transport=ws" : C += this.pub_gruu || this.uri.toString(), y && (E ? !this.temp_gruu : !this.pub_gruu) && (C += ";ob"), C += ">", C;
|
9794
9795
|
}
|
9795
9796
|
};
|
9796
9797
|
var d = ["authorization_user", "password", "realm", "ha1", "authorization_jwt", "display_name", "register"];
|
@@ -9802,21 +9803,21 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9802
9803
|
writable: !1,
|
9803
9804
|
configurable: !1
|
9804
9805
|
}));
|
9805
|
-
|
9806
|
+
qe.debug("configuration parameters after validation:");
|
9806
9807
|
for (var _ in this._configuration)
|
9807
9808
|
if (Object.prototype.hasOwnProperty.call(Po.settings, _))
|
9808
9809
|
switch (_) {
|
9809
9810
|
case "uri":
|
9810
9811
|
case "registrar_server":
|
9811
|
-
|
9812
|
+
qe.debug("- ".concat(_, ": ").concat(this._configuration[_]));
|
9812
9813
|
break;
|
9813
9814
|
case "password":
|
9814
9815
|
case "ha1":
|
9815
9816
|
case "authorization_jwt":
|
9816
|
-
|
9817
|
+
qe.debug("- ".concat(_, ": NOT SHOWN"));
|
9817
9818
|
break;
|
9818
9819
|
default:
|
9819
|
-
|
9820
|
+
qe.debug("- ".concat(_, ": ").concat(JSON.stringify(this._configuration[_])));
|
9820
9821
|
}
|
9821
9822
|
}
|
9822
9823
|
}, {
|
@@ -9849,10 +9850,10 @@ var dm = ft.EventEmitter, _m = ht, pt = lt, pm = s_, Yc = fp, Jc = Cp, zc = Mp,
|
|
9849
9850
|
function ym(c) {
|
9850
9851
|
this.emit("connecting", c);
|
9851
9852
|
}
|
9852
|
-
function
|
9853
|
+
function Cm(c) {
|
9853
9854
|
this._status !== Tt.STATUS_USER_CLOSED && (this._status = Tt.STATUS_READY, this._error = null, this.emit("connected", c), this._dynConfiguration.register && this._registrator.register());
|
9854
9855
|
}
|
9855
|
-
function
|
9856
|
+
function Am(c) {
|
9856
9857
|
for (var t = ["nict", "ict", "nist", "ist"], n = 0, a = t; n < a.length; n++) {
|
9857
9858
|
var o = a[n];
|
9858
9859
|
for (var s in this._transactions[o])
|
@@ -9861,6 +9862,7 @@ function Cm(c) {
|
|
9861
9862
|
this.emit("disconnected", c), this._registrator.onTransportClosed(), this._status !== Tt.STATUS_USER_CLOSED && (this._status = Tt.STATUS_NOT_READY, this._error = Tt.NETWORK_ERROR);
|
9862
9863
|
}
|
9863
9864
|
function Rm(c) {
|
9865
|
+
console.log("onTransportData");
|
9864
9866
|
var t = c.transport, n = c.message;
|
9865
9867
|
if (n = vm.parseMessage(n, this), !!n && !(this._status === Tt.STATUS_USER_CLOSED && n instanceof Uo.IncomingRequest) && Em(n, this, t)) {
|
9866
9868
|
if (n instanceof Uo.IncomingRequest)
|
@@ -10285,8 +10287,8 @@ function Zt() {
|
|
10285
10287
|
ALPHA: T,
|
10286
10288
|
HEXDIG: E,
|
10287
10289
|
WSP: y,
|
10288
|
-
OCTET:
|
10289
|
-
DQUOTE:
|
10290
|
+
OCTET: C,
|
10291
|
+
DQUOTE: A,
|
10290
10292
|
SP: I,
|
10291
10293
|
HTAB: H,
|
10292
10294
|
alphanum: $,
|
@@ -10313,13 +10315,13 @@ function Zt() {
|
|
10313
10315
|
RPAREN: ge,
|
10314
10316
|
RAQUOT: be,
|
10315
10317
|
LAQUOT: xe,
|
10316
|
-
COMMA:
|
10318
|
+
COMMA: Ae,
|
10317
10319
|
SEMI: le,
|
10318
10320
|
COLON: ye,
|
10319
10321
|
LDQUOT: nt,
|
10320
10322
|
RDQUOT: at,
|
10321
10323
|
comment: Ee,
|
10322
|
-
ctext:
|
10324
|
+
ctext: Ce,
|
10323
10325
|
quoted_string: Ie,
|
10324
10326
|
quoted_string_clean: Oe,
|
10325
10327
|
qdtext: pe,
|
@@ -10344,14 +10346,14 @@ function Zt() {
|
|
10344
10346
|
ls32: ae,
|
10345
10347
|
IPv4address: ot,
|
10346
10348
|
dec_octet: Wt,
|
10347
|
-
port:
|
10349
|
+
port: As,
|
10348
10350
|
uri_parameters: Er,
|
10349
10351
|
uri_parameter: Un,
|
10350
10352
|
transport_param: Pn,
|
10351
10353
|
user_param: Sr,
|
10352
10354
|
method_param: yr,
|
10353
|
-
ttl_param:
|
10354
|
-
maddr_param:
|
10355
|
+
ttl_param: Cr,
|
10356
|
+
maddr_param: Ar,
|
10355
10357
|
lr_param: Rr,
|
10356
10358
|
other_param: Ir,
|
10357
10359
|
pname: br,
|
@@ -10426,8 +10428,8 @@ function Zt() {
|
|
10426
10428
|
m_subtype: Zr,
|
10427
10429
|
m_parameter: qn,
|
10428
10430
|
m_value: Vn,
|
10429
|
-
CSeq:
|
10430
|
-
CSeq_value:
|
10431
|
+
CSeq: Cl,
|
10432
|
+
CSeq_value: Al,
|
10431
10433
|
Expires: Rl,
|
10432
10434
|
Event: Qa,
|
10433
10435
|
event_type: on,
|
@@ -10484,9 +10486,9 @@ function Zt() {
|
|
10484
10486
|
transport: Ei,
|
10485
10487
|
sent_by: Si,
|
10486
10488
|
via_host: yi,
|
10487
|
-
via_port:
|
10489
|
+
via_port: Ci,
|
10488
10490
|
ttl: tr,
|
10489
|
-
WWW_Authenticate:
|
10491
|
+
WWW_Authenticate: Ai,
|
10490
10492
|
Session_Expires: lo,
|
10491
10493
|
s_e_expires: Ol,
|
10492
10494
|
s_e_params: sr,
|
@@ -10538,11 +10540,11 @@ function Zt() {
|
|
10538
10540
|
var i;
|
10539
10541
|
return i = I(), i === null && (i = H()), i;
|
10540
10542
|
}
|
10541
|
-
function
|
10543
|
+
function C() {
|
10542
10544
|
var i;
|
10543
10545
|
return /^[\0-\xFF]/.test(n.charAt(s)) ? (i = n.charAt(s), s++) : (i = null, h("[\\0-\\xFF]")), i;
|
10544
10546
|
}
|
10545
|
-
function
|
10547
|
+
function A() {
|
10546
10548
|
var i;
|
10547
10549
|
return /^["]/.test(n.charAt(s)) ? (i = n.charAt(s), s++) : (i = null, h('["]')), i;
|
10548
10550
|
}
|
@@ -10667,13 +10669,13 @@ function Zt() {
|
|
10667
10669
|
}
|
10668
10670
|
function se() {
|
10669
10671
|
var i;
|
10670
|
-
return n.charCodeAt(s) === 40 ? (i = "(", s++) : (i = null, h('"("')), i === null && (n.charCodeAt(s) === 41 ? (i = ")", s++) : (i = null, h('")"')), i === null && (n.charCodeAt(s) === 60 ? (i = "<", s++) : (i = null, h('"<"')), i === null && (n.charCodeAt(s) === 62 ? (i = ">", s++) : (i = null, h('">"')), i === null && (n.charCodeAt(s) === 64 ? (i = "@", s++) : (i = null, h('"@"')), i === null && (n.charCodeAt(s) === 44 ? (i = ",", s++) : (i = null, h('","')), i === null && (n.charCodeAt(s) === 59 ? (i = ";", s++) : (i = null, h('";"')), i === null && (n.charCodeAt(s) === 58 ? (i = ":", s++) : (i = null, h('":"')), i === null && (n.charCodeAt(s) === 92 ? (i = "\\", s++) : (i = null, h('"\\\\"')), i === null && (i =
|
10672
|
+
return n.charCodeAt(s) === 40 ? (i = "(", s++) : (i = null, h('"("')), i === null && (n.charCodeAt(s) === 41 ? (i = ")", s++) : (i = null, h('")"')), i === null && (n.charCodeAt(s) === 60 ? (i = "<", s++) : (i = null, h('"<"')), i === null && (n.charCodeAt(s) === 62 ? (i = ">", s++) : (i = null, h('">"')), i === null && (n.charCodeAt(s) === 64 ? (i = "@", s++) : (i = null, h('"@"')), i === null && (n.charCodeAt(s) === 44 ? (i = ",", s++) : (i = null, h('","')), i === null && (n.charCodeAt(s) === 59 ? (i = ";", s++) : (i = null, h('";"')), i === null && (n.charCodeAt(s) === 58 ? (i = ":", s++) : (i = null, h('":"')), i === null && (n.charCodeAt(s) === 92 ? (i = "\\", s++) : (i = null, h('"\\\\"')), i === null && (i = A(), i === null && (n.charCodeAt(s) === 47 ? (i = "/", s++) : (i = null, h('"/"')), i === null && (n.charCodeAt(s) === 91 ? (i = "[", s++) : (i = null, h('"["')), i === null && (n.charCodeAt(s) === 93 ? (i = "]", s++) : (i = null, h('"]"')), i === null && (n.charCodeAt(s) === 63 ? (i = "?", s++) : (i = null, h('"?"')), i === null && (n.charCodeAt(s) === 61 ? (i = "=", s++) : (i = null, h('"="')), i === null && (n.charCodeAt(s) === 123 ? (i = "{", s++) : (i = null, h('"{"')), i === null && (n.charCodeAt(s) === 125 ? (i = "}", s++) : (i = null, h('"}"')), i === null && (i = I(), i === null && (i = H())))))))))))))))))), i;
|
10671
10673
|
}
|
10672
10674
|
function st() {
|
10673
10675
|
var i, e, l;
|
10674
|
-
if (l = s, e = $(), e === null && (n.charCodeAt(s) === 45 ? (e = "-", s++) : (e = null, h('"-"')), e === null && (n.charCodeAt(s) === 46 ? (e = ".", s++) : (e = null, h('"."')), e === null && (n.charCodeAt(s) === 33 ? (e = "!", s++) : (e = null, h('"!"')), e === null && (n.charCodeAt(s) === 37 ? (e = "%", s++) : (e = null, h('"%"')), e === null && (n.charCodeAt(s) === 42 ? (e = "*", s++) : (e = null, h('"*"')), e === null && (n.charCodeAt(s) === 95 ? (e = "_", s++) : (e = null, h('"_"')), e === null && (n.charCodeAt(s) === 43 ? (e = "+", s++) : (e = null, h('"+"')), e === null && (n.charCodeAt(s) === 96 ? (e = "`", s++) : (e = null, h('"`"')), e === null && (n.charCodeAt(s) === 39 ? (e = "'", s++) : (e = null, h(`"'"`)), e === null && (n.charCodeAt(s) === 126 ? (e = "~", s++) : (e = null, h('"~"')), e === null && (n.charCodeAt(s) === 40 ? (e = "(", s++) : (e = null, h('"("')), e === null && (n.charCodeAt(s) === 41 ? (e = ")", s++) : (e = null, h('")"')), e === null && (n.charCodeAt(s) === 60 ? (e = "<", s++) : (e = null, h('"<"')), e === null && (n.charCodeAt(s) === 62 ? (e = ">", s++) : (e = null, h('">"')), e === null && (n.charCodeAt(s) === 58 ? (e = ":", s++) : (e = null, h('":"')), e === null && (n.charCodeAt(s) === 92 ? (e = "\\", s++) : (e = null, h('"\\\\"')), e === null && (e =
|
10676
|
+
if (l = s, e = $(), e === null && (n.charCodeAt(s) === 45 ? (e = "-", s++) : (e = null, h('"-"')), e === null && (n.charCodeAt(s) === 46 ? (e = ".", s++) : (e = null, h('"."')), e === null && (n.charCodeAt(s) === 33 ? (e = "!", s++) : (e = null, h('"!"')), e === null && (n.charCodeAt(s) === 37 ? (e = "%", s++) : (e = null, h('"%"')), e === null && (n.charCodeAt(s) === 42 ? (e = "*", s++) : (e = null, h('"*"')), e === null && (n.charCodeAt(s) === 95 ? (e = "_", s++) : (e = null, h('"_"')), e === null && (n.charCodeAt(s) === 43 ? (e = "+", s++) : (e = null, h('"+"')), e === null && (n.charCodeAt(s) === 96 ? (e = "`", s++) : (e = null, h('"`"')), e === null && (n.charCodeAt(s) === 39 ? (e = "'", s++) : (e = null, h(`"'"`)), e === null && (n.charCodeAt(s) === 126 ? (e = "~", s++) : (e = null, h('"~"')), e === null && (n.charCodeAt(s) === 40 ? (e = "(", s++) : (e = null, h('"("')), e === null && (n.charCodeAt(s) === 41 ? (e = ")", s++) : (e = null, h('")"')), e === null && (n.charCodeAt(s) === 60 ? (e = "<", s++) : (e = null, h('"<"')), e === null && (n.charCodeAt(s) === 62 ? (e = ">", s++) : (e = null, h('">"')), e === null && (n.charCodeAt(s) === 58 ? (e = ":", s++) : (e = null, h('":"')), e === null && (n.charCodeAt(s) === 92 ? (e = "\\", s++) : (e = null, h('"\\\\"')), e === null && (e = A(), e === null && (n.charCodeAt(s) === 47 ? (e = "/", s++) : (e = null, h('"/"')), e === null && (n.charCodeAt(s) === 91 ? (e = "[", s++) : (e = null, h('"["')), e === null && (n.charCodeAt(s) === 93 ? (e = "]", s++) : (e = null, h('"]"')), e === null && (n.charCodeAt(s) === 63 ? (e = "?", s++) : (e = null, h('"?"')), e === null && (n.charCodeAt(s) === 123 ? (e = "{", s++) : (e = null, h('"{"')), e === null && (n.charCodeAt(s) === 125 ? (e = "}", s++) : (e = null, h('"}"'))))))))))))))))))))))))), e !== null)
|
10675
10677
|
for (i = []; e !== null; )
|
10676
|
-
i.push(e), e = $(), e === null && (n.charCodeAt(s) === 45 ? (e = "-", s++) : (e = null, h('"-"')), e === null && (n.charCodeAt(s) === 46 ? (e = ".", s++) : (e = null, h('"."')), e === null && (n.charCodeAt(s) === 33 ? (e = "!", s++) : (e = null, h('"!"')), e === null && (n.charCodeAt(s) === 37 ? (e = "%", s++) : (e = null, h('"%"')), e === null && (n.charCodeAt(s) === 42 ? (e = "*", s++) : (e = null, h('"*"')), e === null && (n.charCodeAt(s) === 95 ? (e = "_", s++) : (e = null, h('"_"')), e === null && (n.charCodeAt(s) === 43 ? (e = "+", s++) : (e = null, h('"+"')), e === null && (n.charCodeAt(s) === 96 ? (e = "`", s++) : (e = null, h('"`"')), e === null && (n.charCodeAt(s) === 39 ? (e = "'", s++) : (e = null, h(`"'"`)), e === null && (n.charCodeAt(s) === 126 ? (e = "~", s++) : (e = null, h('"~"')), e === null && (n.charCodeAt(s) === 40 ? (e = "(", s++) : (e = null, h('"("')), e === null && (n.charCodeAt(s) === 41 ? (e = ")", s++) : (e = null, h('")"')), e === null && (n.charCodeAt(s) === 60 ? (e = "<", s++) : (e = null, h('"<"')), e === null && (n.charCodeAt(s) === 62 ? (e = ">", s++) : (e = null, h('">"')), e === null && (n.charCodeAt(s) === 58 ? (e = ":", s++) : (e = null, h('":"')), e === null && (n.charCodeAt(s) === 92 ? (e = "\\", s++) : (e = null, h('"\\\\"')), e === null && (e =
|
10678
|
+
i.push(e), e = $(), e === null && (n.charCodeAt(s) === 45 ? (e = "-", s++) : (e = null, h('"-"')), e === null && (n.charCodeAt(s) === 46 ? (e = ".", s++) : (e = null, h('"."')), e === null && (n.charCodeAt(s) === 33 ? (e = "!", s++) : (e = null, h('"!"')), e === null && (n.charCodeAt(s) === 37 ? (e = "%", s++) : (e = null, h('"%"')), e === null && (n.charCodeAt(s) === 42 ? (e = "*", s++) : (e = null, h('"*"')), e === null && (n.charCodeAt(s) === 95 ? (e = "_", s++) : (e = null, h('"_"')), e === null && (n.charCodeAt(s) === 43 ? (e = "+", s++) : (e = null, h('"+"')), e === null && (n.charCodeAt(s) === 96 ? (e = "`", s++) : (e = null, h('"`"')), e === null && (n.charCodeAt(s) === 39 ? (e = "'", s++) : (e = null, h(`"'"`)), e === null && (n.charCodeAt(s) === 126 ? (e = "~", s++) : (e = null, h('"~"')), e === null && (n.charCodeAt(s) === 40 ? (e = "(", s++) : (e = null, h('"("')), e === null && (n.charCodeAt(s) === 41 ? (e = ")", s++) : (e = null, h('")"')), e === null && (n.charCodeAt(s) === 60 ? (e = "<", s++) : (e = null, h('"<"')), e === null && (n.charCodeAt(s) === 62 ? (e = ">", s++) : (e = null, h('">"')), e === null && (n.charCodeAt(s) === 58 ? (e = ":", s++) : (e = null, h('":"')), e === null && (n.charCodeAt(s) === 92 ? (e = "\\", s++) : (e = null, h('"\\\\"')), e === null && (e = A(), e === null && (n.charCodeAt(s) === 47 ? (e = "/", s++) : (e = null, h('"/"')), e === null && (n.charCodeAt(s) === 91 ? (e = "[", s++) : (e = null, h('"["')), e === null && (n.charCodeAt(s) === 93 ? (e = "]", s++) : (e = null, h('"]"')), e === null && (n.charCodeAt(s) === 63 ? (e = "?", s++) : (e = null, h('"?"')), e === null && (n.charCodeAt(s) === 123 ? (e = "{", s++) : (e = null, h('"{"')), e === null && (n.charCodeAt(s) === 125 ? (e = "}", s++) : (e = null, h('"}"')))))))))))))))))))))))));
|
10677
10679
|
else
|
10678
10680
|
i = null;
|
10679
10681
|
return i !== null && (i = function(u) {
|
@@ -10722,7 +10724,7 @@ function Zt() {
|
|
10722
10724
|
return "<";
|
10723
10725
|
}()), i === null && (s = l), i;
|
10724
10726
|
}
|
10725
|
-
function
|
10727
|
+
function Ae() {
|
10726
10728
|
var i, e, l, u, f;
|
10727
10729
|
return u = s, f = s, i = k(), i !== null ? (n.charCodeAt(s) === 44 ? (e = ",", s++) : (e = null, h('","')), e !== null ? (l = k(), l !== null ? i = [i, e, l] : (i = null, s = f)) : (i = null, s = f)) : (i = null, s = f), i !== null && (i = function(p) {
|
10728
10730
|
return ",";
|
@@ -10742,37 +10744,37 @@ function Zt() {
|
|
10742
10744
|
}
|
10743
10745
|
function nt() {
|
10744
10746
|
var i, e, l, u;
|
10745
|
-
return l = s, u = s, i = k(), i !== null ? (e =
|
10747
|
+
return l = s, u = s, i = k(), i !== null ? (e = A(), e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i !== null && (i = function(f) {
|
10746
10748
|
return '"';
|
10747
10749
|
}()), i === null && (s = l), i;
|
10748
10750
|
}
|
10749
10751
|
function at() {
|
10750
10752
|
var i, e, l, u;
|
10751
|
-
return l = s, u = s, i =
|
10753
|
+
return l = s, u = s, i = A(), i !== null ? (e = k(), e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i !== null && (i = function(f) {
|
10752
10754
|
return '"';
|
10753
10755
|
}()), i === null && (s = l), i;
|
10754
10756
|
}
|
10755
10757
|
function Ee() {
|
10756
10758
|
var i, e, l, u;
|
10757
10759
|
if (u = s, i = re(), i !== null) {
|
10758
|
-
for (e = [], l =
|
10759
|
-
e.push(l), l =
|
10760
|
+
for (e = [], l = Ce(), l === null && (l = ue(), l === null && (l = Ee())); l !== null; )
|
10761
|
+
e.push(l), l = Ce(), l === null && (l = ue(), l === null && (l = Ee()));
|
10760
10762
|
e !== null ? (l = ge(), l !== null ? i = [i, e, l] : (i = null, s = u)) : (i = null, s = u);
|
10761
10763
|
} else
|
10762
10764
|
i = null, s = u;
|
10763
10765
|
return i;
|
10764
10766
|
}
|
10765
|
-
function
|
10767
|
+
function Ce() {
|
10766
10768
|
var i;
|
10767
10769
|
return /^[!-']/.test(n.charAt(s)) ? (i = n.charAt(s), s++) : (i = null, h("[!-']")), i === null && (/^[*-[]/.test(n.charAt(s)) ? (i = n.charAt(s), s++) : (i = null, h("[*-[]")), i === null && (/^[\]-~]/.test(n.charAt(s)) ? (i = n.charAt(s), s++) : (i = null, h("[\\]-~]")), i === null && (i = J(), i === null && (i = ve())))), i;
|
10768
10770
|
}
|
10769
10771
|
function Ie() {
|
10770
10772
|
var i, e, l, u, f, p;
|
10771
10773
|
if (f = s, p = s, i = k(), i !== null)
|
10772
|
-
if (e =
|
10774
|
+
if (e = A(), e !== null) {
|
10773
10775
|
for (l = [], u = pe(), u === null && (u = ue()); u !== null; )
|
10774
10776
|
l.push(u), u = pe(), u === null && (u = ue());
|
10775
|
-
l !== null ? (u =
|
10777
|
+
l !== null ? (u = A(), u !== null ? i = [i, e, l, u] : (i = null, s = p)) : (i = null, s = p);
|
10776
10778
|
} else
|
10777
10779
|
i = null, s = p;
|
10778
10780
|
else
|
@@ -10784,10 +10786,10 @@ function Zt() {
|
|
10784
10786
|
function Oe() {
|
10785
10787
|
var i, e, l, u, f, p;
|
10786
10788
|
if (f = s, p = s, i = k(), i !== null)
|
10787
|
-
if (e =
|
10789
|
+
if (e = A(), e !== null) {
|
10788
10790
|
for (l = [], u = pe(), u === null && (u = ue()); u !== null; )
|
10789
10791
|
l.push(u), u = pe(), u === null && (u = ue());
|
10790
|
-
l !== null ? (u =
|
10792
|
+
l !== null ? (u = A(), u !== null ? i = [i, e, l, u] : (i = null, s = p)) : (i = null, s = p);
|
10791
10793
|
} else
|
10792
10794
|
i = null, s = p;
|
10793
10795
|
else
|
@@ -10870,7 +10872,7 @@ function Zt() {
|
|
10870
10872
|
}
|
10871
10873
|
function Ys() {
|
10872
10874
|
var i, e, l, u, f;
|
10873
|
-
return u = s, i = es(), i !== null ? (f = s, n.charCodeAt(s) === 58 ? (e = ":", s++) : (e = null, h('":"')), e !== null ? (l =
|
10875
|
+
return u = s, i = es(), i !== null ? (f = s, n.charCodeAt(s) === 58 ? (e = ":", s++) : (e = null, h('":"')), e !== null ? (l = As(), l !== null ? e = [e, l] : (e = null, s = f)) : (e = null, s = f), e = e !== null ? e : "", e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i;
|
10874
10876
|
}
|
10875
10877
|
function es() {
|
10876
10878
|
var i, e;
|
@@ -10936,7 +10938,7 @@ function Zt() {
|
|
10936
10938
|
var i, e, l, u;
|
10937
10939
|
return u = s, n.substr(s, 2) === "25" ? (i = "25", s += 2) : (i = null, h('"25"')), i !== null ? (/^[0-5]/.test(n.charAt(s)) ? (e = n.charAt(s), s++) : (e = null, h("[0-5]")), e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i === null && (u = s, n.charCodeAt(s) === 50 ? (i = "2", s++) : (i = null, h('"2"')), i !== null ? (/^[0-4]/.test(n.charAt(s)) ? (e = n.charAt(s), s++) : (e = null, h("[0-4]")), e !== null ? (l = g(), l !== null ? i = [i, e, l] : (i = null, s = u)) : (i = null, s = u)) : (i = null, s = u), i === null && (u = s, n.charCodeAt(s) === 49 ? (i = "1", s++) : (i = null, h('"1"')), i !== null ? (e = g(), e !== null ? (l = g(), l !== null ? i = [i, e, l] : (i = null, s = u)) : (i = null, s = u)) : (i = null, s = u), i === null && (u = s, /^[1-9]/.test(n.charAt(s)) ? (i = n.charAt(s), s++) : (i = null, h("[1-9]")), i !== null ? (e = g(), e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i === null && (i = g())))), i;
|
10938
10940
|
}
|
10939
|
-
function
|
10941
|
+
function As() {
|
10940
10942
|
var i, e, l, u, f, p, m;
|
10941
10943
|
return p = s, m = s, i = g(), i = i !== null ? i : "", i !== null ? (e = g(), e = e !== null ? e : "", e !== null ? (l = g(), l = l !== null ? l : "", l !== null ? (u = g(), u = u !== null ? u : "", u !== null ? (f = g(), f = f !== null ? f : "", f !== null ? i = [i, e, l, u, f] : (i = null, s = m)) : (i = null, s = m)) : (i = null, s = m)) : (i = null, s = m)) : (i = null, s = m), i !== null && (i = function(v, S) {
|
10942
10944
|
return S = parseInt(S.join("")), b.port = S, S;
|
@@ -10950,7 +10952,7 @@ function Zt() {
|
|
10950
10952
|
}
|
10951
10953
|
function Un() {
|
10952
10954
|
var i;
|
10953
|
-
return i = Pn(), i === null && (i = Sr(), i === null && (i = yr(), i === null && (i =
|
10955
|
+
return i = Pn(), i === null && (i = Sr(), i === null && (i = yr(), i === null && (i = Cr(), i === null && (i = Ar(), i === null && (i = Rr(), i === null && (i = Ir())))))), i;
|
10954
10956
|
}
|
10955
10957
|
function Pn() {
|
10956
10958
|
var i, e, l, u;
|
@@ -10970,13 +10972,13 @@ function Zt() {
|
|
10970
10972
|
b.uri_params || (b.uri_params = {}), b.uri_params.method = p;
|
10971
10973
|
}(l, i[1])), i === null && (s = l), i;
|
10972
10974
|
}
|
10973
|
-
function
|
10975
|
+
function Cr() {
|
10974
10976
|
var i, e, l, u;
|
10975
10977
|
return l = s, u = s, n.substr(s, 4).toLowerCase() === "ttl=" ? (i = n.substr(s, 4), s += 4) : (i = null, h('"ttl="')), i !== null ? (e = tr(), e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i !== null && (i = function(f, p) {
|
10976
10978
|
b.params || (b.params = {}), b.params.ttl = p;
|
10977
10979
|
}(l, i[1])), i === null && (s = l), i;
|
10978
10980
|
}
|
10979
|
-
function
|
10981
|
+
function Ar() {
|
10980
10982
|
var i, e, l, u;
|
10981
10983
|
return l = s, u = s, n.substr(s, 6).toLowerCase() === "maddr=" ? (i = n.substr(s, 6), s += 6) : (i = null, h('"maddr="')), i !== null ? (e = es(), e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i !== null && (i = function(f, p) {
|
10982
10984
|
b.uri_params || (b.uri_params = {}), b.uri_params.maddr = p;
|
@@ -11271,8 +11273,8 @@ function Zt() {
|
|
11271
11273
|
function Tl() {
|
11272
11274
|
var i, e, l, u, f, p;
|
11273
11275
|
if (f = s, i = on(), i !== null) {
|
11274
|
-
for (e = [], p = s, l =
|
11275
|
-
e.push(l), p = s, l =
|
11276
|
+
for (e = [], p = s, l = Ae(), l !== null ? (u = on(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p); l !== null; )
|
11277
|
+
e.push(l), p = s, l = Ae(), l !== null ? (u = on(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p);
|
11276
11278
|
e !== null ? i = [i, e] : (i = null, s = f);
|
11277
11279
|
} else
|
11278
11280
|
i = null, s = f;
|
@@ -11288,8 +11290,8 @@ function Zt() {
|
|
11288
11290
|
var i, e, l, u, f, p, m;
|
11289
11291
|
if (f = s, i = ee(), i === null)
|
11290
11292
|
if (p = s, i = $n(), i !== null) {
|
11291
|
-
for (e = [], m = s, l =
|
11292
|
-
e.push(l), m = s, l =
|
11293
|
+
for (e = [], m = s, l = Ae(), l !== null ? (u = $n(), u !== null ? l = [l, u] : (l = null, s = m)) : (l = null, s = m); l !== null; )
|
11294
|
+
e.push(l), m = s, l = Ae(), l !== null ? (u = $n(), u !== null ? l = [l, u] : (l = null, s = m)) : (l = null, s = m);
|
11293
11295
|
e !== null ? i = [i, e] : (i = null, s = p);
|
11294
11296
|
} else
|
11295
11297
|
i = null, s = p;
|
@@ -11412,8 +11414,8 @@ function Zt() {
|
|
11412
11414
|
function Sl() {
|
11413
11415
|
var i, e, l, u, f, p;
|
11414
11416
|
if (f = s, i = U(), i !== null) {
|
11415
|
-
for (e = [], p = s, l =
|
11416
|
-
e.push(l), p = s, l =
|
11417
|
+
for (e = [], p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p); l !== null; )
|
11418
|
+
e.push(l), p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p);
|
11417
11419
|
e !== null ? i = [i, e] : (i = null, s = f);
|
11418
11420
|
} else
|
11419
11421
|
i = null, s = f;
|
@@ -11484,11 +11486,11 @@ function Zt() {
|
|
11484
11486
|
var i;
|
11485
11487
|
return i = U(), i === null && (i = Ie()), i;
|
11486
11488
|
}
|
11487
|
-
function
|
11489
|
+
function Cl() {
|
11488
11490
|
var i, e, l, u;
|
11489
|
-
return u = s, i =
|
11491
|
+
return u = s, i = Al(), i !== null ? (e = ve(), e !== null ? (l = nn(), l !== null ? i = [i, e, l] : (i = null, s = u)) : (i = null, s = u)) : (i = null, s = u), i;
|
11490
11492
|
}
|
11491
|
-
function
|
11493
|
+
function Al() {
|
11492
11494
|
var i, e, l;
|
11493
11495
|
if (l = s, e = g(), e !== null)
|
11494
11496
|
for (i = []; e !== null; )
|
@@ -11607,8 +11609,8 @@ function Zt() {
|
|
11607
11609
|
if (m = s, n.substr(s, 6).toLowerCase() === "digest" ? (i = n.substr(s, 6), s += 6) : (i = null, h('"Digest"')), i !== null)
|
11608
11610
|
if (e = ve(), e !== null)
|
11609
11611
|
if (l = ns(), l !== null) {
|
11610
|
-
for (u = [], v = s, f =
|
11611
|
-
u.push(f), v = s, f =
|
11612
|
+
for (u = [], v = s, f = Ae(), f !== null ? (p = ns(), p !== null ? f = [f, p] : (f = null, s = v)) : (f = null, s = v); f !== null; )
|
11613
|
+
u.push(f), v = s, f = Ae(), f !== null ? (p = ns(), p !== null ? f = [f, p] : (f = null, s = v)) : (f = null, s = v);
|
11612
11614
|
u !== null ? i = [i, e, l, u] : (i = null, s = m);
|
11613
11615
|
} else
|
11614
11616
|
i = null, s = m;
|
@@ -11623,8 +11625,8 @@ function Zt() {
|
|
11623
11625
|
if (m = s, i = U(), i !== null)
|
11624
11626
|
if (e = ve(), e !== null)
|
11625
11627
|
if (l = Ps(), l !== null) {
|
11626
|
-
for (u = [], v = s, f =
|
11627
|
-
u.push(f), v = s, f =
|
11628
|
+
for (u = [], v = s, f = Ae(), f !== null ? (p = Ps(), p !== null ? f = [f, p] : (f = null, s = v)) : (f = null, s = v); f !== null; )
|
11629
|
+
u.push(f), v = s, f = Ae(), f !== null ? (p = Ps(), p !== null ? f = [f, p] : (f = null, s = v)) : (f = null, s = v);
|
11628
11630
|
u !== null ? i = [i, e, l, u] : (i = null, s = m);
|
11629
11631
|
} else
|
11630
11632
|
i = null, s = m;
|
@@ -11745,8 +11747,8 @@ function Zt() {
|
|
11745
11747
|
function Gn() {
|
11746
11748
|
var i, e, l, u, f, p;
|
11747
11749
|
if (f = s, i = U(), i !== null) {
|
11748
|
-
for (e = [], p = s, l =
|
11749
|
-
e.push(l), p = s, l =
|
11750
|
+
for (e = [], p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p); l !== null; )
|
11751
|
+
e.push(l), p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p);
|
11750
11752
|
e !== null ? i = [i, e] : (i = null, s = f);
|
11751
11753
|
} else
|
11752
11754
|
i = null, s = f;
|
@@ -11755,8 +11757,8 @@ function Zt() {
|
|
11755
11757
|
function so() {
|
11756
11758
|
var i, e, l, u, f, p, m;
|
11757
11759
|
if (f = s, p = s, i = Wn(), i !== null) {
|
11758
|
-
for (e = [], m = s, l =
|
11759
|
-
e.push(l), m = s, l =
|
11760
|
+
for (e = [], m = s, l = Ae(), l !== null ? (u = Wn(), u !== null ? l = [l, u] : (l = null, s = m)) : (l = null, s = m); l !== null; )
|
11761
|
+
e.push(l), m = s, l = Ae(), l !== null ? (u = Wn(), u !== null ? l = [l, u] : (l = null, s = m)) : (l = null, s = m);
|
11760
11762
|
e !== null ? i = [i, e] : (i = null, s = p);
|
11761
11763
|
} else
|
11762
11764
|
i = null, s = p;
|
@@ -11833,8 +11835,8 @@ function Zt() {
|
|
11833
11835
|
function Il() {
|
11834
11836
|
var i, e, l, u, f, p;
|
11835
11837
|
if (f = s, i = U(), i !== null) {
|
11836
|
-
for (e = [], p = s, l =
|
11837
|
-
e.push(l), p = s, l =
|
11838
|
+
for (e = [], p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p); l !== null; )
|
11839
|
+
e.push(l), p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p);
|
11838
11840
|
e !== null ? i = [i, e] : (i = null, s = f);
|
11839
11841
|
} else
|
11840
11842
|
i = null, s = f;
|
@@ -11843,8 +11845,8 @@ function Zt() {
|
|
11843
11845
|
function no() {
|
11844
11846
|
var i, e, l, u, f, p;
|
11845
11847
|
if (f = s, i = Jn(), i !== null) {
|
11846
|
-
for (e = [], p = s, l =
|
11847
|
-
e.push(l), p = s, l =
|
11848
|
+
for (e = [], p = s, l = Ae(), l !== null ? (u = Jn(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p); l !== null; )
|
11849
|
+
e.push(l), p = s, l = Ae(), l !== null ? (u = Jn(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p);
|
11848
11850
|
e !== null ? i = [i, e] : (i = null, s = f);
|
11849
11851
|
} else
|
11850
11852
|
i = null, s = f;
|
@@ -11897,8 +11899,8 @@ function Zt() {
|
|
11897
11899
|
function ro() {
|
11898
11900
|
var i, e, l, u, f, p;
|
11899
11901
|
if (f = s, i = U(), i !== null) {
|
11900
|
-
for (e = [], p = s, l =
|
11901
|
-
e.push(l), p = s, l =
|
11902
|
+
for (e = [], p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p); l !== null; )
|
11903
|
+
e.push(l), p = s, l = Ae(), l !== null ? (u = U(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p);
|
11902
11904
|
e !== null ? i = [i, e] : (i = null, s = f);
|
11903
11905
|
} else
|
11904
11906
|
i = null, s = f;
|
@@ -11928,8 +11930,8 @@ function Zt() {
|
|
11928
11930
|
function hi() {
|
11929
11931
|
var i, e, l, u, f, p;
|
11930
11932
|
if (f = s, i = Zn(), i !== null) {
|
11931
|
-
for (e = [], p = s, l =
|
11932
|
-
e.push(l), p = s, l =
|
11933
|
+
for (e = [], p = s, l = Ae(), l !== null ? (u = Zn(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p); l !== null; )
|
11934
|
+
e.push(l), p = s, l = Ae(), l !== null ? (u = Zn(), u !== null ? l = [l, u] : (l = null, s = p)) : (l = null, s = p);
|
11933
11935
|
e !== null ? i = [i, e] : (i = null, s = f);
|
11934
11936
|
} else
|
11935
11937
|
i = null, s = f;
|
@@ -12007,7 +12009,7 @@ function Zt() {
|
|
12007
12009
|
}
|
12008
12010
|
function Si() {
|
12009
12011
|
var i, e, l, u, f;
|
12010
|
-
return u = s, i = yi(), i !== null ? (f = s, e = ye(), e !== null ? (l =
|
12012
|
+
return u = s, i = yi(), i !== null ? (f = s, e = ye(), e !== null ? (l = Ci(), l !== null ? e = [e, l] : (e = null, s = f)) : (e = null, s = f), e = e !== null ? e : "", e !== null ? i = [i, e] : (i = null, s = u)) : (i = null, s = u), i;
|
12011
12013
|
}
|
12012
12014
|
function yi() {
|
12013
12015
|
var i, e;
|
@@ -12015,7 +12017,7 @@ function Zt() {
|
|
12015
12017
|
b.host = n.substring(s, l);
|
12016
12018
|
}(e)), i === null && (s = e), i;
|
12017
12019
|
}
|
12018
|
-
function
|
12020
|
+
function Ci() {
|
12019
12021
|
var i, e, l, u, f, p, m;
|
12020
12022
|
return p = s, m = s, i = g(), i = i !== null ? i : "", i !== null ? (e = g(), e = e !== null ? e : "", e !== null ? (l = g(), l = l !== null ? l : "", l !== null ? (u = g(), u = u !== null ? u : "", u !== null ? (f = g(), f = f !== null ? f : "", f !== null ? i = [i, e, l, u, f] : (i = null, s = m)) : (i = null, s = m)) : (i = null, s = m)) : (i = null, s = m)) : (i = null, s = m), i !== null && (i = function(v, S) {
|
12021
12023
|
b.port = parseInt(S.join(""));
|
@@ -12027,7 +12029,7 @@ function Zt() {
|
|
12027
12029
|
return parseInt(m.join(""));
|
12028
12030
|
}(u, i)), i === null && (s = u), i;
|
12029
12031
|
}
|
12030
|
-
function
|
12032
|
+
function Ai() {
|
12031
12033
|
var i;
|
12032
12034
|
return i = si(), i;
|
12033
12035
|
}
|
@@ -12069,8 +12071,8 @@ function Zt() {
|
|
12069
12071
|
}
|
12070
12072
|
function Ul() {
|
12071
12073
|
var i, e;
|
12072
|
-
for (i = [], e =
|
12073
|
-
i.push(e), e =
|
12074
|
+
for (i = [], e = C(); e !== null; )
|
12075
|
+
i.push(e), e = C();
|
12074
12076
|
return i;
|
12075
12077
|
}
|
12076
12078
|
function ao() {
|
@@ -12205,7 +12207,7 @@ function ys() {
|
|
12205
12207
|
if (sf)
|
12206
12208
|
return Mo;
|
12207
12209
|
sf = 1;
|
12208
|
-
const c = De, t =
|
12210
|
+
const c = De, t = Ct(), n = Zt();
|
12209
12211
|
return Mo = class ch {
|
12210
12212
|
/**
|
12211
12213
|
* Parse the given string and returns a JsSIP.URI instance or undefined if
|
@@ -12317,7 +12319,7 @@ function ys() {
|
|
12317
12319
|
}, Mo;
|
12318
12320
|
}
|
12319
12321
|
var nf;
|
12320
|
-
function
|
12322
|
+
function Ct() {
|
12321
12323
|
if (nf)
|
12322
12324
|
return et;
|
12323
12325
|
nf = 1;
|
@@ -12396,63 +12398,63 @@ function At() {
|
|
12396
12398
|
}
|
12397
12399
|
return `192.0.2.${r(1, 254)}`;
|
12398
12400
|
}, et.calculateMD5 = (r) => {
|
12399
|
-
function d(Ee,
|
12400
|
-
return Ee <<
|
12401
|
+
function d(Ee, Ce) {
|
12402
|
+
return Ee << Ce | Ee >>> 32 - Ce;
|
12401
12403
|
}
|
12402
|
-
function h(Ee,
|
12403
|
-
const Ie = Ee & 2147483648, Oe =
|
12404
|
+
function h(Ee, Ce) {
|
12405
|
+
const Ie = Ee & 2147483648, Oe = Ce & 2147483648, pe = Ee & 1073741824, ue = Ce & 1073741824, _e = (Ee & 1073741823) + (Ce & 1073741823);
|
12404
12406
|
return pe & ue ? _e ^ 2147483648 ^ Ie ^ Oe : pe | ue ? _e & 1073741824 ? _e ^ 3221225472 ^ Ie ^ Oe : _e ^ 1073741824 ^ Ie ^ Oe : _e ^ Ie ^ Oe;
|
12405
12407
|
}
|
12406
|
-
function _(Ee,
|
12407
|
-
return Ee &
|
12408
|
+
function _(Ee, Ce, Ie) {
|
12409
|
+
return Ee & Ce | ~Ee & Ie;
|
12408
12410
|
}
|
12409
|
-
function g(Ee,
|
12410
|
-
return Ee & Ie |
|
12411
|
+
function g(Ee, Ce, Ie) {
|
12412
|
+
return Ee & Ie | Ce & ~Ie;
|
12411
12413
|
}
|
12412
|
-
function T(Ee,
|
12413
|
-
return Ee ^
|
12414
|
+
function T(Ee, Ce, Ie) {
|
12415
|
+
return Ee ^ Ce ^ Ie;
|
12414
12416
|
}
|
12415
|
-
function E(Ee,
|
12416
|
-
return
|
12417
|
+
function E(Ee, Ce, Ie) {
|
12418
|
+
return Ce ^ (Ee | ~Ie);
|
12417
12419
|
}
|
12418
|
-
function y(Ee,
|
12419
|
-
return Ee = h(Ee, h(h(_(
|
12420
|
+
function y(Ee, Ce, Ie, Oe, pe, ue, _e) {
|
12421
|
+
return Ee = h(Ee, h(h(_(Ce, Ie, Oe), pe), _e)), h(d(Ee, ue), Ce);
|
12420
12422
|
}
|
12421
|
-
function
|
12422
|
-
return Ee = h(Ee, h(h(g(
|
12423
|
+
function C(Ee, Ce, Ie, Oe, pe, ue, _e) {
|
12424
|
+
return Ee = h(Ee, h(h(g(Ce, Ie, Oe), pe), _e)), h(d(Ee, ue), Ce);
|
12423
12425
|
}
|
12424
|
-
function
|
12425
|
-
return Ee = h(Ee, h(h(T(
|
12426
|
+
function A(Ee, Ce, Ie, Oe, pe, ue, _e) {
|
12427
|
+
return Ee = h(Ee, h(h(T(Ce, Ie, Oe), pe), _e)), h(d(Ee, ue), Ce);
|
12426
12428
|
}
|
12427
|
-
function I(Ee,
|
12428
|
-
return Ee = h(Ee, h(h(E(
|
12429
|
+
function I(Ee, Ce, Ie, Oe, pe, ue, _e) {
|
12430
|
+
return Ee = h(Ee, h(h(E(Ce, Ie, Oe), pe), _e)), h(d(Ee, ue), Ce);
|
12429
12431
|
}
|
12430
12432
|
function H(Ee) {
|
12431
|
-
let
|
12433
|
+
let Ce;
|
12432
12434
|
const Ie = Ee.length, Oe = Ie + 8, ue = ((Oe - Oe % 64) / 64 + 1) * 16, _e = new Array(ue - 1);
|
12433
12435
|
let we = 0, Ne = 0;
|
12434
12436
|
for (; Ne < Ie; )
|
12435
|
-
|
12436
|
-
return
|
12437
|
+
Ce = (Ne - Ne % 4) / 4, we = Ne % 4 * 8, _e[Ce] = _e[Ce] | Ee.charCodeAt(Ne) << we, Ne++;
|
12438
|
+
return Ce = (Ne - Ne % 4) / 4, we = Ne % 4 * 8, _e[Ce] = _e[Ce] | 128 << we, _e[ue - 2] = Ie << 3, _e[ue - 1] = Ie >>> 29, _e;
|
12437
12439
|
}
|
12438
12440
|
function $(Ee) {
|
12439
|
-
let
|
12441
|
+
let Ce = "", Ie = "", Oe, pe;
|
12440
12442
|
for (pe = 0; pe <= 3; pe++)
|
12441
|
-
Oe = Ee >>> pe * 8 & 255, Ie = `0${Oe.toString(16)}`,
|
12442
|
-
return
|
12443
|
+
Oe = Ee >>> pe * 8 & 255, Ie = `0${Oe.toString(16)}`, Ce = Ce + Ie.substr(Ie.length - 2, 2);
|
12444
|
+
return Ce;
|
12443
12445
|
}
|
12444
12446
|
function oe(Ee) {
|
12445
|
-
let
|
12447
|
+
let Ce = "";
|
12446
12448
|
for (let Ie = 0; Ie < Ee.length; Ie++) {
|
12447
12449
|
const Oe = Ee.charCodeAt(Ie);
|
12448
|
-
Oe < 128 ?
|
12450
|
+
Oe < 128 ? Ce += String.fromCharCode(Oe) : Oe > 127 && Oe < 2048 ? (Ce += String.fromCharCode(Oe >> 6 | 192), Ce += String.fromCharCode(Oe & 63 | 128)) : (Ce += String.fromCharCode(Oe >> 12 | 224), Ce += String.fromCharCode(Oe >> 6 & 63 | 128), Ce += String.fromCharCode(Oe & 63 | 128));
|
12449
12451
|
}
|
12450
|
-
return
|
12452
|
+
return Ce;
|
12451
12453
|
}
|
12452
12454
|
let N = [], j, Se, ve, k, D, B, V, J, F;
|
12453
|
-
const X = 7, U = 12, P = 17, se = 22, st = 5, ee = 9, W = 14, G = 20, re = 4, ge = 11, be = 16, xe = 23,
|
12455
|
+
const X = 7, U = 12, P = 17, se = 22, st = 5, ee = 9, W = 14, G = 20, re = 4, ge = 11, be = 16, xe = 23, Ae = 6, le = 10, ye = 15, nt = 21;
|
12454
12456
|
for (r = oe(r), N = H(r), B = 1732584193, V = 4023233417, J = 2562383102, F = 271733878, j = 0; j < N.length; j += 16)
|
12455
|
-
Se = B, ve = V, k = J, D = F, B = y(B, V, J, F, N[j + 0], X, 3614090360), F = y(F, B, V, J, N[j + 1], U, 3905402710), J = y(J, F, B, V, N[j + 2], P, 606105819), V = y(V, J, F, B, N[j + 3], se, 3250441966), B = y(B, V, J, F, N[j + 4], X, 4118548399), F = y(F, B, V, J, N[j + 5], U, 1200080426), J = y(J, F, B, V, N[j + 6], P, 2821735955), V = y(V, J, F, B, N[j + 7], se, 4249261313), B = y(B, V, J, F, N[j + 8], X, 1770035416), F = y(F, B, V, J, N[j + 9], U, 2336552879), J = y(J, F, B, V, N[j + 10], P, 4294925233), V = y(V, J, F, B, N[j + 11], se, 2304563134), B = y(B, V, J, F, N[j + 12], X, 1804603682), F = y(F, B, V, J, N[j + 13], U, 4254626195), J = y(J, F, B, V, N[j + 14], P, 2792965006), V = y(V, J, F, B, N[j + 15], se, 1236535329), B =
|
12457
|
+
Se = B, ve = V, k = J, D = F, B = y(B, V, J, F, N[j + 0], X, 3614090360), F = y(F, B, V, J, N[j + 1], U, 3905402710), J = y(J, F, B, V, N[j + 2], P, 606105819), V = y(V, J, F, B, N[j + 3], se, 3250441966), B = y(B, V, J, F, N[j + 4], X, 4118548399), F = y(F, B, V, J, N[j + 5], U, 1200080426), J = y(J, F, B, V, N[j + 6], P, 2821735955), V = y(V, J, F, B, N[j + 7], se, 4249261313), B = y(B, V, J, F, N[j + 8], X, 1770035416), F = y(F, B, V, J, N[j + 9], U, 2336552879), J = y(J, F, B, V, N[j + 10], P, 4294925233), V = y(V, J, F, B, N[j + 11], se, 2304563134), B = y(B, V, J, F, N[j + 12], X, 1804603682), F = y(F, B, V, J, N[j + 13], U, 4254626195), J = y(J, F, B, V, N[j + 14], P, 2792965006), V = y(V, J, F, B, N[j + 15], se, 1236535329), B = C(B, V, J, F, N[j + 1], st, 4129170786), F = C(F, B, V, J, N[j + 6], ee, 3225465664), J = C(J, F, B, V, N[j + 11], W, 643717713), V = C(V, J, F, B, N[j + 0], G, 3921069994), B = C(B, V, J, F, N[j + 5], st, 3593408605), F = C(F, B, V, J, N[j + 10], ee, 38016083), J = C(J, F, B, V, N[j + 15], W, 3634488961), V = C(V, J, F, B, N[j + 4], G, 3889429448), B = C(B, V, J, F, N[j + 9], st, 568446438), F = C(F, B, V, J, N[j + 14], ee, 3275163606), J = C(J, F, B, V, N[j + 3], W, 4107603335), V = C(V, J, F, B, N[j + 8], G, 1163531501), B = C(B, V, J, F, N[j + 13], st, 2850285829), F = C(F, B, V, J, N[j + 2], ee, 4243563512), J = C(J, F, B, V, N[j + 7], W, 1735328473), V = C(V, J, F, B, N[j + 12], G, 2368359562), B = A(B, V, J, F, N[j + 5], re, 4294588738), F = A(F, B, V, J, N[j + 8], ge, 2272392833), J = A(J, F, B, V, N[j + 11], be, 1839030562), V = A(V, J, F, B, N[j + 14], xe, 4259657740), B = A(B, V, J, F, N[j + 1], re, 2763975236), F = A(F, B, V, J, N[j + 4], ge, 1272893353), J = A(J, F, B, V, N[j + 7], be, 4139469664), V = A(V, J, F, B, N[j + 10], xe, 3200236656), B = A(B, V, J, F, N[j + 13], re, 681279174), F = A(F, B, V, J, N[j + 0], ge, 3936430074), J = A(J, F, B, V, N[j + 3], be, 3572445317), V = A(V, J, F, B, N[j + 6], xe, 76029189), B = A(B, V, J, F, N[j + 9], re, 3654602809), F = A(F, B, V, J, N[j + 12], ge, 3873151461), J = A(J, F, B, V, N[j + 15], be, 530742520), V = A(V, J, F, B, N[j + 2], xe, 3299628645), B = I(B, V, J, F, N[j + 0], Ae, 4096336452), F = I(F, B, V, J, N[j + 7], le, 1126891415), J = I(J, F, B, V, N[j + 14], ye, 2878612391), V = I(V, J, F, B, N[j + 5], nt, 4237533241), B = I(B, V, J, F, N[j + 12], Ae, 1700485571), F = I(F, B, V, J, N[j + 3], le, 2399980690), J = I(J, F, B, V, N[j + 10], ye, 4293915773), V = I(V, J, F, B, N[j + 1], nt, 2240044497), B = I(B, V, J, F, N[j + 8], Ae, 1873313359), F = I(F, B, V, J, N[j + 15], le, 4264355552), J = I(J, F, B, V, N[j + 6], ye, 2734768916), V = I(V, J, F, B, N[j + 13], nt, 1309151649), B = I(B, V, J, F, N[j + 4], Ae, 4149444226), F = I(F, B, V, J, N[j + 11], le, 3174756917), J = I(J, F, B, V, N[j + 2], ye, 718787259), V = I(V, J, F, B, N[j + 9], nt, 3951481745), B = h(B, Se), V = h(V, ve), J = h(J, k), F = h(F, D);
|
12456
12458
|
return ($(B) + $(V) + $(J) + $(F)).toLowerCase();
|
12457
12459
|
}, et.closeMediaStream = (r) => {
|
12458
12460
|
if (r)
|
@@ -12475,7 +12477,7 @@ function At() {
|
|
12475
12477
|
}
|
12476
12478
|
}, et.cloneArray = (r) => r && r.slice() || [], et.cloneObject = (r, d = {}) => r && Object.assign({}, r) || d, et;
|
12477
12479
|
}
|
12478
|
-
const fh = xt, Fm = ut, St = De, it =
|
12480
|
+
const fh = xt, Fm = ut, St = De, it = Ct(), rf = $u(), jm = Zt(), Lo = new Fm("SIPMessage");
|
12479
12481
|
class Wa {
|
12480
12482
|
constructor(t, n, a, o, s, r) {
|
12481
12483
|
if (!t || !n || !a)
|
@@ -12488,8 +12490,8 @@ class Wa {
|
|
12488
12490
|
typeof o.from_display_name < "u" ? E = o.from_display_name : a.configuration.display_name ? E = a.configuration.display_name : E = null, this.from = new rf(g, E, T), this.setHeader("from", this.from.toString());
|
12489
12491
|
const y = o.call_id || a.configuration.jssip_id + it.createRandomToken(15);
|
12490
12492
|
this.call_id = y, this.setHeader("call-id", y);
|
12491
|
-
const
|
12492
|
-
this.cseq =
|
12493
|
+
const C = o.cseq || Math.floor(Math.random() * 1e4);
|
12494
|
+
this.cseq = C, this.setHeader("cseq", `${C} ${t}`);
|
12493
12495
|
}
|
12494
12496
|
/**
|
12495
12497
|
* Replace the the given header by the given value.
|
@@ -12833,7 +12835,7 @@ var yt = {
|
|
12833
12835
|
IncomingRequest: qm,
|
12834
12836
|
IncomingResponse: Vm
|
12835
12837
|
};
|
12836
|
-
const pr = /* @__PURE__ */ ze(yt), Bm = ut, ps =
|
12838
|
+
const pr = /* @__PURE__ */ ze(yt), Bm = ut, ps = Ct(), Jt = new Bm("DigestAuthentication");
|
12837
12839
|
var dh = class {
|
12838
12840
|
constructor(t) {
|
12839
12841
|
this._credentials = t, this._cnonce = null, this._nc = 0, this._ncHex = "00000000", this._algorithm = null, this._realm = null, this._nonce = null, this._opaque = null, this._stale = null, this._qop = null, this._method = null, this._uri = null, this._ha1 = null, this._response = null;
|
@@ -13324,7 +13326,7 @@ var vr = class {
|
|
13324
13326
|
this._eventHandlers.onReceiveResponse(t);
|
13325
13327
|
}
|
13326
13328
|
};
|
13327
|
-
const sl = /* @__PURE__ */ ze(vr), ng = ut, Fo =
|
13329
|
+
const sl = /* @__PURE__ */ ze(vr), ng = ut, Fo = Ct(), Tn = De, ff = yt, hf = vr, Hi = new ng("Registrator"), Ql = 10;
|
13328
13330
|
var rg = class {
|
13329
13331
|
constructor(t, n) {
|
13330
13332
|
this._reg_id = 1, this._ua = t, this._transport = n, this._registrar = t.configuration.registrar_server, this._expires = t.configuration.register_expires, this._call_id = Fo.createRandomToken(22), this._cseq = 0, this._to_uri = t.configuration.uri, this._registrationTimer = null, this._registering = !1, this._registered = !1, this._contact = this._ua.contact.toString(), this._contact += ";+sip.ice", this._extraHeaders = [], this._extraContactParams = "", this._sipInstance = `"<urn:uuid:${this._ua.configuration.instance_id}>"`, this._contact += `;reg-id=${this._reg_id}`, this._contact += `;+sip.instance=${this._sipInstance}`;
|
@@ -13495,13 +13497,13 @@ class og extends Error {
|
|
13495
13497
|
super(), this.code = 4, this.name = "NOT_READY_ERROR", this.message = t;
|
13496
13498
|
}
|
13497
13499
|
}
|
13498
|
-
var
|
13500
|
+
var Cs = {
|
13499
13501
|
ConfigurationError: ig,
|
13500
13502
|
InvalidStateError: lg,
|
13501
13503
|
NotSupportedError: ag,
|
13502
13504
|
NotReadyError: og
|
13503
13505
|
};
|
13504
|
-
const qs = /* @__PURE__ */ ze(
|
13506
|
+
const qs = /* @__PURE__ */ ze(Cs), jo = De, Zl = Tr, ug = vr, qo = {
|
13505
13507
|
onRequestTimeout: () => {
|
13506
13508
|
},
|
13507
13509
|
onTransportError: () => {
|
@@ -13553,7 +13555,7 @@ var _h = class {
|
|
13553
13555
|
}, 1e3)) : t.status_code >= 200 && t.status_code < 300 ? this._eventHandlers.onSuccessResponse(t) : t.status_code >= 300 && this._eventHandlers.onErrorResponse(t);
|
13554
13556
|
}
|
13555
13557
|
};
|
13556
|
-
const cg = /* @__PURE__ */ ze(_h), fg = ut, df = yt, $s = De, Fi = Tr, hg = _h, Vo =
|
13558
|
+
const cg = /* @__PURE__ */ ze(_h), fg = ut, df = yt, $s = De, Fi = Tr, hg = _h, Vo = Ct(), Bo = new fg("Dialog"), Hs = {
|
13557
13559
|
// Dialog states.
|
13558
13560
|
STATUS_EARLY: 1,
|
13559
13561
|
STATUS_CONFIRMED: 2,
|
@@ -13684,7 +13686,7 @@ var ph = class {
|
|
13684
13686
|
};
|
13685
13687
|
const ea = /* @__PURE__ */ ze(ph);
|
13686
13688
|
var ju = { exports: {} };
|
13687
|
-
const dg = ft.EventEmitter, _g = ut, pg = De, mg =
|
13689
|
+
const dg = ft.EventEmitter, _g = ut, pg = De, mg = Cs, _f = Ct(), gg = new _g("RTCSession:DTMF"), mh = {
|
13688
13690
|
MIN_DURATION: 70,
|
13689
13691
|
MAX_DURATION: 6e3,
|
13690
13692
|
DEFAULT_DURATION: 100,
|
@@ -13768,7 +13770,7 @@ ju.exports = class extends dg {
|
|
13768
13770
|
};
|
13769
13771
|
ju.exports.C = mh;
|
13770
13772
|
var gh = ju.exports;
|
13771
|
-
const Tg = /* @__PURE__ */ ze(gh), vg = ft.EventEmitter, Eg = De, Sg =
|
13773
|
+
const Tg = /* @__PURE__ */ ze(gh), vg = ft.EventEmitter, Eg = De, Sg = Cs, yg = Ct();
|
13772
13774
|
var Th = class extends vg {
|
13773
13775
|
constructor(t) {
|
13774
13776
|
super(), this._session = t, this._direction = null, this._contentType = null, this._body = null;
|
@@ -13826,7 +13828,7 @@ var Th = class extends vg {
|
|
13826
13828
|
});
|
13827
13829
|
}
|
13828
13830
|
};
|
13829
|
-
const yu = /* @__PURE__ */ ze(Th),
|
13831
|
+
const yu = /* @__PURE__ */ ze(Th), Cg = ut, pf = De, Ag = new Cg("RTCSession:ReferNotifier"), Go = {
|
13830
13832
|
event_type: "refer",
|
13831
13833
|
body_type: "message/sipfrag;version=2.0",
|
13832
13834
|
expires: 300
|
@@ -13836,7 +13838,7 @@ var vh = class {
|
|
13836
13838
|
this._session = t, this._id = n, this._expires = a || Go.expires, this._active = !0, this.notify(100);
|
13837
13839
|
}
|
13838
13840
|
notify(t, n) {
|
13839
|
-
if (
|
13841
|
+
if (Ag.debug("notify()"), this._active === !1)
|
13840
13842
|
return;
|
13841
13843
|
n = n || pf.REASON_PHRASE[t] || "";
|
13842
13844
|
let a;
|
@@ -13856,7 +13858,7 @@ var vh = class {
|
|
13856
13858
|
});
|
13857
13859
|
}
|
13858
13860
|
};
|
13859
|
-
const Rg = /* @__PURE__ */ ze(vh), Ig = ft.EventEmitter, bg = ut, ji = De, wg = Zt(), mf =
|
13861
|
+
const Rg = /* @__PURE__ */ ze(vh), Ig = ft.EventEmitter, bg = ut, ji = De, wg = Zt(), mf = Ct(), vn = new bg("RTCSession:ReferSubscriber");
|
13860
13862
|
var Eh = class extends Ig {
|
13861
13863
|
constructor(t) {
|
13862
13864
|
super(), this._id = null, this._session = t;
|
@@ -13947,7 +13949,7 @@ var Eh = class extends Ig {
|
|
13947
13949
|
});
|
13948
13950
|
}
|
13949
13951
|
};
|
13950
|
-
const Og = /* @__PURE__ */ ze(Eh), Dg = ft.EventEmitter, gf = xt, Ng = ut, fe = De, En =
|
13952
|
+
const Og = /* @__PURE__ */ ze(Eh), Dg = ft.EventEmitter, gf = xt, Ng = ut, fe = De, En = Cs, Tf = Tr, Be = Ct(), qi = Fu, Ug = yt, ta = ph, Pg = vr, Mt = gh, vf = Th, xg = vh, kg = Eh, Ef = ys(), Y = new Ng("RTCSession"), Z = {
|
13951
13953
|
// RTCSession states.
|
13952
13954
|
STATUS_NULL: 0,
|
13953
13955
|
STATUS_INVITE_SENT: 1,
|
@@ -13960,7 +13962,7 @@ const Og = /* @__PURE__ */ ze(Eh), Dg = ft.EventEmitter, gf = xt, Ng = ut, fe =
|
|
13960
13962
|
STATUS_TERMINATED: 8,
|
13961
13963
|
STATUS_CONFIRMED: 9
|
13962
13964
|
}, sa = ["audio", "video"];
|
13963
|
-
var Sh = class
|
13965
|
+
var Sh = class Cu extends Dg {
|
13964
13966
|
/**
|
13965
13967
|
* Expose C object.
|
13966
13968
|
*/
|
@@ -14086,8 +14088,8 @@ var Sh = class Au extends Dg {
|
|
14086
14088
|
if (t = this._ua.normalizeTarget(t), !t)
|
14087
14089
|
throw new TypeError(`Invalid target: ${o}`);
|
14088
14090
|
this._sessionTimers.enabled && Be.isDecimal(n.sessionTimersExpires) && (n.sessionTimersExpires >= fe.MIN_SESSION_EXPIRES ? this._sessionTimers.defaultExpires = n.sessionTimersExpires : this._sessionTimers.defaultExpires = fe.SESSION_EXPIRES);
|
14089
|
-
for (const
|
14090
|
-
Object.prototype.hasOwnProperty.call(s,
|
14091
|
+
for (const C in s)
|
14092
|
+
Object.prototype.hasOwnProperty.call(s, C) && this.on(C, s[C]);
|
14091
14093
|
this._from_tag = Be.newTag();
|
14092
14094
|
const E = n.anonymous || !1, y = { from_tag: this._from_tag };
|
14093
14095
|
this._contact = this._ua.contact.toString({
|
@@ -14130,7 +14132,7 @@ var Sh = class Au extends Dg {
|
|
14130
14132
|
answer(t = {}) {
|
14131
14133
|
Y.debug("answer()");
|
14132
14134
|
const n = this._request, a = Be.cloneArray(t.extraHeaders), o = Be.cloneObject(t.mediaConstraints), s = t.mediaStream || null, r = Be.cloneObject(t.pcConfig, { iceServers: [] }), d = t.rtcConstraints || null, h = t.rtcAnswerConstraints || null, _ = Be.cloneObject(t.rtcOfferConstraints);
|
14133
|
-
let g, T = !1, E = !1, y = !1,
|
14135
|
+
let g, T = !1, E = !1, y = !1, C = !1;
|
14134
14136
|
if (this._rtcAnswerConstraints = h, this._rtcOfferConstraints = t.rtcOfferConstraints || null, this._data = t.data || this._data, this._direction !== "incoming")
|
14135
14137
|
throw new En.NotSupportedError('"answer" not supported for outgoing RTCSession');
|
14136
14138
|
if (this._status !== Z.STATUS_WAITING_FOR_ANSWER)
|
@@ -14140,10 +14142,10 @@ var Sh = class Au extends Dg {
|
|
14140
14142
|
return;
|
14141
14143
|
}
|
14142
14144
|
clearTimeout(this._timers.userNoAnswerTimer), a.unshift(`Contact: ${this._contact}`);
|
14143
|
-
const
|
14144
|
-
Array.isArray(
|
14145
|
-
for (const I of
|
14146
|
-
I.type === "audio" && (T = !0, (!I.direction || I.direction === "sendrecv") && (y = !0)), I.type === "video" && (E = !0, (!I.direction || I.direction === "sendrecv") && (
|
14145
|
+
const A = n.parseSDP();
|
14146
|
+
Array.isArray(A.media) || (A.media = [A.media]);
|
14147
|
+
for (const I of A.media)
|
14148
|
+
I.type === "audio" && (T = !0, (!I.direction || I.direction === "sendrecv") && (y = !0)), I.type === "video" && (E = !0, (!I.direction || I.direction === "sendrecv") && (C = !0));
|
14147
14149
|
if (s && o.audio === !1) {
|
14148
14150
|
g = s.getAudioTracks();
|
14149
14151
|
for (const I of g)
|
@@ -14154,7 +14156,7 @@ var Sh = class Au extends Dg {
|
|
14154
14156
|
for (const I of g)
|
14155
14157
|
s.removeTrack(I);
|
14156
14158
|
}
|
14157
|
-
!s && o.audio === void 0 && (o.audio = y), !s && o.video === void 0 && (o.video =
|
14159
|
+
!s && o.audio === void 0 && (o.audio = y), !s && o.video === void 0 && (o.video = C), !s && !T && !_.offerToReceiveAudio && (o.audio = !1), !s && !E && !_.offerToReceiveVideo && (o.video = !1), this._createRTCConnection(r, d), Promise.resolve().then(() => {
|
14158
14160
|
if (s)
|
14159
14161
|
return s;
|
14160
14162
|
if (o.audio || o.video)
|
@@ -14790,7 +14792,7 @@ var Sh = class Au extends Dg {
|
|
14790
14792
|
function a(s, r = {}) {
|
14791
14793
|
if (s = typeof s == "function" ? s : null, this._status !== Z.STATUS_WAITING_FOR_ACK && this._status !== Z.STATUS_CONFIRMED)
|
14792
14794
|
return !1;
|
14793
|
-
const d = new
|
14795
|
+
const d = new Cu(this._ua);
|
14794
14796
|
if (d.on("progress", ({ response: h }) => {
|
14795
14797
|
n.notify(h.status_code, h.reason_phrase);
|
14796
14798
|
}), d.on("accepted", ({ response: h }) => {
|
@@ -14841,7 +14843,7 @@ var Sh = class Au extends Dg {
|
|
14841
14843
|
function n(o) {
|
14842
14844
|
if (this._status !== Z.STATUS_WAITING_FOR_ACK && this._status !== Z.STATUS_CONFIRMED)
|
14843
14845
|
return !1;
|
14844
|
-
const s = new
|
14846
|
+
const s = new Cu(this._ua);
|
14845
14847
|
s.on("confirmed", () => {
|
14846
14848
|
this.terminate();
|
14847
14849
|
}), s.init_incoming(t, o);
|
@@ -15274,7 +15276,7 @@ var Sh = class Au extends Dg {
|
|
15274
15276
|
});
|
15275
15277
|
}
|
15276
15278
|
};
|
15277
|
-
const Mg = /* @__PURE__ */ ze(Sh), Lg = ft.EventEmitter, $g = ut, Wo = De, Hg = yt, Vi =
|
15279
|
+
const Mg = /* @__PURE__ */ ze(Sh), Lg = ft.EventEmitter, $g = ut, Wo = De, Hg = yt, Vi = Ct(), Fg = vr, Sf = Cs, jg = ys(), na = new $g("Message");
|
15278
15280
|
var qg = class extends Lg {
|
15279
15281
|
constructor(t) {
|
15280
15282
|
super(), this._ua = t, this._request = null, this._closed = !1, this._direction = null, this._local_identity = null, this._remote_identity = null, this._is_replied = !1, this._data = {};
|
@@ -15395,7 +15397,7 @@ var qg = class extends Lg {
|
|
15395
15397
|
});
|
15396
15398
|
}
|
15397
15399
|
};
|
15398
|
-
const Vg = ft.EventEmitter, Bg = ut, Ko = De, Gg = yt, Bi =
|
15400
|
+
const Vg = ft.EventEmitter, Bg = ut, Ko = De, Gg = yt, Bi = Ct(), Wg = vr, yf = Cs, ra = new Bg("Options");
|
15399
15401
|
var Kg = class extends Vg {
|
15400
15402
|
constructor(t) {
|
15401
15403
|
super(), this._ua = t, this._request = null, this._closed = !1, this._direction = null, this._local_identity = null, this._remote_identity = null, this._is_replied = !1, this._data = {};
|
@@ -15515,7 +15517,7 @@ var Kg = class extends Vg {
|
|
15515
15517
|
});
|
15516
15518
|
}
|
15517
15519
|
}, qu = {};
|
15518
|
-
const Yg = ut, Yo =
|
15520
|
+
const Yg = ut, Yo = Ct(), Jg = Zt(), Gi = new Yg("Socket");
|
15519
15521
|
qu.isSocket = (c) => {
|
15520
15522
|
if (Array.isArray(c))
|
15521
15523
|
return !1;
|
@@ -15541,7 +15543,7 @@ qu.isSocket = (c) => {
|
|
15541
15543
|
}
|
15542
15544
|
return !0;
|
15543
15545
|
};
|
15544
|
-
const zg = ut, Xg = qu,
|
15546
|
+
const zg = ut, Xg = qu, Cf = De, Ut = new zg("Transport"), Vt = {
|
15545
15547
|
// Transport status.
|
15546
15548
|
STATUS_CONNECTED: 0,
|
15547
15549
|
STATUS_CONNECTING: 1,
|
@@ -15552,9 +15554,9 @@ const zg = ut, Xg = qu, Af = De, Ut = new zg("Transport"), Vt = {
|
|
15552
15554
|
// Recovery options.
|
15553
15555
|
recovery_options: {
|
15554
15556
|
// minimum interval in seconds between recover attempts.
|
15555
|
-
min_interval:
|
15557
|
+
min_interval: Cf.CONNECTION_RECOVERY_MIN_INTERVAL,
|
15556
15558
|
// maximum interval in seconds between recover attempts.
|
15557
|
-
max_interval:
|
15559
|
+
max_interval: Cf.CONNECTION_RECOVERY_MAX_INTERVAL
|
15558
15560
|
}
|
15559
15561
|
};
|
15560
15562
|
var yh = class {
|
@@ -15692,9 +15694,9 @@ ${t}
|
|
15692
15694
|
}
|
15693
15695
|
};
|
15694
15696
|
const Qg = /* @__PURE__ */ ze(yh);
|
15695
|
-
var
|
15696
|
-
const Zg = ut,
|
15697
|
-
|
15697
|
+
var Ch = {};
|
15698
|
+
const Zg = ut, Au = Zt(), Ru = yt, ia = new Zg("Parser");
|
15699
|
+
Ch.parseMessage = (c, t) => {
|
15698
15700
|
let n, a, o = c.indexOf(`\r
|
15699
15701
|
`);
|
15700
15702
|
if (o === -1) {
|
@@ -15702,7 +15704,7 @@ Ah.parseMessage = (c, t) => {
|
|
15702
15704
|
return;
|
15703
15705
|
}
|
15704
15706
|
const s = c.substring(0, o);
|
15705
|
-
let r =
|
15707
|
+
let r = Au.parse(s, "Request_Response");
|
15706
15708
|
if (r === -1) {
|
15707
15709
|
ia.warn(`parseMessage() | error parsing first line of SIP message: "${s}"`);
|
15708
15710
|
return;
|
@@ -15760,7 +15762,7 @@ function tT(c, t, n, a) {
|
|
15760
15762
|
c.setHeader("to", d), o = c.parseHeader("to"), o && (c.to = o, c.to_tag = o.getParam("tag"));
|
15761
15763
|
break;
|
15762
15764
|
case "record-route":
|
15763
|
-
if (o =
|
15765
|
+
if (o = Au.parse(d, "Record_Route"), o === -1)
|
15764
15766
|
o = void 0;
|
15765
15767
|
else
|
15766
15768
|
for (const h of o)
|
@@ -15772,7 +15774,7 @@ function tT(c, t, n, a) {
|
|
15772
15774
|
break;
|
15773
15775
|
case "contact":
|
15774
15776
|
case "m":
|
15775
|
-
if (o =
|
15777
|
+
if (o = Au.parse(d, "Contact"), o === -1)
|
15776
15778
|
o = void 0;
|
15777
15779
|
else
|
15778
15780
|
for (const h of o)
|
@@ -15820,7 +15822,7 @@ function tT(c, t, n, a) {
|
|
15820
15822
|
error: `error parsing header "${r}"`
|
15821
15823
|
} : !0;
|
15822
15824
|
}
|
15823
|
-
const sT = ut,
|
15825
|
+
const sT = ut, Ah = De, Af = yt, Vu = Ct(), Bu = new sT("sanityCheck"), nT = [hT], rT = [
|
15824
15826
|
lT,
|
15825
15827
|
aT,
|
15826
15828
|
oT,
|
@@ -15829,17 +15831,17 @@ const sT = ut, Ch = De, Cf = yt, Vu = At(), Bu = new sT("sanityCheck"), nT = [hT
|
|
15829
15831
|
cT,
|
15830
15832
|
fT
|
15831
15833
|
];
|
15832
|
-
let
|
15834
|
+
let je, is, Rh;
|
15833
15835
|
var Ih = (c, t, n) => {
|
15834
|
-
|
15836
|
+
je = c, is = t, Rh = n;
|
15835
15837
|
for (const a of nT)
|
15836
15838
|
if (a() === !1)
|
15837
15839
|
return !1;
|
15838
|
-
if (
|
15840
|
+
if (je instanceof Af.IncomingRequest) {
|
15839
15841
|
for (const a of rT)
|
15840
15842
|
if (a() === !1)
|
15841
15843
|
return !1;
|
15842
|
-
} else if (
|
15844
|
+
} else if (je instanceof Af.IncomingResponse) {
|
15843
15845
|
for (const a of iT)
|
15844
15846
|
if (a() === !1)
|
15845
15847
|
return !1;
|
@@ -15847,30 +15849,30 @@ var Ih = (c, t, n) => {
|
|
15847
15849
|
return !0;
|
15848
15850
|
};
|
15849
15851
|
function lT() {
|
15850
|
-
if (
|
15852
|
+
if (je.s("to").uri.scheme !== "sip")
|
15851
15853
|
return nl(416), !1;
|
15852
15854
|
}
|
15853
15855
|
function aT() {
|
15854
|
-
if (!
|
15856
|
+
if (!je.to_tag && je.call_id.substr(0, 5) === is.configuration.jssip_id)
|
15855
15857
|
return nl(482), !1;
|
15856
15858
|
}
|
15857
15859
|
function oT() {
|
15858
|
-
const c = Vu.str_utf8_length(
|
15860
|
+
const c = Vu.str_utf8_length(je.body), t = je.getHeader("content-length");
|
15859
15861
|
if (c < t)
|
15860
15862
|
return nl(400), !1;
|
15861
15863
|
}
|
15862
15864
|
function uT() {
|
15863
|
-
const c =
|
15865
|
+
const c = je.from_tag, t = je.call_id, n = je.cseq;
|
15864
15866
|
let a;
|
15865
|
-
if (!
|
15866
|
-
if (
|
15867
|
-
if (is._transactions.ist[
|
15867
|
+
if (!je.to_tag)
|
15868
|
+
if (je.method === Ah.INVITE) {
|
15869
|
+
if (is._transactions.ist[je.via_branch])
|
15868
15870
|
return !1;
|
15869
15871
|
for (const o in is._transactions.ist)
|
15870
15872
|
if (Object.prototype.hasOwnProperty.call(is._transactions.ist, o) && (a = is._transactions.ist[o], a.request.from_tag === c && a.request.call_id === t && a.request.cseq === n))
|
15871
15873
|
return nl(482), !1;
|
15872
15874
|
} else {
|
15873
|
-
if (is._transactions.nist[
|
15875
|
+
if (is._transactions.nist[je.via_branch])
|
15874
15876
|
return !1;
|
15875
15877
|
for (const o in is._transactions.nist)
|
15876
15878
|
if (Object.prototype.hasOwnProperty.call(is._transactions.nist, o) && (a = is._transactions.nist[o], a.request.from_tag === c && a.request.call_id === t && a.request.cseq === n))
|
@@ -15878,37 +15880,37 @@ function uT() {
|
|
15878
15880
|
}
|
15879
15881
|
}
|
15880
15882
|
function cT() {
|
15881
|
-
if (
|
15883
|
+
if (je.getHeaders("via").length > 1)
|
15882
15884
|
return Bu.debug("more than one Via header field present in the response, dropping the response"), !1;
|
15883
15885
|
}
|
15884
15886
|
function fT() {
|
15885
|
-
const c = Vu.str_utf8_length(
|
15887
|
+
const c = Vu.str_utf8_length(je.body), t = je.getHeader("content-length");
|
15886
15888
|
if (c < t)
|
15887
15889
|
return Bu.debug("message body length is lower than the value in Content-Length header field, dropping the response"), !1;
|
15888
15890
|
}
|
15889
15891
|
function hT() {
|
15890
15892
|
const c = ["from", "to", "call_id", "cseq", "via"];
|
15891
15893
|
for (const t of c)
|
15892
|
-
if (!
|
15894
|
+
if (!je.hasHeader(t))
|
15893
15895
|
return Bu.debug(`missing mandatory header field : ${t}, dropping the response`), !1;
|
15894
15896
|
}
|
15895
15897
|
function nl(c) {
|
15896
|
-
const t =
|
15897
|
-
let n, a = `SIP/2.0 ${c} ${
|
15898
|
+
const t = je.getHeaders("via");
|
15899
|
+
let n, a = `SIP/2.0 ${c} ${Ah.REASON_PHRASE[c]}\r
|
15898
15900
|
`;
|
15899
15901
|
for (const o of t)
|
15900
15902
|
a += `Via: ${o}\r
|
15901
15903
|
`;
|
15902
|
-
n =
|
15903
|
-
`, a += `From: ${
|
15904
|
-
`, a += `Call-ID: ${
|
15905
|
-
`, a += `CSeq: ${
|
15904
|
+
n = je.getHeader("To"), je.to_tag || (n += `;tag=${Vu.newTag()}`), a += `To: ${n}\r
|
15905
|
+
`, a += `From: ${je.getHeader("From")}\r
|
15906
|
+
`, a += `Call-ID: ${je.call_id}\r
|
15907
|
+
`, a += `CSeq: ${je.cseq} ${je.method}\r
|
15906
15908
|
`, a += `\r
|
15907
15909
|
`, Rh.send(a);
|
15908
15910
|
}
|
15909
15911
|
const dT = /* @__PURE__ */ ze(Ih);
|
15910
15912
|
var rl = {};
|
15911
|
-
const hr =
|
15913
|
+
const hr = Ct(), Cn = De, Jo = Zt(), Rf = ys(), zo = qu, Xo = Cs;
|
15912
15914
|
rl.settings = {
|
15913
15915
|
// SIP authentication.
|
15914
15916
|
authorization_user: null,
|
@@ -15926,7 +15928,7 @@ rl.settings = {
|
|
15926
15928
|
use_preloaded_route: !1,
|
15927
15929
|
// Session parameters.
|
15928
15930
|
session_timers: !0,
|
15929
|
-
session_timers_refresh_method:
|
15931
|
+
session_timers_refresh_method: Cn.UPDATE,
|
15930
15932
|
session_timers_force_refresher: !1,
|
15931
15933
|
no_answer_timeout: 60,
|
15932
15934
|
// Registration parameters.
|
@@ -15935,8 +15937,8 @@ rl.settings = {
|
|
15935
15937
|
registrar_server: null,
|
15936
15938
|
// Connection options.
|
15937
15939
|
sockets: null,
|
15938
|
-
connection_recovery_max_interval:
|
15939
|
-
connection_recovery_min_interval:
|
15940
|
+
connection_recovery_max_interval: Cn.CONNECTION_RECOVERY_MAX_INTERVAL,
|
15941
|
+
connection_recovery_min_interval: Cn.CONNECTION_RECOVERY_MIN_INTERVAL,
|
15940
15942
|
// Global extra headers, to be added to every request and response
|
15941
15943
|
extra_headers: null,
|
15942
15944
|
/*
|
@@ -15959,7 +15961,7 @@ const la = {
|
|
15959
15961
|
return t;
|
15960
15962
|
},
|
15961
15963
|
uri(c) {
|
15962
|
-
/^sip:/i.test(c) || (c = `${
|
15964
|
+
/^sip:/i.test(c) || (c = `${Cn.SIP}:${c}`);
|
15963
15965
|
const t = Rf.parse(c);
|
15964
15966
|
if (t)
|
15965
15967
|
return t.user ? t : void 0;
|
@@ -16018,7 +16020,7 @@ const la = {
|
|
16018
16020
|
return c;
|
16019
16021
|
},
|
16020
16022
|
session_timers_refresh_method(c) {
|
16021
|
-
if (typeof c == "string" && (c = c.toUpperCase(), c ===
|
16023
|
+
if (typeof c == "string" && (c = c.toUpperCase(), c === Cn.INVITE || c === Cn.UPDATE))
|
16022
16024
|
return c;
|
16023
16025
|
},
|
16024
16026
|
session_timers_force_refresher(c) {
|
@@ -16046,7 +16048,7 @@ const la = {
|
|
16046
16048
|
}
|
16047
16049
|
},
|
16048
16050
|
registrar_server(c) {
|
16049
|
-
/^sip:/i.test(c) || (c = `${
|
16051
|
+
/^sip:/i.test(c) || (c = `${Cn.SIP}:${c}`);
|
16050
16052
|
const t = Rf.parse(c);
|
16051
16053
|
if (t)
|
16052
16054
|
return t.user ? void 0 : t;
|
@@ -16088,7 +16090,7 @@ rl.load = (c, t) => {
|
|
16088
16090
|
throw new Xo.ConfigurationError(n, a);
|
16089
16091
|
}
|
16090
16092
|
};
|
16091
|
-
const _T = ft.EventEmitter, pT = ut, mt = De, mT = rg, If = Sh, bf = qg, wf = Kg, Qo = Tr, gT = yh, aa =
|
16093
|
+
const _T = ft.EventEmitter, pT = ut, mt = De, mT = rg, If = Sh, bf = qg, wf = Kg, Qo = Tr, gT = yh, aa = Ct(), TT = Cs, vT = ys(), ET = Ch, Zo = yt, ST = Ih, eu = rl, He = new pT("UA"), vt = {
|
16092
16094
|
// UA status codes.
|
16093
16095
|
STATUS_INIT: 0,
|
16094
16096
|
STATUS_READY: 1,
|
@@ -16104,7 +16106,7 @@ var bh = class extends _T {
|
|
16104
16106
|
return vt;
|
16105
16107
|
}
|
16106
16108
|
constructor(t) {
|
16107
|
-
if (
|
16109
|
+
if (He.debug("new() [configuration:%o]", t), super(), this._cache = {
|
16108
16110
|
credentials: {}
|
16109
16111
|
}, this._configuration = Object.assign({}, eu.settings), this._dynConfiguration = {}, this._dialogs = {}, this._applicants = {}, this._sessions = {}, this._transport = null, this._contact = null, this._status = vt.STATUS_INIT, this._error = null, this._transactions = {
|
16110
16112
|
nist: {},
|
@@ -16143,19 +16145,19 @@ var bh = class extends _T {
|
|
16143
16145
|
* Resume UA after being closed.
|
16144
16146
|
*/
|
16145
16147
|
start() {
|
16146
|
-
|
16148
|
+
He.debug("start()"), this._status === vt.STATUS_INIT ? this._transport.connect() : this._status === vt.STATUS_USER_CLOSED ? (He.debug("restarting UA"), this._closeTimer !== null && (clearTimeout(this._closeTimer), this._closeTimer = null, this._transport.disconnect()), this._status = vt.STATUS_INIT, this._transport.connect()) : this._status === vt.STATUS_READY ? He.debug("UA is in READY status, not restarted") : He.debug("ERROR: connection is down, Auto-Recovery system is trying to reconnect"), this._dynConfiguration.register = this._configuration.register;
|
16147
16149
|
}
|
16148
16150
|
/**
|
16149
16151
|
* Register.
|
16150
16152
|
*/
|
16151
16153
|
register() {
|
16152
|
-
|
16154
|
+
He.debug("register()"), this._dynConfiguration.register = !0, this._registrator.register();
|
16153
16155
|
}
|
16154
16156
|
/**
|
16155
16157
|
* Unregister.
|
16156
16158
|
*/
|
16157
16159
|
unregister(t) {
|
16158
|
-
|
16160
|
+
He.debug("unregister()"), this._dynConfiguration.register = !1, this._registrator.unregister(t);
|
16159
16161
|
}
|
16160
16162
|
/**
|
16161
16163
|
* Get the Registrator instance.
|
@@ -16185,7 +16187,7 @@ var bh = class extends _T {
|
|
16185
16187
|
*
|
16186
16188
|
*/
|
16187
16189
|
call(t, n) {
|
16188
|
-
|
16190
|
+
He.debug("call()");
|
16189
16191
|
const a = new If(this);
|
16190
16192
|
return a.connect(t, n), a;
|
16191
16193
|
}
|
@@ -16200,7 +16202,7 @@ var bh = class extends _T {
|
|
16200
16202
|
*
|
16201
16203
|
*/
|
16202
16204
|
sendMessage(t, n, a) {
|
16203
|
-
|
16205
|
+
He.debug("sendMessage()");
|
16204
16206
|
const o = new bf(this);
|
16205
16207
|
return o.send(t, n, a), o;
|
16206
16208
|
}
|
@@ -16215,7 +16217,7 @@ var bh = class extends _T {
|
|
16215
16217
|
*
|
16216
16218
|
*/
|
16217
16219
|
sendOptions(t, n, a) {
|
16218
|
-
|
16220
|
+
He.debug("sendOptions()");
|
16219
16221
|
const o = new wf(this);
|
16220
16222
|
return o.send(t, n, a), o;
|
16221
16223
|
}
|
@@ -16223,7 +16225,7 @@ var bh = class extends _T {
|
|
16223
16225
|
* Terminate ongoing sessions.
|
16224
16226
|
*/
|
16225
16227
|
terminateSessions(t) {
|
16226
|
-
|
16228
|
+
He.debug("terminateSessions()");
|
16227
16229
|
for (const n in this._sessions)
|
16228
16230
|
this._sessions[n].isEnded() || this._sessions[n].terminate(t);
|
16229
16231
|
}
|
@@ -16232,15 +16234,15 @@ var bh = class extends _T {
|
|
16232
16234
|
*
|
16233
16235
|
*/
|
16234
16236
|
stop() {
|
16235
|
-
if (
|
16236
|
-
|
16237
|
+
if (He.debug("stop()"), this._dynConfiguration = {}, this._status === vt.STATUS_USER_CLOSED) {
|
16238
|
+
He.debug("UA already closed");
|
16237
16239
|
return;
|
16238
16240
|
}
|
16239
16241
|
this._registrator.close();
|
16240
16242
|
const t = Object.keys(this._sessions).length;
|
16241
16243
|
for (const a in this._sessions)
|
16242
16244
|
if (Object.prototype.hasOwnProperty.call(this._sessions, a)) {
|
16243
|
-
|
16245
|
+
He.debug(`closing session ${a}`);
|
16244
16246
|
try {
|
16245
16247
|
this._sessions[a].terminate();
|
16246
16248
|
} catch {
|
@@ -16278,7 +16280,7 @@ var bh = class extends _T {
|
|
16278
16280
|
case "authorization_jwt":
|
16279
16281
|
return this._configuration.authorization_jwt;
|
16280
16282
|
default:
|
16281
|
-
|
16283
|
+
He.warn('get() | cannot get "%s" parameter in runtime', t);
|
16282
16284
|
return;
|
16283
16285
|
}
|
16284
16286
|
}
|
@@ -16313,7 +16315,7 @@ var bh = class extends _T {
|
|
16313
16315
|
break;
|
16314
16316
|
}
|
16315
16317
|
default:
|
16316
|
-
return
|
16318
|
+
return He.warn('set() | cannot set "%s" parameter in runtime', t), !1;
|
16317
16319
|
}
|
16318
16320
|
return !0;
|
16319
16321
|
}
|
@@ -16403,9 +16405,10 @@ var bh = class extends _T {
|
|
16403
16405
|
* Request reception
|
16404
16406
|
*/
|
16405
16407
|
receiveRequest(t) {
|
16408
|
+
console.log("receiveRequest");
|
16406
16409
|
const n = t.method;
|
16407
16410
|
if (t.ruri.user !== this._configuration.uri.user && t.ruri.user !== this._contact.uri.user) {
|
16408
|
-
|
16411
|
+
He.debug("Request-URI does not point to us"), t.method !== mt.ACK && t.reply_sl(404);
|
16409
16412
|
return;
|
16410
16413
|
}
|
16411
16414
|
if (t.ruri.scheme === mt.SIPS) {
|
@@ -16415,7 +16418,7 @@ var bh = class extends _T {
|
|
16415
16418
|
if (Qo.checkTransaction(this, t))
|
16416
16419
|
return;
|
16417
16420
|
if (n === mt.INVITE ? new Qo.InviteServerTransaction(this, this._transport, t) : n !== mt.ACK && n !== mt.CANCEL && new Qo.NonInviteServerTransaction(this, this._transport, t), n === mt.OPTIONS) {
|
16418
|
-
if (this.listeners("newOptions").length === 0) {
|
16421
|
+
if (console.log("OPPP in option"), this.listeners("newOptions").length === 0) {
|
16419
16422
|
t.reply(200);
|
16420
16423
|
return;
|
16421
16424
|
}
|
@@ -16432,7 +16435,7 @@ var bh = class extends _T {
|
|
16432
16435
|
}
|
16433
16436
|
let a, o;
|
16434
16437
|
if (t.to_tag)
|
16435
|
-
a = this._findDialog(t.call_id, t.from_tag, t.to_tag), a ? a.receiveRequest(t) : n === mt.NOTIFY ? (o = this._findSession(t), o ? o.receiveRequest(t) : (
|
16438
|
+
a = this._findDialog(t.call_id, t.from_tag, t.to_tag), a ? a.receiveRequest(t) : n === mt.NOTIFY ? (o = this._findSession(t), o ? o.receiveRequest(t) : (He.debug("received NOTIFY request for a non existent subscription"), t.reply(481, "Subscription does not exist"))) : n !== mt.ACK && t.reply(481);
|
16436
16439
|
else
|
16437
16440
|
switch (n) {
|
16438
16441
|
case mt.INVITE:
|
@@ -16447,13 +16450,13 @@ var bh = class extends _T {
|
|
16447
16450
|
} else
|
16448
16451
|
o = new If(this), o.init_incoming(t);
|
16449
16452
|
else
|
16450
|
-
|
16453
|
+
He.warn("INVITE received but WebRTC is not supported"), t.reply(488);
|
16451
16454
|
break;
|
16452
16455
|
case mt.BYE:
|
16453
16456
|
t.reply(481);
|
16454
16457
|
break;
|
16455
16458
|
case mt.CANCEL:
|
16456
|
-
o = this._findSession(t), o ? o.receiveRequest(t) :
|
16459
|
+
o = this._findSession(t), o ? o.receiveRequest(t) : He.debug("received CANCEL request for a non existent session");
|
16457
16460
|
break;
|
16458
16461
|
case mt.ACK:
|
16459
16462
|
break;
|
@@ -16486,35 +16489,36 @@ var bh = class extends _T {
|
|
16486
16489
|
return s || (o = t + a + n, s = this._dialogs[o], s || null);
|
16487
16490
|
}
|
16488
16491
|
_loadConfig(t) {
|
16492
|
+
console.log("in _loadConfig");
|
16489
16493
|
try {
|
16490
|
-
eu.load(this._configuration, t);
|
16494
|
+
console.log("config.load"), eu.load(this._configuration, t);
|
16491
16495
|
} catch (o) {
|
16492
|
-
throw o;
|
16496
|
+
throw console.log("throw in _loadConfig", o), o;
|
16493
16497
|
}
|
16494
16498
|
this._configuration.display_name === 0 && (this._configuration.display_name = "0"), this._configuration.instance_id || (this._configuration.instance_id = aa.newUUID()), this._configuration.jssip_id = aa.createRandomToken(5);
|
16495
16499
|
const n = this._configuration.uri.clone();
|
16496
16500
|
n.user = null, this._configuration.hostport_params = n.toString().replace(/^sip:/i, "");
|
16497
16501
|
try {
|
16498
|
-
this._transport = new gT(this._configuration.sockets, {
|
16502
|
+
console.log("new transport"), this._transport = new gT(this._configuration.sockets, {
|
16499
16503
|
// Recovery options.
|
16500
16504
|
max_interval: this._configuration.connection_recovery_max_interval,
|
16501
16505
|
min_interval: this._configuration.connection_recovery_min_interval
|
16502
|
-
}), this._transport.onconnecting = yT.bind(this), this._transport.onconnect =
|
16506
|
+
}), this._transport.onconnecting = yT.bind(this), this._transport.onconnect = CT.bind(this), this._transport.ondisconnect = AT.bind(this), this._transport.ondata = RT.bind(this);
|
16503
16507
|
} catch (o) {
|
16504
|
-
throw
|
16508
|
+
throw He.warn(o), new TT.ConfigurationError("sockets", this._configuration.sockets);
|
16505
16509
|
}
|
16506
16510
|
if (delete this._configuration.sockets, this._configuration.authorization_user || (this._configuration.authorization_user = this._configuration.uri.user), !this._configuration.registrar_server) {
|
16507
16511
|
const o = this._configuration.uri.clone();
|
16508
16512
|
o.user = null, o.clearParams(), o.clearHeaders(), this._configuration.registrar_server = o;
|
16509
16513
|
}
|
16510
|
-
this._configuration.no_answer_timeout *= 1e3, this._configuration.contact_uri ? this._configuration.via_host = this._configuration.contact_uri.host : this._configuration.contact_uri = new vT("sip", aa.createRandomToken(8), this._configuration.via_host, null, { transport: "ws" }), this._contact = {
|
16514
|
+
this._configuration.no_answer_timeout *= 1e3, this._configuration.contact_uri ? this._configuration.via_host = this._configuration.contact_uri.host : (console.log("this._configuration.contact_uri 1"), this._configuration.contact_uri = new vT("sip", aa.createRandomToken(8), this._configuration.via_host, null, { transport: "ws" }), console.log("this._configuration.contact_uri 2", this._configuration.contact_uri)), this._contact = {
|
16511
16515
|
pub_gruu: null,
|
16512
16516
|
temp_gruu: null,
|
16513
16517
|
uri: this._configuration.contact_uri,
|
16514
16518
|
toString(o = {}) {
|
16515
16519
|
const s = o.anonymous || null, r = o.outbound || null;
|
16516
16520
|
let d = "<";
|
16517
|
-
return s ? d += this.temp_gruu || "sip:anonymous@anonymous.invalid;transport=ws" : d += this.pub_gruu || this.uri.toString(), r && (s ? !this.temp_gruu : !this.pub_gruu) && (d += ";ob"), d += ">", d;
|
16521
|
+
return s ? d += this.temp_gruu || "sip:anonymous@anonymous.invalid;transport=ws" : d += this.pub_gruu || this.uri.toString(), r && (s ? !this.temp_gruu : !this.pub_gruu) && (d += ";ob"), d += ">", console.log("contact", d), d;
|
16518
16522
|
}
|
16519
16523
|
};
|
16520
16524
|
const a = [
|
@@ -16534,31 +16538,32 @@ var bh = class extends _T {
|
|
16534
16538
|
writable: !1,
|
16535
16539
|
configurable: !1
|
16536
16540
|
}));
|
16537
|
-
|
16541
|
+
He.debug("configuration parameters after validation:"), He.debug("this._contact.toString:", this._contact.toString());
|
16538
16542
|
for (const o in this._configuration)
|
16539
16543
|
if (Object.prototype.hasOwnProperty.call(eu.settings, o))
|
16540
16544
|
switch (o) {
|
16541
16545
|
case "uri":
|
16542
16546
|
case "registrar_server":
|
16543
|
-
|
16547
|
+
He.debug(`- ${o}: ${this._configuration[o]}`);
|
16544
16548
|
break;
|
16545
16549
|
case "password":
|
16546
16550
|
case "ha1":
|
16547
16551
|
case "authorization_jwt":
|
16548
|
-
|
16552
|
+
He.debug(`- ${o}: NOT SHOWN`);
|
16549
16553
|
break;
|
16550
16554
|
default:
|
16551
|
-
|
16555
|
+
He.debug(`- ${o}: ${JSON.stringify(this._configuration[o])}`);
|
16552
16556
|
}
|
16557
|
+
console.log("_loadConfig retun");
|
16553
16558
|
}
|
16554
16559
|
};
|
16555
16560
|
function yT(c) {
|
16556
16561
|
this.emit("connecting", c);
|
16557
16562
|
}
|
16558
|
-
function
|
16563
|
+
function CT(c) {
|
16559
16564
|
this._status !== vt.STATUS_USER_CLOSED && (this._status = vt.STATUS_READY, this._error = null, this.emit("connected", c), this._dynConfiguration.register && this._registrator.register());
|
16560
16565
|
}
|
16561
|
-
function
|
16566
|
+
function AT(c) {
|
16562
16567
|
const t = ["nict", "ict", "nist", "ist"];
|
16563
16568
|
for (const n of t)
|
16564
16569
|
for (const a in this._transactions[n])
|
@@ -16566,6 +16571,7 @@ function CT(c) {
|
|
16566
16571
|
this.emit("disconnected", c), this._registrator.onTransportClosed(), this._status !== vt.STATUS_USER_CLOSED && (this._status = vt.STATUS_NOT_READY, this._error = vt.NETWORK_ERROR);
|
16567
16572
|
}
|
16568
16573
|
function RT(c) {
|
16574
|
+
console.log("onTransportData", c);
|
16569
16575
|
const t = c.transport;
|
16570
16576
|
let n = c.message;
|
16571
16577
|
if (n = ET.parseMessage(n, this), !!n && !(this._status === vt.STATUS_USER_CLOSED && n instanceof Zo.IncomingRequest) && ST(n, this, t)) {
|
@@ -16616,7 +16622,7 @@ function Df(c, t, n) {
|
|
16616
16622
|
}
|
16617
16623
|
return bT(a);
|
16618
16624
|
}
|
16619
|
-
var ke =
|
16625
|
+
var ke = Ct();
|
16620
16626
|
const Ts = /* @__PURE__ */ ze(ke), su = new Ga("Dialog"), Fs = {
|
16621
16627
|
// Dialog states.
|
16622
16628
|
STATUS_EARLY: 1,
|
@@ -17066,17 +17072,17 @@ class $a extends ft.EventEmitter {
|
|
17066
17072
|
if (t = this._ua.normalizeTarget(t), this.room_id = t.user, this.target = t, !t)
|
17067
17073
|
throw new TypeError(`Invalid target: ${s}`);
|
17068
17074
|
this._sessionTimers.enabled && ke.isDecimal(a.sessionTimersExpires) && (a.sessionTimersExpires >= L.MIN_SESSION_EXPIRES ? this._sessionTimers.defaultExpires = a.sessionTimersExpires : this._sessionTimers.defaultExpires = L.SESSION_EXPIRES);
|
17069
|
-
for (const
|
17070
|
-
Object.prototype.hasOwnProperty.call(r,
|
17075
|
+
for (const A in r)
|
17076
|
+
Object.prototype.hasOwnProperty.call(r, A) && this.on(A, r[A]);
|
17071
17077
|
this._from_tag = ke.newTag();
|
17072
|
-
const y = a.anonymous || !1,
|
17078
|
+
const y = a.anonymous || !1, C = { from_tag: this._from_tag };
|
17073
17079
|
this._contact = this._ua.contact.toString({
|
17074
17080
|
anonymous: y,
|
17075
17081
|
outbound: !0
|
17076
|
-
}), y ? (
|
17082
|
+
}), y ? (C.from_display_name = "Anonymous", C.from_uri = new In("sip", "anonymous", "anonymous.invalid"), d.push(`P-Preferred-Identity: ${this._ua.configuration.uri.toString()}`), d.push("Privacy: id")) : a.fromUserName && (C.from_uri = new In("sip", a.fromUserName, this._ua.configuration.uri.host), d.push(`P-Preferred-Identity: ${this._ua.configuration.uri.toString()}`)), a.fromDisplayName && (C.from_display_name = a.fromDisplayName), d.push(`Contact: ${this._contact}`), d.push("Content-Type: application/json"), this._sessionTimers.enabled && d.push(`Session-Expires: ${this._sessionTimers.defaultExpires}${this._ua.configuration.session_timers_force_refresher ? ";refresher=uac" : ""}`), this._request = new yt.InitialOutgoingInviteRequest(
|
17077
17083
|
t,
|
17078
17084
|
this._ua,
|
17079
|
-
|
17085
|
+
C,
|
17080
17086
|
d
|
17081
17087
|
), this._id = this._request.call_id + this._from_tag, this._createRTCConnection(g, T), this._direction = "outgoing", this._local_identity = this._request.from, this._remote_identity = this._request.to, o && o(this), this._newJanusSession("local", this._request), this._sendInitialRequest(h, E, _);
|
17082
17088
|
}
|
@@ -17162,7 +17168,7 @@ class $a extends ft.EventEmitter {
|
|
17162
17168
|
answer(t = {}) {
|
17163
17169
|
z.debug("answer()");
|
17164
17170
|
const n = this._request, a = ke.cloneArray(t.extraHeaders), o = ke.cloneObject(t.mediaConstraints), s = t.mediaStream || null, r = ke.cloneObject(t.pcConfig, { iceServers: [] }), d = t.rtcConstraints || null, h = t.rtcAnswerConstraints || null, _ = ke.cloneObject(t.rtcOfferConstraints);
|
17165
|
-
let g, T = !1, E = !1, y = !1,
|
17171
|
+
let g, T = !1, E = !1, y = !1, C = !1;
|
17166
17172
|
if (this._rtcAnswerConstraints = h, this._rtcOfferConstraints = t.rtcOfferConstraints || null, this._data = t.data || this._data, this._direction !== "incoming")
|
17167
17173
|
throw new qs.NotSupportedError('"answer" not supported for outgoing RTCSession');
|
17168
17174
|
if (this._status !== te.STATUS_WAITING_FOR_ANSWER)
|
@@ -17172,10 +17178,10 @@ class $a extends ft.EventEmitter {
|
|
17172
17178
|
return;
|
17173
17179
|
}
|
17174
17180
|
clearTimeout(this._timers.userNoAnswerTimer), a.unshift(`Contact: ${this._contact}`);
|
17175
|
-
const
|
17176
|
-
Array.isArray(
|
17177
|
-
for (const I of
|
17178
|
-
I.type === "audio" && (T = !0, (!I.direction || I.direction === "sendrecv") && (y = !0)), I.type === "video" && (E = !0, (!I.direction || I.direction === "sendrecv") && (
|
17181
|
+
const A = n.parseSDP();
|
17182
|
+
Array.isArray(A.media) || (A.media = [A.media]);
|
17183
|
+
for (const I of A.media)
|
17184
|
+
I.type === "audio" && (T = !0, (!I.direction || I.direction === "sendrecv") && (y = !0)), I.type === "video" && (E = !0, (!I.direction || I.direction === "sendrecv") && (C = !0));
|
17179
17185
|
if (s && o.audio === !1) {
|
17180
17186
|
g = s.getAudioTracks();
|
17181
17187
|
for (const I of g)
|
@@ -17186,7 +17192,7 @@ class $a extends ft.EventEmitter {
|
|
17186
17192
|
for (const I of g)
|
17187
17193
|
s.removeTrack(I);
|
17188
17194
|
}
|
17189
|
-
!s && o.audio === void 0 && (o.audio = y), !s && o.video === void 0 && (o.video =
|
17195
|
+
!s && o.audio === void 0 && (o.audio = y), !s && o.video === void 0 && (o.video = C), !s && !T && !_.offerToReceiveAudio && (o.audio = !1), !s && !E && !_.offerToReceiveVideo && (o.video = !1), this._createRTCConnection(r, d), Promise.resolve().then(() => {
|
17190
17196
|
if (s)
|
17191
17197
|
return s;
|
17192
17198
|
if (o.audio || o.video)
|
@@ -18312,8 +18318,8 @@ class $a extends ft.EventEmitter {
|
|
18312
18318
|
audio: !0,
|
18313
18319
|
video: !0
|
18314
18320
|
};
|
18315
|
-
await new Promise((
|
18316
|
-
setTimeout(
|
18321
|
+
await new Promise((C) => {
|
18322
|
+
setTimeout(C, 100);
|
18317
18323
|
}), a = await t.rtcpPeer.createAnswer(y), this._sendMemberStartMessage(t, a);
|
18318
18324
|
}
|
18319
18325
|
const _ = h.streams[0].getAudioTracks(), g = h.streams[0].getVideoTracks(), T = [];
|
@@ -20209,7 +20215,7 @@ var QT = class {
|
|
20209
20215
|
Dt.warn(`WebSocket ${this._url} error: `, t);
|
20210
20216
|
}
|
20211
20217
|
};
|
20212
|
-
const bu = Ha, ZT = De, ev =
|
20218
|
+
const bu = Ha, ZT = De, ev = Cs, tv = Ct(), sv = bh, nv = ys(), rv = $u(), iv = Zt(), lv = QT, av = gr("JsSIP");
|
20213
20219
|
av("version %s", bu.version);
|
20214
20220
|
var ov = {
|
20215
20221
|
C: ZT,
|
@@ -20244,8 +20250,8 @@ function cv(c) {
|
|
20244
20250
|
formatted: o
|
20245
20251
|
};
|
20246
20252
|
}
|
20247
|
-
var
|
20248
|
-
|
20253
|
+
var At = {};
|
20254
|
+
At.forEach = async (c, t, n) => {
|
20249
20255
|
const a = [];
|
20250
20256
|
for (let o = 0; o < c.length; o++)
|
20251
20257
|
if (o in c) {
|
@@ -20254,23 +20260,23 @@ Ct.forEach = async (c, t, n) => {
|
|
20254
20260
|
}
|
20255
20261
|
await Promise.all(a);
|
20256
20262
|
};
|
20257
|
-
|
20263
|
+
At.forEachSeries = async (c, t, n) => {
|
20258
20264
|
for (let a = 0; a < c.length; a++)
|
20259
20265
|
a in c && await t.call(n || globalThis, await c[a], a, c);
|
20260
20266
|
};
|
20261
|
-
|
20267
|
+
At.map = async (c, t, n) => {
|
20262
20268
|
const a = [];
|
20263
20269
|
for (let o = 0; o < c.length; o++)
|
20264
20270
|
o in c && (a[o] = Promise.resolve(c[o]).then((s) => t.call(n || globalThis, s, o, c)));
|
20265
20271
|
return Promise.all(a);
|
20266
20272
|
};
|
20267
|
-
|
20273
|
+
At.mapSeries = async (c, t, n) => {
|
20268
20274
|
const a = [];
|
20269
20275
|
for (let o = 0; o < c.length; o++)
|
20270
20276
|
o in c && (a[o] = await t.call(n || globalThis, await c[o], o, c));
|
20271
20277
|
return a;
|
20272
20278
|
};
|
20273
|
-
|
20279
|
+
At.find = (c, t, n) => new Promise((a, o) => {
|
20274
20280
|
if (c.length === 0)
|
20275
20281
|
return a();
|
20276
20282
|
let s = 1;
|
@@ -20281,12 +20287,12 @@ Ct.find = (c, t, n) => new Promise((a, o) => {
|
|
20281
20287
|
Promise.resolve(c[r]).then((h) => t.call(n || globalThis, h, r, c)).then(d).catch(o);
|
20282
20288
|
}
|
20283
20289
|
});
|
20284
|
-
|
20290
|
+
At.findSeries = async (c, t, n) => {
|
20285
20291
|
for (let a = 0; a < c.length; a++)
|
20286
20292
|
if (await t.call(n || globalThis, await c[a], a, c))
|
20287
20293
|
return c[a];
|
20288
20294
|
};
|
20289
|
-
|
20295
|
+
At.findIndex = (c, t, n) => new Promise((a, o) => {
|
20290
20296
|
if (c.length === 0)
|
20291
20297
|
return a(-1);
|
20292
20298
|
let s = 1;
|
@@ -20297,12 +20303,12 @@ Ct.findIndex = (c, t, n) => new Promise((a, o) => {
|
|
20297
20303
|
Promise.resolve(c[r]).then((h) => t.call(n || globalThis, h, r, c)).then(d).catch(o);
|
20298
20304
|
}
|
20299
20305
|
});
|
20300
|
-
|
20306
|
+
At.findIndexSeries = async (c, t, n) => {
|
20301
20307
|
for (let a = 0; a < c.length; a++)
|
20302
20308
|
if (await t.call(n || globalThis, await c[a], a, c))
|
20303
20309
|
return a;
|
20304
20310
|
};
|
20305
|
-
|
20311
|
+
At.some = (c, t, n) => new Promise((a, o) => {
|
20306
20312
|
if (c.length === 0)
|
20307
20313
|
return a(!1);
|
20308
20314
|
let s = 1;
|
@@ -20317,13 +20323,13 @@ Ct.some = (c, t, n) => new Promise((a, o) => {
|
|
20317
20323
|
Promise.resolve(c[r]).then((h) => t.call(n || globalThis, h, r, c)).then(d).catch(o);
|
20318
20324
|
}
|
20319
20325
|
});
|
20320
|
-
|
20326
|
+
At.someSeries = async (c, t, n) => {
|
20321
20327
|
for (let a = 0; a < c.length; a++)
|
20322
20328
|
if (a in c && await t.call(n || globalThis, await c[a], a, c))
|
20323
20329
|
return !0;
|
20324
20330
|
return !1;
|
20325
20331
|
};
|
20326
|
-
|
20332
|
+
At.every = (c, t, n) => new Promise((a, o) => {
|
20327
20333
|
if (c.length === 0)
|
20328
20334
|
return a(!0);
|
20329
20335
|
let s = 1;
|
@@ -20338,13 +20344,13 @@ Ct.every = (c, t, n) => new Promise((a, o) => {
|
|
20338
20344
|
Promise.resolve(c[r]).then((h) => t.call(n || globalThis, h, r, c)).then(d).catch(o);
|
20339
20345
|
}
|
20340
20346
|
});
|
20341
|
-
|
20347
|
+
At.everySeries = async (c, t, n) => {
|
20342
20348
|
for (let a = 0; a < c.length; a++)
|
20343
20349
|
if (a in c && !await t.call(n || globalThis, await c[a], a, c))
|
20344
20350
|
return !1;
|
20345
20351
|
return !0;
|
20346
20352
|
};
|
20347
|
-
|
20353
|
+
At.filter = (c, t, n) => new Promise(async (a, o) => {
|
20348
20354
|
const s = [];
|
20349
20355
|
for (let d = 0; d < c.length; d++)
|
20350
20356
|
d in c && (s[d] = Promise.resolve(c[d]).then((h) => t.call(n || globalThis, h, d, c)).catch(o));
|
@@ -20353,13 +20359,13 @@ Ct.filter = (c, t, n) => new Promise(async (a, o) => {
|
|
20353
20359
|
await s[d] && r.push(await c[d]);
|
20354
20360
|
a(r);
|
20355
20361
|
});
|
20356
|
-
|
20362
|
+
At.filterSeries = async (c, t, n) => {
|
20357
20363
|
const a = [];
|
20358
20364
|
for (let o = 0; o < c.length; o++)
|
20359
20365
|
o in c && await t.call(n || globalThis, await c[o], o, c) && a.push(await c[o]);
|
20360
20366
|
return a;
|
20361
20367
|
};
|
20362
|
-
|
20368
|
+
At.reduce = async (c, t, n) => {
|
20363
20369
|
if (c.length === 0 && n === void 0)
|
20364
20370
|
throw TypeError("Reduce of empty array with no initial value");
|
20365
20371
|
let a, o;
|
@@ -20369,7 +20375,7 @@ Ct.reduce = async (c, t, n) => {
|
|
20369
20375
|
};
|
20370
20376
|
var Oh = {};
|
20371
20377
|
(function(c) {
|
20372
|
-
const t =
|
20378
|
+
const t = At;
|
20373
20379
|
Object.keys(t).forEach((n) => {
|
20374
20380
|
const a = n.charAt(0).toUpperCase() + n.slice(1);
|
20375
20381
|
c[`async${a}`] = async function(...o) {
|
@@ -20377,9 +20383,9 @@ var Oh = {};
|
|
20377
20383
|
};
|
20378
20384
|
});
|
20379
20385
|
})(Oh);
|
20380
|
-
const fv =
|
20386
|
+
const fv = At, hv = Oh;
|
20381
20387
|
var dv = Object.assign(fv, { instanceMethods: hv });
|
20382
|
-
const
|
20388
|
+
const An = new AudioContext(), Xt = {
|
20383
20389
|
NEW_CALL: "new_call",
|
20384
20390
|
CALL_CONFIRMED: "confirmed",
|
20385
20391
|
CALL_FAILED: "failed",
|
@@ -20419,7 +20425,7 @@ var _v = { exports: {} };
|
|
20419
20425
|
return { type: "throw", arg: re };
|
20420
20426
|
}
|
20421
20427
|
}
|
20422
|
-
var
|
20428
|
+
var C = "suspendedStart", A = "suspendedYield", I = "executing", H = "completed", $ = {};
|
20423
20429
|
function oe() {
|
20424
20430
|
}
|
20425
20431
|
function N() {
|
@@ -20460,26 +20466,26 @@ var _v = { exports: {} };
|
|
20460
20466
|
return { __await: ee };
|
20461
20467
|
};
|
20462
20468
|
function V(ee, W) {
|
20463
|
-
function G(be, xe,
|
20469
|
+
function G(be, xe, Ae, le) {
|
20464
20470
|
var ye = y(ee[be], ee, xe);
|
20465
20471
|
if (ye.type === "throw")
|
20466
20472
|
le(ye.arg);
|
20467
20473
|
else {
|
20468
20474
|
var nt = ye.arg, at = nt.value;
|
20469
20475
|
return at && typeof at == "object" && o.call(at, "__await") ? W.resolve(at.__await).then(function(Ee) {
|
20470
|
-
G("next", Ee,
|
20476
|
+
G("next", Ee, Ae, le);
|
20471
20477
|
}, function(Ee) {
|
20472
|
-
G("throw", Ee,
|
20478
|
+
G("throw", Ee, Ae, le);
|
20473
20479
|
}) : W.resolve(at).then(function(Ee) {
|
20474
|
-
nt.value = Ee,
|
20480
|
+
nt.value = Ee, Ae(nt);
|
20475
20481
|
}, function(Ee) {
|
20476
|
-
return G("throw", Ee,
|
20482
|
+
return G("throw", Ee, Ae, le);
|
20477
20483
|
});
|
20478
20484
|
}
|
20479
20485
|
}
|
20480
20486
|
var re;
|
20481
20487
|
function ge(be, xe) {
|
20482
|
-
function
|
20488
|
+
function Ae() {
|
20483
20489
|
return new W(function(le, ye) {
|
20484
20490
|
G(be, xe, le, ye);
|
20485
20491
|
});
|
@@ -20497,11 +20503,11 @@ var _v = { exports: {} };
|
|
20497
20503
|
// async functions in terms of async generators, it is especially
|
20498
20504
|
// important to get this right, even though it requires care.
|
20499
20505
|
re ? re.then(
|
20500
|
-
|
20506
|
+
Ae,
|
20501
20507
|
// Avoid propagating failures to Promises returned by later
|
20502
20508
|
// invocations of the iterator.
|
20503
|
-
|
20504
|
-
) :
|
20509
|
+
Ae
|
20510
|
+
) : Ae();
|
20505
20511
|
}
|
20506
20512
|
s(this, "_invoke", { value: ge });
|
20507
20513
|
}
|
@@ -20518,7 +20524,7 @@ var _v = { exports: {} };
|
|
20518
20524
|
});
|
20519
20525
|
};
|
20520
20526
|
function J(ee, W, G) {
|
20521
|
-
var re =
|
20527
|
+
var re = C;
|
20522
20528
|
return function(be, xe) {
|
20523
20529
|
if (re === I)
|
20524
20530
|
throw new Error("Generator is already running");
|
@@ -20528,9 +20534,9 @@ var _v = { exports: {} };
|
|
20528
20534
|
return st();
|
20529
20535
|
}
|
20530
20536
|
for (G.method = be, G.arg = xe; ; ) {
|
20531
|
-
var
|
20532
|
-
if (
|
20533
|
-
var le = F(
|
20537
|
+
var Ae = G.delegate;
|
20538
|
+
if (Ae) {
|
20539
|
+
var le = F(Ae, G);
|
20534
20540
|
if (le) {
|
20535
20541
|
if (le === $)
|
20536
20542
|
continue;
|
@@ -20540,7 +20546,7 @@ var _v = { exports: {} };
|
|
20540
20546
|
if (G.method === "next")
|
20541
20547
|
G.sent = G._sent = G.arg;
|
20542
20548
|
else if (G.method === "throw") {
|
20543
|
-
if (re ===
|
20549
|
+
if (re === C)
|
20544
20550
|
throw re = H, G.arg;
|
20545
20551
|
G.dispatchException(G.arg);
|
20546
20552
|
} else
|
@@ -20548,7 +20554,7 @@ var _v = { exports: {} };
|
|
20548
20554
|
re = I;
|
20549
20555
|
var ye = y(ee, W, G);
|
20550
20556
|
if (ye.type === "normal") {
|
20551
|
-
if (re = G.done ? H :
|
20557
|
+
if (re = G.done ? H : A, ye.arg === $)
|
20552
20558
|
continue;
|
20553
20559
|
return {
|
20554
20560
|
value: ye.arg,
|
@@ -20655,8 +20661,8 @@ var _v = { exports: {} };
|
|
20655
20661
|
if (ge.tryLoc === "root")
|
20656
20662
|
return G("end");
|
20657
20663
|
if (ge.tryLoc <= this.prev) {
|
20658
|
-
var xe = o.call(ge, "catchLoc"),
|
20659
|
-
if (xe &&
|
20664
|
+
var xe = o.call(ge, "catchLoc"), Ae = o.call(ge, "finallyLoc");
|
20665
|
+
if (xe && Ae) {
|
20660
20666
|
if (this.prev < ge.catchLoc)
|
20661
20667
|
return G(ge.catchLoc, !0);
|
20662
20668
|
if (this.prev < ge.finallyLoc)
|
@@ -20664,7 +20670,7 @@ var _v = { exports: {} };
|
|
20664
20670
|
} else if (xe) {
|
20665
20671
|
if (this.prev < ge.catchLoc)
|
20666
20672
|
return G(ge.catchLoc, !0);
|
20667
|
-
} else if (
|
20673
|
+
} else if (Ae) {
|
20668
20674
|
if (this.prev < ge.finallyLoc)
|
20669
20675
|
return G(ge.finallyLoc);
|
20670
20676
|
} else
|
@@ -20744,44 +20750,44 @@ var Dh = { exports: {} };
|
|
20744
20750
|
"warn",
|
20745
20751
|
"error"
|
20746
20752
|
];
|
20747
|
-
function s(
|
20748
|
-
var H =
|
20753
|
+
function s(A, I) {
|
20754
|
+
var H = A[I];
|
20749
20755
|
if (typeof H.bind == "function")
|
20750
|
-
return H.bind(
|
20756
|
+
return H.bind(A);
|
20751
20757
|
try {
|
20752
|
-
return Function.prototype.bind.call(H,
|
20758
|
+
return Function.prototype.bind.call(H, A);
|
20753
20759
|
} catch {
|
20754
20760
|
return function() {
|
20755
|
-
return Function.prototype.apply.apply(H, [
|
20761
|
+
return Function.prototype.apply.apply(H, [A, arguments]);
|
20756
20762
|
};
|
20757
20763
|
}
|
20758
20764
|
}
|
20759
20765
|
function r() {
|
20760
20766
|
console.log && (console.log.apply ? console.log.apply(console, arguments) : Function.prototype.apply.apply(console.log, [console, arguments])), console.trace && console.trace();
|
20761
20767
|
}
|
20762
|
-
function d(
|
20763
|
-
return
|
20768
|
+
function d(A) {
|
20769
|
+
return A === "debug" && (A = "log"), typeof console === n ? !1 : A === "trace" && a ? r : console[A] !== void 0 ? s(console, A) : console.log !== void 0 ? s(console, "log") : t;
|
20764
20770
|
}
|
20765
|
-
function h(
|
20771
|
+
function h(A, I) {
|
20766
20772
|
for (var H = 0; H < o.length; H++) {
|
20767
20773
|
var $ = o[H];
|
20768
|
-
this[$] = H <
|
20774
|
+
this[$] = H < A ? t : this.methodFactory($, A, I);
|
20769
20775
|
}
|
20770
20776
|
this.log = this.debug;
|
20771
20777
|
}
|
20772
|
-
function _(
|
20778
|
+
function _(A, I, H) {
|
20773
20779
|
return function() {
|
20774
|
-
typeof console !== n && (h.call(this, I, H), this[
|
20780
|
+
typeof console !== n && (h.call(this, I, H), this[A].apply(this, arguments));
|
20775
20781
|
};
|
20776
20782
|
}
|
20777
|
-
function g(
|
20778
|
-
return d(
|
20783
|
+
function g(A, I, H) {
|
20784
|
+
return d(A) || _.apply(this, arguments);
|
20779
20785
|
}
|
20780
|
-
function T(
|
20786
|
+
function T(A, I, H) {
|
20781
20787
|
var $ = this, oe;
|
20782
20788
|
I = I ?? "WARN";
|
20783
20789
|
var N = "loglevel";
|
20784
|
-
typeof
|
20790
|
+
typeof A == "string" ? N += ":" + A : typeof A == "symbol" && (N = void 0);
|
20785
20791
|
function j(D) {
|
20786
20792
|
var B = (o[D] || "silent").toUpperCase();
|
20787
20793
|
if (!(typeof window === n || !N)) {
|
@@ -20827,7 +20833,7 @@ var Dh = { exports: {} };
|
|
20827
20833
|
}
|
20828
20834
|
}
|
20829
20835
|
}
|
20830
|
-
$.name =
|
20836
|
+
$.name = A, $.levels = {
|
20831
20837
|
TRACE: 0,
|
20832
20838
|
DEBUG: 1,
|
20833
20839
|
INFO: 2,
|
@@ -20838,7 +20844,7 @@ var Dh = { exports: {} };
|
|
20838
20844
|
return oe;
|
20839
20845
|
}, $.setLevel = function(D, B) {
|
20840
20846
|
if (typeof D == "string" && $.levels[D.toUpperCase()] !== void 0 && (D = $.levels[D.toUpperCase()]), typeof D == "number" && D >= 0 && D <= $.levels.SILENT) {
|
20841
|
-
if (oe = D, B !== !1 && j(D), h.call($, D,
|
20847
|
+
if (oe = D, B !== !1 && j(D), h.call($, D, A), typeof console === n && D < $.levels.SILENT)
|
20842
20848
|
return "No console available for logging";
|
20843
20849
|
} else
|
20844
20850
|
throw "log.setLevel() called with invalid level: " + D;
|
@@ -20865,9 +20871,9 @@ var Dh = { exports: {} };
|
|
20865
20871
|
E.methodFactory
|
20866
20872
|
)), H;
|
20867
20873
|
};
|
20868
|
-
var
|
20874
|
+
var C = typeof window !== n ? window.log : void 0;
|
20869
20875
|
return E.noConflict = function() {
|
20870
|
-
return typeof window !== n && window.log === E && (window.log =
|
20876
|
+
return typeof window !== n && window.log === E && (window.log = C), E;
|
20871
20877
|
}, E.getLoggers = function() {
|
20872
20878
|
return y;
|
20873
20879
|
}, E.default = E, E;
|
@@ -20933,7 +20939,7 @@ const Qi = /* @__PURE__ */ ze(Ev), Sv = () => "WebRTCMetrics", yv = () => "5.0.3
|
|
20933
20939
|
DISCONNECTED: "disconnected",
|
20934
20940
|
FAILED: "failed",
|
20935
20941
|
CLOSED: "closed"
|
20936
|
-
},
|
20942
|
+
}, Cv = () => ({
|
20937
20943
|
...{
|
20938
20944
|
delta_time_to_measure_probes_ms: 0,
|
20939
20945
|
// Total time to measure all probes
|
@@ -21036,7 +21042,7 @@ const Qi = /* @__PURE__ */ ze(Ev), Sv = () => "WebRTCMetrics", yv = () => "5.0.3
|
|
21036
21042
|
timestamp_out: null,
|
21037
21043
|
ssrc: "",
|
21038
21044
|
direction: $e.OUTBOUND
|
21039
|
-
},
|
21045
|
+
}, Av = (c) => {
|
21040
21046
|
const t = {
|
21041
21047
|
pname: "",
|
21042
21048
|
call_id: "",
|
@@ -21484,22 +21490,22 @@ class kv {
|
|
21484
21490
|
x.AUDIO,
|
21485
21491
|
"total_packets_lost_in",
|
21486
21492
|
d
|
21487
|
-
),
|
21493
|
+
), C = gt(
|
21488
21494
|
this._reports,
|
21489
21495
|
x.AUDIO,
|
21490
21496
|
"total_packets_in",
|
21491
21497
|
d
|
21492
|
-
),
|
21498
|
+
), A = {
|
21493
21499
|
lost: y,
|
21494
21500
|
avg: Math.round(
|
21495
|
-
(y / (y +
|
21501
|
+
(y / (y + C) * 100 || 0) * 100
|
21496
21502
|
) / 100,
|
21497
21503
|
_unit: {
|
21498
21504
|
avg: "percent",
|
21499
21505
|
lost: "number"
|
21500
21506
|
}
|
21501
21507
|
};
|
21502
|
-
s[d].jitter = _, s[d].mos = E, s[d].traffic = T, s[d].bitrate = g, s[d].loss =
|
21508
|
+
s[d].jitter = _, s[d].mos = E, s[d].traffic = T, s[d].bitrate = g, s[d].loss = A;
|
21503
21509
|
} else {
|
21504
21510
|
const _ = {
|
21505
21511
|
avg: Xe(
|
@@ -21619,15 +21625,15 @@ class kv {
|
|
21619
21625
|
x.AUDIO,
|
21620
21626
|
"total_packets_lost_out",
|
21621
21627
|
d
|
21622
|
-
),
|
21628
|
+
), C = gt(
|
21623
21629
|
this._reports,
|
21624
21630
|
x.AUDIO,
|
21625
21631
|
"total_packets_out",
|
21626
21632
|
d
|
21627
|
-
),
|
21633
|
+
), A = {
|
21628
21634
|
lost: y,
|
21629
21635
|
avg: Math.round(
|
21630
|
-
(y / (y +
|
21636
|
+
(y / (y + C) * 100 || 0) * 100
|
21631
21637
|
) / 100,
|
21632
21638
|
_unit: {
|
21633
21639
|
avg: "percent",
|
@@ -21663,7 +21669,7 @@ class kv {
|
|
21663
21669
|
volatility: "percent"
|
21664
21670
|
}
|
21665
21671
|
};
|
21666
|
-
s[d].jitter = _, s[d].rtt = E, s[d].traffic = T, s[d].bitrate = g, s[d].loss =
|
21672
|
+
s[d].jitter = _, s[d].rtt = E, s[d].traffic = T, s[d].bitrate = g, s[d].loss = A, s[d].mos = I;
|
21667
21673
|
}
|
21668
21674
|
}), Object.keys(r[x.VIDEO]).forEach((d) => {
|
21669
21675
|
const h = r[x.VIDEO][d];
|
@@ -21777,7 +21783,7 @@ class kv {
|
|
21777
21783
|
x.VIDEO,
|
21778
21784
|
"total_packets_in",
|
21779
21785
|
d
|
21780
|
-
),
|
21786
|
+
), C = {
|
21781
21787
|
lost: E,
|
21782
21788
|
avg: Math.round(
|
21783
21789
|
(E / (E + y) * 100 || 0) * 100
|
@@ -21787,7 +21793,7 @@ class kv {
|
|
21787
21793
|
lost: "number"
|
21788
21794
|
}
|
21789
21795
|
};
|
21790
|
-
s[d].jitter = _, s[d].traffic = T, s[d].bitrate = g, s[d].loss =
|
21796
|
+
s[d].jitter = _, s[d].traffic = T, s[d].bitrate = g, s[d].loss = C;
|
21791
21797
|
} else {
|
21792
21798
|
const _ = {
|
21793
21799
|
avg: Xe(
|
@@ -21906,22 +21912,22 @@ class kv {
|
|
21906
21912
|
x.VIDEO,
|
21907
21913
|
"total_packets_lost_out",
|
21908
21914
|
d
|
21909
|
-
),
|
21915
|
+
), C = gt(
|
21910
21916
|
this._reports,
|
21911
21917
|
x.VIDEO,
|
21912
21918
|
"total_packets_out",
|
21913
21919
|
d
|
21914
|
-
),
|
21920
|
+
), A = {
|
21915
21921
|
lost: y,
|
21916
21922
|
avg: Math.round(
|
21917
|
-
(y / (y +
|
21923
|
+
(y / (y + C) * 100 || 0) * 100
|
21918
21924
|
) / 100,
|
21919
21925
|
_unit: {
|
21920
21926
|
avg: "percent",
|
21921
21927
|
lost: "number"
|
21922
21928
|
}
|
21923
21929
|
};
|
21924
|
-
s[d].jitter = _, s[d].rtt = E, s[d].traffic = T, s[d].bitrate = g, s[d].loss =
|
21930
|
+
s[d].jitter = _, s[d].rtt = E, s[d].traffic = T, s[d].bitrate = g, s[d].loss = A;
|
21925
21931
|
}
|
21926
21932
|
})), {
|
21927
21933
|
version: Nv,
|
@@ -22168,7 +22174,7 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22168
22174
|
const o = Number(c[q.PACKETS_RECEIVED]) || 0 - (a ? a[t].total_packets_in : 0), s = Number(c[q.PACKETS_LOST]) || 0 - (a ? a[t].total_packets_lost_in : 0), r = s - n[t].total_packets_lost_in, d = o - n[t].total_packets_in, h = o !== n[t].total_packets_in ? r * 100 / (r + d) : 0, _ = Number(c[q.BYTES_RECEIVED]) / 1024 - (a ? a[t].total_KBytes_in : 0), g = _ - n[t].total_KBytes_in, T = c[q.TIMESTAMP] || Date.now(), E = a ? a.timestamp : null;
|
22169
22175
|
let y = n.timestamp;
|
22170
22176
|
!y && E && (y = E);
|
22171
|
-
const
|
22177
|
+
const C = y ? T - y : 0, A = C > 0 ? g * 8e-3 * 1024 / C * 1e3 : 0;
|
22172
22178
|
return {
|
22173
22179
|
percentPacketsLost: h,
|
22174
22180
|
packetsReceived: o,
|
@@ -22177,7 +22183,7 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22177
22183
|
deltaPacketsLost: r,
|
22178
22184
|
KBytesReceived: _,
|
22179
22185
|
deltaKBytesReceived: g,
|
22180
|
-
kbsReceived:
|
22186
|
+
kbsReceived: A
|
22181
22187
|
};
|
22182
22188
|
}, Hv = (c) => c[q.CANDIDATE_TYPE] !== "relay" ? "" : c[q.RELAY_PROTOCOL] || "", Fv = (c) => {
|
22183
22189
|
if (!Object.prototype.hasOwnProperty.call(c, q.NETWORK_TYPE))
|
@@ -22465,7 +22471,7 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22465
22471
|
x.VIDEO,
|
22466
22472
|
d,
|
22467
22473
|
h
|
22468
|
-
), T = da(c, x.VIDEO, d), E = c[q.DECODER_IMPLEMENTATION] || null, y = c[q.CODEC_ID] || null,
|
22474
|
+
), T = da(c, x.VIDEO, d), E = c[q.DECODER_IMPLEMENTATION] || null, y = c[q.CODEC_ID] || null, C = jf(c), A = qv(
|
22469
22475
|
c,
|
22470
22476
|
d,
|
22471
22477
|
h
|
@@ -22544,27 +22550,27 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22544
22550
|
{
|
22545
22551
|
ssrc: r,
|
22546
22552
|
type: ne.VIDEO,
|
22547
|
-
value: { total_nack_sent_in:
|
22553
|
+
value: { total_nack_sent_in: A.nackCount }
|
22548
22554
|
},
|
22549
22555
|
{
|
22550
22556
|
ssrc: r,
|
22551
22557
|
type: ne.VIDEO,
|
22552
|
-
value: { delta_nack_sent_in:
|
22558
|
+
value: { delta_nack_sent_in: A.deltaNackCount }
|
22553
22559
|
},
|
22554
22560
|
{
|
22555
22561
|
ssrc: r,
|
22556
22562
|
type: ne.VIDEO,
|
22557
|
-
value: { total_pli_sent_in:
|
22563
|
+
value: { total_pli_sent_in: A.pliCount }
|
22558
22564
|
},
|
22559
22565
|
{
|
22560
22566
|
ssrc: r,
|
22561
22567
|
type: ne.VIDEO,
|
22562
|
-
value: { delta_pli_sent_in:
|
22568
|
+
value: { delta_pli_sent_in: A.deltaPliCount }
|
22563
22569
|
},
|
22564
22570
|
{
|
22565
22571
|
ssrc: r,
|
22566
22572
|
type: ne.VIDEO,
|
22567
|
-
value: { size_in:
|
22573
|
+
value: { size_in: C }
|
22568
22574
|
}
|
22569
22575
|
];
|
22570
22576
|
}
|
@@ -22615,11 +22621,11 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22615
22621
|
];
|
22616
22622
|
}
|
22617
22623
|
if (c[q.MEDIA_TYPE] === x.VIDEO) {
|
22618
|
-
const _ = c[q.ENCODER_IMPLEMENTATION] || null, g = c[q.CODEC_ID] || null, T = $v(c, d), E = jf(c), y = jv(c),
|
22624
|
+
const _ = c[q.ENCODER_IMPLEMENTATION] || null, g = c[q.CODEC_ID] || null, T = $v(c, d), E = jf(c), y = jv(c), C = Vv(
|
22619
22625
|
c,
|
22620
22626
|
d,
|
22621
22627
|
h
|
22622
|
-
),
|
22628
|
+
), A = $f(c, x.VIDEO, d, h);
|
22623
22629
|
return [
|
22624
22630
|
{
|
22625
22631
|
ssrc: r,
|
@@ -22629,27 +22635,27 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22629
22635
|
{
|
22630
22636
|
ssrc: r,
|
22631
22637
|
type: ne.VIDEO,
|
22632
|
-
value: { total_packets_out:
|
22638
|
+
value: { total_packets_out: A.packetsSent }
|
22633
22639
|
},
|
22634
22640
|
{
|
22635
22641
|
ssrc: r,
|
22636
22642
|
type: ne.VIDEO,
|
22637
|
-
value: { delta_packets_out:
|
22643
|
+
value: { delta_packets_out: A.deltaPacketsSent }
|
22638
22644
|
},
|
22639
22645
|
{
|
22640
22646
|
ssrc: r,
|
22641
22647
|
type: ne.VIDEO,
|
22642
|
-
value: { total_KBytes_out:
|
22648
|
+
value: { total_KBytes_out: A.KBytesSent }
|
22643
22649
|
},
|
22644
22650
|
{
|
22645
22651
|
ssrc: r,
|
22646
22652
|
type: ne.VIDEO,
|
22647
|
-
value: { delta_KBytes_out:
|
22653
|
+
value: { delta_KBytes_out: A.deltaKBytesSent }
|
22648
22654
|
},
|
22649
22655
|
{
|
22650
22656
|
ssrc: r,
|
22651
22657
|
type: ne.VIDEO,
|
22652
|
-
value: { delta_kbs_out:
|
22658
|
+
value: { delta_kbs_out: A.kbsSent }
|
22653
22659
|
},
|
22654
22660
|
{
|
22655
22661
|
ssrc: r,
|
@@ -22674,22 +22680,22 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22674
22680
|
{
|
22675
22681
|
ssrc: r,
|
22676
22682
|
type: ne.VIDEO,
|
22677
|
-
value: { total_nack_received_out:
|
22683
|
+
value: { total_nack_received_out: C.nackCount }
|
22678
22684
|
},
|
22679
22685
|
{
|
22680
22686
|
ssrc: r,
|
22681
22687
|
type: ne.VIDEO,
|
22682
|
-
value: { delta_nack_received_out:
|
22688
|
+
value: { delta_nack_received_out: C.deltaNackCount }
|
22683
22689
|
},
|
22684
22690
|
{
|
22685
22691
|
ssrc: r,
|
22686
22692
|
type: ne.VIDEO,
|
22687
|
-
value: { total_pli_received_out:
|
22693
|
+
value: { total_pli_received_out: C.pliCount }
|
22688
22694
|
},
|
22689
22695
|
{
|
22690
22696
|
ssrc: r,
|
22691
22697
|
type: ne.VIDEO,
|
22692
|
-
value: { delta_pli_received_out:
|
22698
|
+
value: { delta_pli_received_out: C.deltaPliCount }
|
22693
22699
|
},
|
22694
22700
|
{
|
22695
22701
|
ssrc: r,
|
@@ -22858,23 +22864,23 @@ const js = "extractor ", Lf = (c, t, n, a) => {
|
|
22858
22864
|
}
|
22859
22865
|
return [];
|
22860
22866
|
}, Ka = (c) => c < 0 ? 1 : c > 100 ? 4.5 : 1 + 0.035 * c + 7 / 1e6 * c * (c - 60) * (100 - c), Jv = (c, t = x.AUDIO, n, a, o) => {
|
22861
|
-
const s = ct(o, c, $e.INBOUND), r = ct(o, n, $e.INBOUND), d = ct(o, a, $e.INBOUND), h = [], _ = [], g = s[t].percent_packets_lost_in, T = s[t].delta_jitter_ms_in, E = r && r[t].delta_jitter_ms_in || null, y = d && d[t].delta_jitter_ms_in || null,
|
22862
|
-
|
22867
|
+
const s = ct(o, c, $e.INBOUND), r = ct(o, n, $e.INBOUND), d = ct(o, a, $e.INBOUND), h = [], _ = [], g = s[t].percent_packets_lost_in, T = s[t].delta_jitter_ms_in, E = r && r[t].delta_jitter_ms_in || null, y = d && d[t].delta_jitter_ms_in || null, C = c.data.delta_rtt_connectivity_ms, A = n && n.data.delta_rtt_connectivity_ms || null, I = a && a.data.delta_rtt_connectivity_ms || null;
|
22868
|
+
C && h.push(C), A && h.push(A), I && h.push(I), T && _.push(T), n && E && _.push(E), a && y && _.push(y);
|
22863
22869
|
const H = h.length > 0 ? Gs(h) : 100, $ = _.length > 0 ? Gs(_) : 10, oe = 93.2 - g, N = 0.18 * oe * oe - 27.9 * oe + 1126.62, j = (H + $) / 2, Se = j - 177.3 < 0 ? 0 : 1, ve = 0.024 * j + 0.11 * (j - 177.3) * Se, k = N - ve;
|
22864
22870
|
return Ka(k);
|
22865
22871
|
}, zv = (c, t = x.AUDIO, n, a, o) => {
|
22866
|
-
const s = ct(o, c, $e.OUTBOUND), r = ct(o, n, $e.OUTBOUND), d = ct(o, a, $e.OUTBOUND), h = [], _ = [], g = s[t].percent_packets_lost_out, T = s[t].delta_rtt_ms_out, E = r && r[t].delta_rtt_ms_out || null, y = d && d[t].delta_rtt_ms_out || null,
|
22867
|
-
T ? h.push(T) : H && h.push(H), E ? h.push(E) : $ && h.push($), y ? h.push(y) : oe && h.push(oe),
|
22872
|
+
const s = ct(o, c, $e.OUTBOUND), r = ct(o, n, $e.OUTBOUND), d = ct(o, a, $e.OUTBOUND), h = [], _ = [], g = s[t].percent_packets_lost_out, T = s[t].delta_rtt_ms_out, E = r && r[t].delta_rtt_ms_out || null, y = d && d[t].delta_rtt_ms_out || null, C = s[t].delta_jitter_ms_out, A = r && r[t].delta_jitter_ms_out || null, I = d && d[t].delta_jitter_ms_out || null, H = c.data.delta_rtt_connectivity_ms, $ = n && n.data.delta_rtt_connectivity_ms || null, oe = a && a.data.delta_rtt_connectivity_ms || null;
|
22873
|
+
T ? h.push(T) : H && h.push(H), E ? h.push(E) : $ && h.push($), y ? h.push(y) : oe && h.push(oe), C && _.push(C), n && A && _.push(A), a && I && _.push(I);
|
22868
22874
|
const N = h.length > 0 ? Gs(h) : 100, j = _.length > 0 ? Gs(_) : 10, Se = 93.2 - g, ve = 0.18 * Se * Se - 27.9 * Se + 1126.62, k = (N + j) / 2, D = k - 177.3 < 0 ? 0 : 1, B = 0.024 * k + 0.11 * (k - 177.3) * D, V = ve - B;
|
22869
22875
|
return Ka(V);
|
22870
22876
|
}, Xv = (c, t = x.AUDIO, n, a, o) => {
|
22871
|
-
const s = ct(o, c, $e.INBOUND), r = ct(o, n, $e.INBOUND), d = ct(o, a, $e.INBOUND), h = [], _ = [], g = s[t].percent_packets_lost_in / 100, T = s[t].delta_jitter_ms_in, E = r && r[t].delta_jitter_ms_in || null, y = d && d[t].delta_jitter_ms_in || null,
|
22872
|
-
|
22877
|
+
const s = ct(o, c, $e.INBOUND), r = ct(o, n, $e.INBOUND), d = ct(o, a, $e.INBOUND), h = [], _ = [], g = s[t].percent_packets_lost_in / 100, T = s[t].delta_jitter_ms_in, E = r && r[t].delta_jitter_ms_in || null, y = d && d[t].delta_jitter_ms_in || null, C = c.data.delta_rtt_connectivity_ms, A = n && n.data.delta_rtt_connectivity_ms || null, I = a && a.data.delta_rtt_connectivity_ms || null;
|
22878
|
+
C && h.push(C), A && h.push(A), I && h.push(I), T && _.push(T), r && E && _.push(E), d && y && _.push(y);
|
22873
22879
|
const H = h.length > 0 ? Gs(h) : 100, $ = _.length > 0 ? Gs(_) : 10, oe = 0, N = 19.8, j = 29.7, Se = 30, ve = (H + $) / 2 + Se, k = ve - 177.3 < 0 ? 0 : 1, D = 0.024 * ve + 0.11 * (ve - 177.3) * k, V = 93.2 - (oe + N * Math.log(1 + j * g) + D);
|
22874
22880
|
return Ka(V);
|
22875
22881
|
}, Qv = (c, t = x.AUDIO, n, a, o) => {
|
22876
|
-
const s = ct(o, c, $e.OUTBOUND), r = ct(o, n, $e.OUTBOUND), d = ct(o, a, $e.OUTBOUND), h = [], _ = [], g = s[t].percent_packets_lost_out / 100, T = s[t].delta_rtt_ms_out, E = r && r[t].delta_rtt_ms_out || null, y = d && d[t].delta_rtt_ms_out || null,
|
22877
|
-
T ? h.push(T) : H && h.push(H), E ? h.push(E) : $ && h.push($), y ? h.push(y) : oe && h.push(oe),
|
22882
|
+
const s = ct(o, c, $e.OUTBOUND), r = ct(o, n, $e.OUTBOUND), d = ct(o, a, $e.OUTBOUND), h = [], _ = [], g = s[t].percent_packets_lost_out / 100, T = s[t].delta_rtt_ms_out, E = r && r[t].delta_rtt_ms_out || null, y = d && d[t].delta_rtt_ms_out || null, C = s[t].delta_jitter_ms_out, A = r && r[t].delta_jitter_ms_out || null, I = d && d[t].delta_jitter_ms_out || null, H = c.data.delta_rtt_connectivity_ms, $ = n && n.data.delta_rtt_connectivity_ms || null, oe = a && a.data.delta_rtt_connectivity_ms || null;
|
22883
|
+
T ? h.push(T) : H && h.push(H), E ? h.push(E) : $ && h.push($), y ? h.push(y) : oe && h.push(oe), C && _.push(C), r && A && _.push(A), d && I && _.push(I);
|
22878
22884
|
const N = h.length > 0 ? Gs(h) : 100, j = _.length > 0 ? Gs(_) : 10, Se = 0, ve = 19.8, k = 29.7, D = 30, B = (N + j) / 2 + D, V = B - 177.3 < 0 ? 0 : 1, J = 0.024 * B + 0.11 * (B - 177.3) * V, X = 93.2 - (Se + ve * Math.log(1 + k * g) + J);
|
22879
22885
|
return Ka(X);
|
22880
22886
|
};
|
@@ -22886,7 +22892,7 @@ class Zv {
|
|
22886
22892
|
}, this._id = Ov(), this._moduleName = this._id, this._probeId = n, this._config = t, this._exporter = new kv(t), this._state = gs.IDLE, this.registerToPCEvents(), Rn(this._moduleName, `new collector created for probe ${this._probeId}`);
|
22887
22893
|
}
|
22888
22894
|
analyze(t, n, a, o) {
|
22889
|
-
const s = (h, _) => h === x.AUDIO ? _ === zt.INBOUND_RTP ? { ...Nh } : { ...Uh } : _ === zt.INBOUND_RTP ? { ...Ph } : { ...xh }, r =
|
22895
|
+
const s = (h, _) => h === x.AUDIO ? _ === zt.INBOUND_RTP ? { ...Nh } : { ...Uh } : _ === zt.INBOUND_RTP ? { ...Ph } : { ...xh }, r = Av(n);
|
22890
22896
|
r.pname = this._config.pname, r.call_id = this._config.cid, r.user_id = this._config.uid, r.count = n ? n.count + 1 : 1;
|
22891
22897
|
let d = null;
|
22892
22898
|
return t.forEach((h) => {
|
@@ -23246,7 +23252,7 @@ class tE {
|
|
23246
23252
|
const t = () => {
|
23247
23253
|
this._probes.forEach((s) => s.start());
|
23248
23254
|
}, n = async () => Promise.all(this._probes.map((s) => s.takeReferenceStats())), a = () => this.isIdle ? !1 : !this._config.stopAfter || this._config.stopAfter < 0 ? !0 : Date.now() < this._startedTime + this._config.stopAfter, o = async () => {
|
23249
|
-
const s =
|
23255
|
+
const s = Cv(), r = this._probes.filter((d) => d.isRunning);
|
23250
23256
|
for (const d of r) {
|
23251
23257
|
const h = await d.collectStats();
|
23252
23258
|
h && s.probes.push(h), Pe(Rt, `got probe ${d.id}`), await kf(0);
|
@@ -23386,8 +23392,8 @@ class lE {
|
|
23386
23392
|
}
|
23387
23393
|
beginCalculation(t, n) {
|
23388
23394
|
this.clearVolumeInterval(n);
|
23389
|
-
const a =
|
23390
|
-
a.smoothingTimeConstant = 0.8, a.fftSize = 1024, o.connect(a), a.connect(s), s.connect(
|
23395
|
+
const a = An.createAnalyser(), o = An.createMediaStreamSource(t), s = An.createScriptProcessor(2048, 1, 1);
|
23396
|
+
a.smoothingTimeConstant = 0.8, a.fftSize = 1024, o.connect(a), a.connect(s), s.connect(An.destination), this.intervals[n] = setInterval(() => {
|
23391
23397
|
const r = new Uint8Array(a.frequencyBinCount);
|
23392
23398
|
a.getByteFrequencyData(r);
|
23393
23399
|
let d = 0;
|
@@ -23821,14 +23827,14 @@ class oE {
|
|
23821
23827
|
var r;
|
23822
23828
|
if (a == null)
|
23823
23829
|
return;
|
23824
|
-
const o = new MediaStream(), s =
|
23830
|
+
const o = new MediaStream(), s = An.createMediaStreamDestination();
|
23825
23831
|
if (a.connection.getReceivers().forEach((d) => {
|
23826
23832
|
n.forEach((h) => {
|
23827
|
-
o.addTrack(d.track), d.track.id !== h.id &&
|
23833
|
+
o.addTrack(d.track), d.track.id !== h.id && An.createMediaStreamSource(new MediaStream([h])).connect(s);
|
23828
23834
|
});
|
23829
23835
|
}), t[0].roomId === this.currentActiveRoomId) {
|
23830
23836
|
const d = this.getActiveStream();
|
23831
|
-
|
23837
|
+
An.createMediaStreamSource(d).connect(s);
|
23832
23838
|
}
|
23833
23839
|
(r = a.connection) != null && r.getSenders()[0] && (await a.connection.getSenders()[0].replaceTrack(s.stream.getTracks()[0]), this.muteReconfigure(a));
|
23834
23840
|
});
|
@@ -24054,12 +24060,15 @@ class oE {
|
|
24054
24060
|
}, this.context.emit("changeCallMetrics", this.callMetrics);
|
24055
24061
|
}
|
24056
24062
|
getCallQuality(t) {
|
24063
|
+
console.log("LOG 1 before createProbe");
|
24057
24064
|
const n = new nE(this.metricConfig), a = n.createProbe(t.connection, {
|
24058
24065
|
cid: t._id
|
24059
|
-
})
|
24066
|
+
});
|
24067
|
+
console.log("LOG 2 after createProbe");
|
24068
|
+
const o = [];
|
24060
24069
|
let s;
|
24061
24070
|
a.onreport = (r) => {
|
24062
|
-
Object.entries(r.audio).forEach(([_, g]) => {
|
24071
|
+
console.log("LOG 3 in onreport"), Object.entries(r.audio).forEach(([_, g]) => {
|
24063
24072
|
g.direction === "inbound" && !o.includes(_) && (o.push(_), s = _);
|
24064
24073
|
});
|
24065
24074
|
const d = r.audio[s];
|