kamailio
13 months agosmsops: fix parsing of validity period
Aleksandar Yosifov [Wed, 17 Mar 2021 10:45:20 +0000 (12:45 +0200)]
smsops: fix parsing of validity period

- Validity period is present only for SUBMIT
msg type and it is an optional parameter.
For now supports only Relative VP format.

(cherry picked from commit c4b1d0ab700ea03869114d08daa78ab6a6a56b96)

13 months agopresence: do not init db in dmq worker for in-memory only mode
Daniel-Constantin Mierla [Fri, 12 Mar 2021 14:30:49 +0000 (15:30 +0100)]
presence: do not init db in dmq worker for in-memory only mode

- GH #2642

(cherry picked from commit 2b475553ef77f63cb444c34ad6c2df0ea237c88b)

13 months agoregistrar: documented lookup_to_dset() cfg function [skip ci]
Daniel-Constantin Mierla [Fri, 12 Mar 2021 08:02:17 +0000 (09:02 +0100)]
registrar: documented lookup_to_dset() cfg function [skip ci]

- function available for long time, but somehow was not documented
- GH #2623

(cherry picked from commit 56cdf70ea008b5401bdd7d1824f15788f85fc6fa)

13 months agouac: exposed uac_auth_mode() also as uac_mode([mode]) to match docs
Daniel-Constantin Mierla [Thu, 11 Mar 2021 17:39:46 +0000 (18:39 +0100)]
uac: exposed uac_auth_mode() also as uac_mode([mode]) to match docs

(cherry picked from commit bb1fe2fc12cb0499c5242c220dd8065e83fe6e61)

13 months agouac: docs - listed uac_auth_mode() function
Daniel-Constantin Mierla [Thu, 11 Mar 2021 17:39:16 +0000 (18:39 +0100)]
uac: docs - listed uac_auth_mode() function

(cherry picked from commit be4e1843c54e70206688c1f2d1f5483165baef8f)

13 months agotm: log message if starting cancel retransmission fails
Daniel-Constantin Mierla [Thu, 11 Mar 2021 16:28:09 +0000 (17:28 +0100)]
tm: log message if starting cancel retransmission fails

(cherry picked from commit afe84defa4ab391064c266e15f557415c5249f7c)

13 months ago cplc: permanent contact not skipped by lookup anymore
easyrider14 [Wed, 10 Mar 2021 09:54:25 +0000 (10:54 +0100)]
 cplc: permanent contact not skipped by lookup anymore

- a permanently registered contact has an "expires" value of 0 in usrloc
  when processing lookup, cplc module checks that contacts are not expired by
  checking that the "expires" value of the contact is not lower than current
  time
  as a consequence, permanently registered contact are alsways skipped and
  never targeted

(cherry picked from commit 525ee139abcb45f71bda42b417b5f8e75c12a622)

13 months agortp_media_server: Makefile - removed unnecessary DEFS+=-DKAMAILIO_MOD_INTERFACE
Daniel-Constantin Mierla [Tue, 9 Mar 2021 11:41:37 +0000 (12:41 +0100)]
rtp_media_server: Makefile - removed unnecessary DEFS+=-DKAMAILIO_MOD_INTERFACE

(cherry picked from commit 7532f864cb9698aff95b9023bc9ff6959a41fd3f)

13 months agousrloc: adjusted rpc reply text when the location domain table is not found
Daniel-Constantin Mierla [Tue, 9 Mar 2021 11:27:10 +0000 (12:27 +0100)]
usrloc: adjusted rpc reply text when the location domain table is not found

(cherry picked from commit d3a36ed6757eeda42dc32608a63b857ee9a67bb9)

13 months agopv: handle missing fields (otcid, instance) for $banch() and $sbranch()
Daniel-Constantin Mierla [Tue, 9 Mar 2021 10:38:26 +0000 (11:38 +0100)]
pv: handle missing fields (otcid, instance) for $banch() and $sbranch()

(cherry picked from commit 0c4becd70428ef15be76fb0aa53932e5803c6bd0)

13 months agotextops: docs - note about search() doing posix regex matching
Daniel-Constantin Mierla [Wed, 3 Mar 2021 16:49:32 +0000 (17:49 +0100)]
textops: docs - note about search() doing posix regex matching

(cherry picked from commit 0cbee55284c4f4d5fef09a3185de31d04776e569)

13 months agoims_diameter_server: fix check for addAVPsfromJSON return code
Riccardo Villa [Wed, 24 Feb 2021 08:56:44 +0000 (09:56 +0100)]
ims_diameter_server: fix check for addAVPsfromJSON return code

(cherry picked from commit 88d38bd306f595585af6e972ac529b40d7a93b58)

13 months agoims_diameter_server: drop cdp session to avoid deadlock
Riccardo Villa [Wed, 24 Feb 2021 08:55:46 +0000 (09:55 +0100)]
ims_diameter_server: drop cdp session to avoid deadlock

(cherry picked from commit 84c342277f2a73196cb377476f2b80e6b4085e7b)

13 months agoims_diameter_server: fix initialization of s_message
Riccardo Villa [Wed, 24 Feb 2021 08:54:47 +0000 (09:54 +0100)]
ims_diameter_server: fix initialization of s_message

(cherry picked from commit faf1edabf732af5a24ad0399098ad11e27b3a1ab)

13 months agoims_diameter_server: check response is not null before json conversion
Riccardo Villa [Wed, 24 Feb 2021 08:52:59 +0000 (09:52 +0100)]
ims_diameter_server: check response is not null before json conversion

(cherry picked from commit 6968f1df9e9d3d66810df910d290f3d9368255fe)

13 months agoxmlrpc: fixed error assigning to str variable added by previous commit
Daniel-Constantin Mierla [Tue, 2 Mar 2021 07:20:12 +0000 (08:20 +0100)]
xmlrpc: fixed error assigning to str variable added by previous commit

(cherry picked from commit 4c6715b5e4a0938ece2937a787c6d2ed6e81a3d8)

13 months agoctl: handle null char* and str* values everywhere
Daniel-Constantin Mierla [Mon, 1 Mar 2021 18:14:34 +0000 (19:14 +0100)]
ctl: handle null char* and str* values everywhere

- not all cases were covered

(cherry picked from commit fa0d2f05ad5124f6166a0384265a827187c6c83f)

13 months agoxmlrpc: use <nil/> for null string values
Daniel-Constantin Mierla [Mon, 1 Mar 2021 17:47:42 +0000 (18:47 +0100)]
xmlrpc: use <nil/> for null string values

- XML-RPC extension listed at https://en.wikipedia.org/wiki/XML-RPC#Data_types

(cherry picked from commit 17b9a6add82781f71b4d84da7c804e0e72c8b026)

13 months agotopos: one more update to enable processing ofr 100
Daniel-Constantin Mierla [Mon, 1 Mar 2021 17:16:00 +0000 (18:16 +0100)]
topos: one more update to enable processing ofr 100

(cherry picked from commit 620194165e0c6c27dfe9dbe382dc2e7b58be13b5)

13 months agotopos: handle 100 response completely
Daniel-Constantin Mierla [Mon, 1 Mar 2021 16:19:03 +0000 (17:19 +0100)]
topos: handle 100 response completely

- it may be needed by other modules to be processed with all via stack

(cherry picked from commit 80e812caf83a131c5f830b7d23de754136fd54f7)

13 months agoipops: proper handling of return code for ip to buf conversion
Daniel-Constantin Mierla [Mon, 29 Mar 2021 07:56:36 +0000 (09:56 +0200)]
ipops: proper handling of return code for ip to buf conversion

- reported in GH #2695

(cherry picked from commit 1d7d78c31eeab717c7013a00650d3cb07895bac8)

13 months agohttp_async_client: fix build with older versionss of libcurl
Victor Seva [Tue, 23 Mar 2021 10:30:18 +0000 (11:30 +0100)]
http_async_client: fix build with older versionss of libcurl

* CURLPIPE_NOTHING was introduced at libcurl 7.43.0

(cherry picked from commit d82d95a824d6f8a6c0246b78ac6642d4d6fed9e1)

13 months agohttp_async_client: disable HTTP/2 multiplexing
Federico Cabiddu [Sun, 21 Mar 2021 16:50:01 +0000 (17:50 +0100)]
http_async_client: disable HTTP/2 multiplexing

14 months agomangler: 0-ending value on deconding uri
Daniel-Constantin Mierla [Tue, 16 Mar 2021 08:37:58 +0000 (09:37 +0100)]
mangler: 0-ending value on deconding uri

(cherry picked from commit 3b038ed6761a5818441a7610a8305491aa358377)

14 months agosiputils: 0-ending value on deconding uri
Daniel-Constantin Mierla [Tue, 16 Mar 2021 08:37:14 +0000 (09:37 +0100)]
siputils: 0-ending value on deconding uri

(cherry picked from commit 735911fcced21eb5c66393045bc143bd953d08bb)

14 months agopv_headers: fix detection of split marker
Victor Seva [Wed, 10 Mar 2021 17:36:18 +0000 (18:36 +0100)]
pv_headers: fix detection of split marker

If we set Diversion in split_headers and we get a header like
> "RULTEST, normalaa" <sip:0046341355354340@whatever.net;user=phone>;reason=unconditional

There was false detection of two Diversion headers.

Skip split marker between double quotes to avoid this

(cherry picked from commit c05c7133a5657a547a5b0ced0b0a05707b44bc06)

14 months agoctl: info log messages made debug
Daniel-Constantin Mierla [Fri, 5 Mar 2021 06:32:47 +0000 (07:32 +0100)]
ctl: info log messages made debug

- used to troubleshoot infite loop on shut down phase
- GH #2661

(cherry picked from commit 38acfb59dde232b1a9f0ffc206fb46b320cd8e10)

14 months agoims_charging: renamed str_list_t to str_htlist_t
Daniel-Constantin Mierla [Wed, 3 Mar 2021 08:16:38 +0000 (09:16 +0100)]
ims_charging: renamed str_list_t to str_htlist_t

- fix conflict added by e1dc6dd6d9b206168f6da2929560ca6a64e1b41e

(cherry picked from commit 1f751775525fdcdb5a75b45fbf451e2bef3696ec)

14 months agocorex: process values for dns_cache params in mod init
Daniel-Constantin Mierla [Wed, 3 Mar 2021 07:48:01 +0000 (08:48 +0100)]
corex: process values for dns_cache params in mod init

- ensure the dns cache structure is properly initialized

(cherry picked from commit 5126964ebf28af3be1391e8ed2153503b118ff2c)

14 months agocore: typedef for str_list struct
Daniel-Constantin Mierla [Wed, 3 Mar 2021 07:47:20 +0000 (08:47 +0100)]
core: typedef for str_list struct

(cherry picked from commit e1dc6dd6d9b206168f6da2929560ca6a64e1b41e)

14 months agondb_redis: add result check when reconnecting
Victor Seva [Tue, 2 Mar 2021 14:16:02 +0000 (15:16 +0100)]
ndb_redis: add result check when reconnecting

Reported and provided solution by @kritarthh

follow-up #2461

(cherry picked from commit f82a2563000361b6b1b12b4bb72b9a8ee4c62292)

14 months agondb_redis: fix cluster support
Victor Seva [Mon, 21 Sep 2020 07:49:25 +0000 (09:49 +0200)]
ndb_redis: fix cluster support

fixes #2461 related #2300

(cherry picked from commit 5557b9b715a9ca754c454b5edaebf2a43b832015)

14 months agoims_qos: typos in comments
Daniel-Constantin Mierla [Wed, 24 Feb 2021 18:09:35 +0000 (19:09 +0100)]
ims_qos: typos in comments

(cherry picked from commit f9c336aa9a78169cf9c7f3fd9bfcfd22218078fb)

14 months agokamdbctl: typo in log message - core tables successfully installed
Piotr Gregor [Wed, 24 Feb 2021 07:20:14 +0000 (08:20 +0100)]
kamdbctl: typo in log message - core tables successfully installed

(cherry picked from commit 571fe52f4ad0cf5ceef98fb2d77c2711f3692c28)

14 months agoipops: use local ip struct for internal resolving
Daniel-Constantin Mierla [Tue, 23 Feb 2021 10:32:21 +0000 (11:32 +0100)]
ipops: use local ip struct for internal resolving

- static structure from core can be overwritten on subsequential use
- GH #2645

(cherry picked from commit 2ce244825bf7bc38f145699209ef7125ae5480d0)

14 months agojsonrpcs: use json null value for c null char* or str*
Daniel-Constantin Mierla [Mon, 22 Feb 2021 10:29:39 +0000 (11:29 +0100)]
jsonrpcs: use json null value for c null char* or str*

(cherry picked from commit c48e409b741821fa470788b3bca0ead32e4d6efc)

14 months agocore: early detect of empty host for check_self()
Daniel-Constantin Mierla [Wed, 17 Feb 2021 13:07:43 +0000 (14:07 +0100)]
core: early detect of empty host for check_self()

(cherry picked from commit 6863cb8b0253c641146633bd063575a53bc6a466)

14 months agorr: catch uri without host part when matching local addresses
Daniel-Constantin Mierla [Wed, 17 Feb 2021 11:15:55 +0000 (12:15 +0100)]
rr: catch uri without host part when matching local addresses

- can happen for tel or urn uri

(cherry picked from commit 81cd9c5d6934392cafd4b73541a19dbfa4b553f9)

14 months agokex: display proper values for pkg mem stats
Ovidiu Sas [Wed, 17 Feb 2021 17:08:10 +0000 (12:08 -0500)]
kex: display proper values for pkg mem stats
 - large amounts of pkg memory were displayed as negative numbers

(cherry picked from commit 220f9ca3c486b92797982a2333343fab463e9e5a)

15 months agoChangeLog: content updated for v5.4.4 5.4.4
Daniel-Constantin Mierla [Mon, 15 Feb 2021 10:58:01 +0000 (11:58 +0100)]
ChangeLog: content updated for v5.4.4

15 months agoMakefile.defs: version set to 5.4.4
Daniel-Constantin Mierla [Mon, 15 Feb 2021 10:28:16 +0000 (11:28 +0100)]
Makefile.defs: version set to 5.4.4

15 months agopkg/kamailio/obs: added --atexit=no into systemd unit file [skip ci]
Sergey Safarov [Mon, 15 Feb 2021 07:11:25 +0000 (10:11 +0300)]
pkg/kamailio/obs: added --atexit=no into systemd unit file [skip ci]

(cherry picked from commit 9a35a5b95e8144dbdb18003f40e49e5b497274f3)

15 months agopkg/kamailio/deb: version set 5.4.4
Victor Seva [Mon, 15 Feb 2021 08:32:05 +0000 (09:32 +0100)]
pkg/kamailio/deb: version set 5.4.4

15 months agopkg/kamailio/deb: restore python3 dependency of kamailio package
Victor Seva [Thu, 11 Feb 2021 12:26:49 +0000 (13:26 +0100)]
pkg/kamailio/deb: restore python3 dependency of kamailio package

(cherry picked from commit ab8e680e0dd3a8078d40b72c50d41db55d442240)

15 months agopkg/kamailio: version set to 5.4.4 for rpm specs and alpine
Daniel-Constantin Mierla [Mon, 15 Feb 2021 08:24:57 +0000 (09:24 +0100)]
pkg/kamailio: version set to 5.4.4 for rpm specs and alpine

15 months agopv: proper transfomation name in the log message
Daniel-Constantin Mierla [Sat, 13 Feb 2021 19:59:30 +0000 (20:59 +0100)]
pv: proper transfomation name in the log message

(cherry picked from commit b4d1def5d8a5ffaddbd87708d8dc99f0f5f8853c)

15 months agomodules: readme files regenerated - modules ... [skip ci]
Kamailio Dev [Fri, 12 Feb 2021 15:16:30 +0000 (16:16 +0100)]
modules: readme files regenerated - modules ... [skip ci]

15 months agorr: docs - more details for sockname_mode param
Daniel-Constantin Mierla [Fri, 12 Feb 2021 15:14:18 +0000 (16:14 +0100)]
rr: docs - more details for sockname_mode param

(cherry picked from commit 86a5f81b776eab3e2b9a3a5470094546b94253f7)

15 months agocore: define sockname attribute name
Daniel-Constantin Mierla [Fri, 12 Feb 2021 14:26:56 +0000 (15:26 +0100)]
core: define sockname attribute name

- used in the sockname r-r parameter

(cherry picked from commit 274d32651d7886b7f424239565a2714e2dd0991d)

15 months agorr: compare sockname parameter name with the attribute name
Daniel-Constantin Mierla [Fri, 12 Feb 2021 14:27:35 +0000 (15:27 +0100)]
rr: compare sockname parameter name with the attribute name

(cherry picked from commit 86e8bfdee87558fcee3e5b821b506b934c6b6790)

15 months agohtable: docs - not about use of event_route[htable:mod-init]
Daniel-Constantin Mierla [Thu, 11 Feb 2021 16:32:45 +0000 (17:32 +0100)]
htable: docs - not about use of event_route[htable:mod-init]

(cherry picked from commit e0dcb1617bedf13cc3fc76cf7f3b5cd516806bc8)

15 months agoImproved README.
Juha Heinanen [Thu, 11 Feb 2021 15:44:19 +0000 (17:44 +0200)]
Improved README.

(cherry picked from commit 857e9deb4c2455ee2ea0c05446da54f97e1f0a63)

15 months agoFixed typo.
Juha Heinanen [Thu, 11 Feb 2021 15:27:44 +0000 (17:27 +0200)]
Fixed typo.

(cherry picked from commit 2664a51c35a1e8b5adc4c7e6cedde60bc01f0b28)

15 months agorr: docs - added missing end tag for para introduced in previous commit
Daniel-Constantin Mierla [Thu, 11 Feb 2021 15:22:06 +0000 (16:22 +0100)]
rr: docs - added missing end tag for para introduced in previous commit

(cherry picked from commit f8e60bcba548b25657cc295f8a593adf371f9fda)

15 months agorr: docs - note about format of record_route_preset() parameters
Daniel-Constantin Mierla [Thu, 11 Feb 2021 15:06:12 +0000 (16:06 +0100)]
rr: docs - note about format of record_route_preset() parameters

(cherry picked from commit f318fab629c308250531046d453a8ac76f80ca42)

15 months agorr: use rr params with record_route_preset()
Daniel-Constantin Mierla [Thu, 11 Feb 2021 14:59:31 +0000 (15:59 +0100)]
rr: use rr params with record_route_preset()

- param buffer was checked, but not used

(cherry picked from commit 76b886da8ddf11a94a62850c19bad8c83bd113fc)

15 months agocore: cfg.lex - do not destroy action if pre-fixup fails
Daniel-Constantin Mierla [Thu, 11 Feb 2021 09:27:20 +0000 (10:27 +0100)]
core: cfg.lex - do not destroy action if pre-fixup fails

- params might be in inconsistent state, shutdown is triggered which
cleans the pkg anyhow
- GH #2630

(cherry picked from commit dddd530ed9fa7b6ca8b31ff299105a53c39c1a5e)

15 months agocore: initialize allocated _ksr_shutdown_phase pointer
Daniel-Constantin Mierla [Wed, 10 Feb 2021 16:01:36 +0000 (17:01 +0100)]
core: initialize allocated _ksr_shutdown_phase pointer

(cherry picked from commit f27c2e06d7467c4c33ff289175862ae7614a3018)

15 months agoctl: fail when requested to process rpc commands in shutdown phase
Daniel-Constantin Mierla [Wed, 10 Feb 2021 16:10:25 +0000 (17:10 +0100)]
ctl: fail when requested to process rpc commands in shutdown phase

(cherry picked from commit 2015cfdfd777085dad98a606fc41946af186db1b)

15 months agoctl: skip handling rpc commands if kamilio is in shutdown phase
Daniel-Constantin Mierla [Mon, 10 Aug 2020 14:23:11 +0000 (16:23 +0200)]
ctl: skip handling rpc commands if kamilio is in shutdown phase

- related to #2433

(cherry picked from commit 6d928b59a3dbd6eb291da3d3936be6e8f18588af)

15 months agocore: test if shm is initialized on early shutdown
Daniel-Constantin Mierla [Fri, 27 Nov 2020 06:49:27 +0000 (07:49 +0100)]
core: test if shm is initialized on early shutdown

(cherry picked from commit b7d42f248bef70a06d8ae23f4a7652fd3f0e4e61)

15 months agocore: proper test when initializing _ksr_shutdown_phase shm pointer
Daniel-Constantin Mierla [Tue, 11 Aug 2020 14:33:02 +0000 (16:33 +0200)]
core: proper test when initializing _ksr_shutdown_phase shm pointer

(cherry picked from commit 27b2ddf926240b1dd269eb1d96767d73edf9c6e6)

15 months agocore: keep a global flag in shm for shut down phase
Daniel-Constantin Mierla [Mon, 10 Aug 2020 14:15:04 +0000 (16:15 +0200)]
core: keep a global flag in shm for shut down phase

- set when destroy modules is starting
- useful to check from other processes if shut down started

(cherry picked from commit 6da946e4a3d6d6949dd6babe9cf3919edc0b4519)

15 months agotls: fixed small typo in log message
Daniel-Constantin Mierla [Wed, 10 Feb 2021 15:35:09 +0000 (16:35 +0100)]
tls: fixed small typo in log message

(cherry picked from commit 3c1a454a1ac4fe8e668f709d3e278bbce59c51d3)

15 months agocfg.lex: removed yynoreturn attribute for ksr_yy_fatal_error()
Daniel-Constantin Mierla [Wed, 10 Feb 2021 07:27:58 +0000 (08:27 +0100)]
cfg.lex: removed yynoreturn attribute for ksr_yy_fatal_error()

- it is defined only by newer flex version, resulting in compile
failure on older versions (e.g., centos 7)

(cherry picked from commit f230035d8275cbad8d7515f73ba242f77a7a16db)

15 months agocore: cfg.lex - removed __attribute__((unused))
Daniel-Constantin Mierla [Tue, 9 Feb 2021 20:16:52 +0000 (21:16 +0100)]
core: cfg.lex - removed __attribute__((unused))

- not supported on some distros
- workaround to avoid unused warning

(cherry picked from commit 20fdab545a5f5c3ef1b8d8c4c392acaf4f9e8aae)

15 months agocore: main - terminate using ksr_exit() instead of return
Daniel-Constantin Mierla [Tue, 9 Feb 2021 13:00:23 +0000 (14:00 +0100)]
core: main - terminate using ksr_exit() instead of return

(cherry picked from commit d8643cd2caf38aa1efaeff73783920fab1d9bf0d)

15 months agocore: cfg.lex - declare auto-generated yy_fatal_error() with unused attribute
Daniel-Constantin Mierla [Tue, 9 Feb 2021 12:27:34 +0000 (13:27 +0100)]
core: cfg.lex - declare auto-generated yy_fatal_error() with unused attribute

(cherry picked from commit 346d99d1f98178a71d482e5724135f65257427dd)

15 months agocore: cfg.lex - overwrite yy_fatal_error() to use ksr_exit() macro
Daniel-Constantin Mierla [Tue, 9 Feb 2021 11:57:57 +0000 (12:57 +0100)]
core: cfg.lex - overwrite yy_fatal_error() to use ksr_exit() macro

(cherry picked from commit 9f326234f40f2c02f4833647112c3a4f4912aa17)

15 months agocore: more use of ksr_exit() macro to follow --atexit param
Daniel-Constantin Mierla [Tue, 9 Feb 2021 09:50:03 +0000 (10:50 +0100)]
core: more use of ksr_exit() macro to follow --atexit param

(cherry picked from commit 4f6243e8e6e2012af35aae67da7b93af2127f02c)

15 months agokeepalive: check if the destinations list is initialized at runtime use
Daniel-Constantin Mierla [Fri, 5 Feb 2021 08:55:58 +0000 (09:55 +0100)]
keepalive: check if the destinations list is initialized at runtime use

- do not initialize, because is no longer seen in all processes,
initialization must be done in mod init

(cherry picked from commit b2b7ec826055fd67ecf5ffb052afa609e0aa9e5b)

15 months agodoc: update manpage for atexit option
Victor Seva [Wed, 3 Feb 2021 12:33:32 +0000 (13:33 +0100)]
doc: update manpage for atexit option

(cherry picked from commit 351efd29d332703e79104a106ade08c9d1df6e20)

15 months agocore: replaced --no-atexit with --atexit=val
Daniel-Constantin Mierla [Wed, 3 Feb 2021 11:49:29 +0000 (12:49 +0100)]
core: replaced --no-atexit with --atexit=val

- val can be y[es] or 1 to enable execution of atexit callbacks; n[o] or
0 to disable the execution of atexit callbacks
- default yes
- simplified ksr_exit() macro

(cherry picked from commit 9b1472275530ed4cc32a65cd247dc9997e8b964b)

15 months agodoc: update options at manpage
Victor Seva [Wed, 3 Feb 2021 08:41:12 +0000 (09:41 +0100)]
doc: update options at manpage

* put them in order too

(cherry picked from commit 377bb3bdfd20bedabbe0f92e53bdded44be267e9)

15 months agocore: use macro for exit variants based on --no-atexit
Daniel-Constantin Mierla [Wed, 3 Feb 2021 07:29:32 +0000 (08:29 +0100)]
core: use macro for exit variants based on --no-atexit

(cherry picked from commit 06aec5a81cb22d06ad3bf613a05951f91e7e21bc)

15 months agocore: take in consideration --no-atexit for daemonize()
Daniel-Constantin Mierla [Tue, 2 Feb 2021 20:36:57 +0000 (21:36 +0100)]
core: take in consideration --no-atexit for daemonize()

(cherry picked from commit 7ab2e85437482b4dba86937a29da025503450014)

15 months agocore: added --no-atexit cli parameter
Daniel-Constantin Mierla [Mon, 1 Feb 2021 22:39:40 +0000 (23:39 +0100)]
core: added --no-atexit cli parameter

- skip atexit callbacks execution from external libraries which may access
destroyed shm memory causing crash on shutdown

(cherry picked from commit 9f12d314268d1d2cd990cb3c5556f79343869e47)

15 months agomodules/siptrace: fix regression preventing variables to be used (#2588)
tsearle [Wed, 16 Dec 2020 20:47:11 +0000 (21:47 +0100)]
modules/siptrace: fix regression preventing variables to be used (#2588)

* modules/siptrace: fix regression preventing variables to be used

Commit fa7eb2a switched the 2 parameter version of sip_trace from
using the builtin fixup_spve_spve to the custom fixup method to
using the custom fixup_siptrace. As it is a custom fixup method,
the corresponding free method can not be auto-detected causing the
config parser to require the parameters to be a constant.  This
patch adds a free method, allowing variables to be once again passed
as the 2nd parameter of this method (as well as fixing a memory leak
for the 3rd parameter).

* change free for parameter 3

Co-authored-by: Torrey Searle <tsearle@voxbone.com>
(cherry picked from commit 7c98d547996637a7bf1c7025c93142f574fe3ac9)

15 months agoapp_python3: handle deprecated PyEval_InitThreads()
Daniel-Constantin Mierla [Thu, 11 Feb 2021 08:14:06 +0000 (09:14 +0100)]
app_python3: handle deprecated PyEval_InitThreads()

- https://docs.python.org/3/c-api/init.html#c.PyEval_InitThreads
- GH #2626

(cherry picked from commit ca37f9247ecb6754fbdbd210fc59158bf0f32def)

15 months agomodules: readme files regenerated - modules ... [skip ci]
Kamailio Dev [Tue, 9 Feb 2021 09:16:59 +0000 (10:16 +0100)]
modules: readme files regenerated - modules ... [skip ci]

15 months agohttp_client: http_client_request to include default clientcert, clientkey,...
Wolfgang Kampichler [Wed, 27 Jan 2021 18:53:24 +0000 (19:53 +0100)]
http_client: http_client_request to include default clientcert, clientkey,...

- the lost module uses http_client API functions and in the course of NG112
  client certificates are used for authentication when querying LIS or ECRF,
  the fix allows these to be read out via http_client module parameters.

(cherry picked from commit 7d5868ab1242eb8166e6af1bb8a21b39001df663)

15 months agosiptrace: docs - fixed small typo
Daniel-Constantin Mierla [Sat, 6 Feb 2021 15:06:47 +0000 (16:06 +0100)]
siptrace: docs - fixed small typo

(cherry picked from commit 7d846f928b75a3bc1b8e8c1a70e39bfede939c15)

15 months agortpengine : add node fallback if node out of port
dvillaume [Wed, 3 Feb 2021 09:19:46 +0000 (10:19 +0100)]
rtpengine : add node fallback if node out of port

When rtpengine answers with error-reason 'Ran out of ports' adopt the same behavor that when node answers 'Parallel session limit reached'

(cherry picked from commit 853068a26c34deff86e17b63f49abea2c8f4403c)

15 months agokamctl: added srv debug subcommand
Daniel-Constantin Mierla [Thu, 4 Feb 2021 13:01:52 +0000 (14:01 +0100)]
kamctl: added srv debug subcommand

- control server debug level via rpc

(cherry picked from commit 6b5aa70f09e294338a65a0bf2fcae8b92fdc6fae)

15 months agoxhttp: do not call memset on a null-pointer, related to GH #2619
Henning Westerholt [Tue, 2 Feb 2021 18:42:35 +0000 (18:42 +0000)]
xhttp: do not call memset on a null-pointer, related to GH #2619

(cherry picked from commit 2db8884945844e5040dfed2b24fe84de097c0b2b)

15 months agotm: prper timer cleanup of responses for rpc tm.t_uac_wait_block
Daniel-Constantin Mierla [Wed, 27 Jan 2021 13:10:34 +0000 (14:10 +0100)]
tm: prper timer cleanup of responses for rpc tm.t_uac_wait_block

(cherry picked from commit 5a6a679985fecfc168b9b26f0be3c0e64e641e64)

15 months agocore: ut.h - add inline to static function to avoid warning from including files
Daniel-Constantin Mierla [Tue, 26 Jan 2021 10:52:36 +0000 (11:52 +0100)]
core: ut.h - add inline to static function to avoid warning from including files

- for shm_str_dup_block()

(cherry picked from commit 34301ea16812eccbb914ea14cafb0140ac9bba61)

15 months agodispatcher: Log dest sets after variable update
Marat Gareev [Mon, 25 Jan 2021 15:40:47 +0000 (18:40 +0300)]
dispatcher: Log dest sets after variable update

(cherry picked from commit f4b8bede6a247415eda84a7db9569747905f9fa0)

15 months agotm: docs for reply_relay_mode parameter
Daniel-Constantin Mierla [Mon, 25 Jan 2021 11:42:36 +0000 (12:42 +0100)]
tm: docs for reply_relay_mode parameter

(cherry picked from commit 00b1aba770c26f75c31cf2a28e7ca425f18788dc)

15 months agotm: new parameter reply_relay_mode
Daniel-Constantin Mierla [Mon, 25 Jan 2021 11:34:33 +0000 (12:34 +0100)]
tm: new parameter reply_relay_mode

- control the behaviour introduced by 18410da0
- if set to 0, the behaviour is like before the commit referenced above,
tm is attemptime to send suspended 200ok after another final response
that was forwarded while 200ok was suspended
- default is 1 (behave as the patch changed the forwarding policy, not
to overwrite the response buffer)

(cherry picked from commit 90dfc421dab438a8ef62cc8f68b2c1f7fb50b0dc)

15 months agotm: 200 OK not processed correctly by Proxy after final non-2xx
Theo [Fri, 17 Apr 2020 08:53:00 +0000 (08:53 +0000)]
tm: 200 OK not processed correctly by Proxy after final non-2xx

Description:
   Problem:
      Forwarding of 200 OK while sent 488 waits for ACK, destroys the UAS send buffer
   Scenario:
      During suspension of 200 OK by ims_qos module function Rx_AAR() at terminating PCSCF,
      The PCRF sends an AA Answer with result code DIAMETER_TOO_BUSY (3004), which triggers
      the PCSCF to send a 488 ‘Sorry no QoS available’ to the originating side (ims_dialog
      module function dlg_terminate()).
      Afterwards neither the 200 OK nor the ACK(488) is processed correctly by the PCSCF.
   Solution:
      The UAS send buffer should not be overwritten during processing of 200 OK,
      because non-2xx is needed to associate the ACK message in a correct way.
      200 OK must be forwarded statelessly.
   Side-Effect (potentially breaks existing function):
      Some callbacks cannot be called for the 200 OK, to avoid messing the stored 488.
(cherry picked from commit 18410da04c7f7bbc9628820427fedb92cf893526)

15 months agocore: fix to xavp_rm_internal (#2604)
Nicolas C [Fri, 22 Jan 2021 14:16:56 +0000 (15:16 +0100)]
core: fix to xavp_rm_internal (#2604)

This fixes the following issue:
https://github.com/kamailio/kamailio/issues/2604

Description of the issue:

When called to remove a specific index from a given xavp, function xavp_rm_by_index removes the index (as expected) but also all others before it.

E.g :
If called with idx = 1, it removes indexes 0 and 1.
Likewise if invoked with idx = 2 => the first 3 elements are removed.

This bug is located in function xavp_rm_internal. An assignment was missing when looping over the xavp list.
Same for xavi_rm_internal.

(cherry picked from commit 12414972ad0c28ac50ece3c14f98134c3f06c522)

15 months agokamctl: removed condition on CTLENGINETYPE
Daniel-Constantin Mierla [Thu, 21 Jan 2021 13:05:50 +0000 (14:05 +0100)]
kamctl: removed condition on CTLENGINETYPE

- done again inside ctl_cmd_run

(cherry picked from commit 4a4f0475716cbf824b2ab9684457e21f6732aa74)

15 months agokamctl: use param evaluation mode for cisco restart command
Daniel-Constantin Mierla [Thu, 21 Jan 2021 09:00:46 +0000 (10:00 +0100)]
kamctl: use param evaluation mode for cisco restart command

(cherry picked from commit 359050f9be40002aec1d3894dc43a2a8762ce8cc)

15 months agokamctl: use tm.t_uac_wait_block rpc for ping command
Daniel-Constantin Mierla [Wed, 20 Jan 2021 07:54:49 +0000 (08:54 +0100)]
kamctl: use tm.t_uac_wait_block rpc for ping command

(cherry picked from commit 47a98532af5512a4597bbf9ad3834c62dd633256)

15 months agotm: docs for rpc t_uac_wait_block
Daniel-Constantin Mierla [Wed, 20 Jan 2021 07:54:21 +0000 (08:54 +0100)]
tm: docs for rpc t_uac_wait_block

(cherry picked from commit 89eea7edb8832124dc325d8303b23ea5f36c88f4)

15 months agotm: implemented t_uac_wait_block rpc command
Daniel-Constantin Mierla [Wed, 20 Jan 2021 07:11:45 +0000 (08:11 +0100)]
tm: implemented t_uac_wait_block rpc command

- it blocks while waiting for the reply to return the code and reason
text

(cherry picked from commit dc5a548a9e6327674615aa7ddc8708e0ba5252aa)

15 months agocore: utils - functions to shm-duplicate str in a block
Daniel-Constantin Mierla [Tue, 19 Jan 2021 20:00:54 +0000 (21:00 +0100)]
core: utils - functions to shm-duplicate str in a block

(cherry picked from commit 6684b57641396ba494716e7f63a0f15afc1d8637)

15 months agokamctl: use tm.t_uac_wait for ping command
Daniel-Constantin Mierla [Tue, 19 Jan 2021 06:49:24 +0000 (07:49 +0100)]
kamctl: use tm.t_uac_wait for ping command

(cherry picked from commit 20d075a17189961baf63ac000e4417d7f04d8a08)

15 months agokamctl: option for rpc command to replace tokens in parameters
Daniel-Constantin Mierla [Mon, 18 Jan 2021 09:19:05 +0000 (10:19 +0100)]
kamctl: option for rpc command to replace tokens in parameters

- supported now: replace '=CRLF=' with '\r\n'
- fix 'kamctl ping' command by replacing '=CRLF=' with '\r\n'
in multi-headers parameter

(cherry picked from commit 1c66f6a1a5d04c33f1912609a36729b06b6eebd7)