Module: kamailio
Branch: master
Commit: b9cfe696db5f7bbcbe6fc8c3ae63b4f9d640e311
URL: https://github.com/kamailio/kamailio/commit/b9cfe696db5f7bbcbe6fc8c3ae63b4f…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2019-09-02T13:47:22+02:00
modules: readme files regenerated - phonenum ... [skip ci]
---
Modified: src/modules/phonenum/README
---
Diff: https://github.com/kamailio/kamailio/commit/b9cfe696db5f7bbcbe6fc8c3ae63b4f…
Patch: https://github.com/kamailio/kamailio/commit/b9cfe696db5f7bbcbe6fc8c3ae63b4f…
---
diff --git a/src/modules/phonenum/README b/src/modules/phonenum/README
index 842e2cfcc7..ebe872869b 100644
--- a/src/modules/phonenum/README
+++ b/src/modules/phonenum/README
@@ -26,6 +26,7 @@ Daniel-Constantin Mierla
3. Parameters
3.1. smode (int)
+ 3.2. resid (str)
4. Functions
@@ -37,8 +38,9 @@ Daniel-Constantin Mierla
List of Examples
1.1. Set smode parameter
- 1.2. phonenum_match usage
- 1.3. phonenum_match_cn usage
+ 1.2. Set resid parameter
+ 1.3. phonenum_match usage
+ 1.4. phonenum_match_cn usage
Chapter 1. Admin Guide
@@ -53,6 +55,7 @@ Chapter 1. Admin Guide
3. Parameters
3.1. smode (int)
+ 3.2. resid (str)
4. Functions
@@ -95,10 +98,11 @@ Chapter 1. Admin Guide
3. Parameters
3.1. smode (int)
+ 3.2. resid (str)
3.1. smode (int)
- Phone number search mode.
+ Phone number search mode (not in use yet).
Default value is “0”.
@@ -107,6 +111,23 @@ Chapter 1. Admin Guide
modparam("phonenum", "smode", 0)
...
+3.2. resid (str)
+
+ Preregister result container id during initialization, enabling the use
+ of the module in KEMI scripts. In native Kamailio.cfg file,
+ registration is done when parsing config and finding variables.
+
+ Default value is “” (empty).
+
+ Example 1.2. Set resid parameter
+...
+modparam("phonenum", "resid", "src")
+...
+if(phonenum_match("1-484-555-8888", "src")) {
+ ...
+}
+...
+
4. Functions
4.1. phonenum_match(num, pvc)
@@ -115,14 +136,14 @@ modparam("phonenum", "smode", 0)
4.1. phonenum_match(num, pvc)
Match num against the libphonenumber and set the attributes inside the
- pvc container. The function has to be called before accessing a key
- via: $phn(pvc=>key).
+ pvc result container. The function has to be called before accessing a
+ key via: $phn(pvc=>key).
The parameters can be static strings or strings with variables.
It can be used from ANY_ROUTE.
- Example 1.2. phonenum_match usage
+ Example 1.3. phonenum_match usage
...
if(phonenum_match("1-484-555-8888", "src")) {
if($phn(src=>valid)==1) {
@@ -144,7 +165,7 @@ if(phonenum_match("1-484-555-8888", "src")) {
It can be used from ANY_ROUTE.
- Example 1.3. phonenum_match_cn usage
+ Example 1.4. phonenum_match_cn usage
...
if(phonenum_match_cn("1-484-555-8888", "US", "src")) {
if($phn(src=>valid)==1) {
Module: kamailio
Branch: master
Commit: d2bac426192c074368bf78014e0d1d0ca97f3274
URL: https://github.com/kamailio/kamailio/commit/d2bac426192c074368bf78014e0d1d0…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2019-09-02T13:45:16+02:00
phonenum: docs for resid parameter
---
Modified: src/modules/phonenum/doc/phonenum_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/d2bac426192c074368bf78014e0d1d0…
Patch: https://github.com/kamailio/kamailio/commit/d2bac426192c074368bf78014e0d1d0…
---
diff --git a/src/modules/phonenum/doc/phonenum_admin.xml b/src/modules/phonenum/doc/phonenum_admin.xml
index 402edfdb60..d30c2026ee 100644
--- a/src/modules/phonenum/doc/phonenum_admin.xml
+++ b/src/modules/phonenum/doc/phonenum_admin.xml
@@ -71,7 +71,7 @@
<section id="phonenum.p.smode">
<title><varname>smode</varname> (int)</title>
<para>
- Phone number search mode.
+ Phone number search mode (not in use yet).
</para>
<para>
<emphasis>
@@ -87,7 +87,31 @@ modparam("phonenum", "smode", 0)
</programlisting>
</example>
</section>
-
+ <section id="phonenum.p.resid">
+ <title><varname>resid</varname> (str)</title>
+ <para>
+ Preregister result container id during initialization, enabling the use
+ of the module in KEMI scripts. In native &kamailio;.cfg file, registration
+ is done when parsing config and finding variables.
+ </para>
+ <para>
+ <emphasis>
+ Default value is <quote></quote> (empty).
+ </emphasis>
+ </para>
+ <example>
+ <title>Set <varname>resid</varname> parameter</title>
+ <programlisting format="linespecific">
+...
+modparam("phonenum", "resid", "src")
+...
+if(phonenum_match("1-484-555-8888", "src")) {
+ ...
+}
+...
+</programlisting>
+ </example>
+ </section>
</section>
<section>
@@ -98,7 +122,7 @@ modparam("phonenum", "smode", 0)
</title>
<para>
Match num against the libphonenumber and set the attributes inside
- the pvc container. The function has to be called before accessing
+ the pvc result container. The function has to be called before accessing
a key via: $phn(pvc=>key).
</para>
<para>
### Description
Not shure is this relevant issue.
according to rfc3261:
> When a tag is generated by a UA for insertion into a request or
> response, it MUST be globally unique and cryptographically random
> with at least 32 bits of randomness.
Kamailio has 16 instead and distribution is not good.
I look at tags for 419485 sip flows (different callid) and table below (top keys ordered by count):
tag suffix; count for different flows with this suffix
ed54 6258
d118 5988
56ce 5923
a7a5 5220
de51 2150
82d8 1143
cf52 890
af92 740
7b5f 534
85f7 307
e553 163
7f7e 138
1d55 130
1afe 62
5a69 43
7caa 18
8474 18
9db2 18
11d3 18
f9ff 18
5420 17
dae6 17
908d 17
ede4 17
09ee 17
96be 17
25dc 17
af6d 16
2506 16
3da0 16
f161 16
1c29 16
#### SIP Traffic
To: <sip:039*101@host:5071>;tag=555d2c3eafafcba8ac92b676e91bb6ed.58eb
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/1164
Module: kamailio
Branch: master
Commit: e4ae7c7a7c7e8696870535e3399c8b9ddf585a06
URL: https://github.com/kamailio/kamailio/commit/e4ae7c7a7c7e8696870535e3399c8b9…
Author: Henning Westerholt <hw(a)skalatan.de>
Committer: Henning Westerholt <hw(a)skalatan.de>
Date: 2019-09-02T09:54:21+02:00
tm: improve from-tags to include more randomness and use the recommended size from RFC 3261 (GH #1164)
- improve from-tag generation for uac request to include more randomness (request uri)
- use the recommended size of 32 bit randomness from RFC 3261
- implementation could be further improved by using a cryptographic hash algorithm
- related to GH #1164
---
Modified: src/modules/tm/dlg.c
Modified: src/modules/tm/rpc_uac.c
Modified: src/modules/tm/t_msgbuilder.c
Modified: src/modules/tm/uac.c
Modified: src/modules/tm/uac.h
---
Diff: https://github.com/kamailio/kamailio/commit/e4ae7c7a7c7e8696870535e3399c8b9…
Patch: https://github.com/kamailio/kamailio/commit/e4ae7c7a7c7e8696870535e3399c8b9…