@linuxmaniac - closing this one, 2e7710e should fix it. Once you test and it is ok, then you can backport as needed. If still an issues, then reopen.
--
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/2479#issuecomment-701344668
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [x] Small bug fix (non-breaking change which fixes an issue)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [x] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
Based on the email thread :
```
[SR-Users] Dialog - timeout for dlg with CallIDInbox
```
Several users are facing unpexected dialog disconnection caused by no-ack timer.
Using a modified version of the dialog module to improve debug-ability
ttps://github.com/kamailio/kamailio/pull/2483
I was able to confirm at least one problem and after looking at the trace, it seems like dialog mismatch with a serial forking scenario :
- log line 3 is telling us that a NO-ACK disconnection should be triggered
- log line 1-2 is telling us what happened when the ACK was received in dlg_onroute(), oddly enough state 5 was old and new, could it be a mismatch/confusio with the previous dialog, looking in this direction ...
```
1: 2020-09-25T16:30:16.896: dialog [dlg_handlers.c:1273]: extra_ack_debug_info(): [ACK][1] state not changed >>> call-id[562419_125824138_2072238224] to-tag[<sip:+14019991904@anon.com>;tag=gK02b68836]
2: 2020-09-25T16:30:16.896: dialog [dlg_handlers.c:1440]: dlg_onroute(): [ACK] state not changed old[5]new[5]
...
3: 2020-09-25T16:32:22.674: dialog [dlg_hash.c:247]: dlg_clean_run(): dialog disconnection no-ACK call-id[562419_125824138_2072238224][1601051416]<[1601051542 - 60]
```
After looking at the pcap trace, call-id 562419_125824138_2072238224 was involved in serial forking :
call attempt1
```
X >> INVITE >> Y // no to-tag
X << 100
...
X << 408 // to-tag=594d50c3218065a60bb91fd47a70fbc1-59edef02 (locally generated)
X >> ACK // to-tag=594d50c3218065a60bb91fd47a70fbc1-59edef02
```
call attempt2
```
X >> INVITE >> Z // no to-tag
X << 100
X << 200 << Z // to-tag=gK02b68836
X >> ACK >> Z // to-tag=gK02b68836 (Should be state old[3]new[4], I wonder how it could possibly be state old[5]new[5])
```
I did look at several occurrences and there is always a locally generated 408/to-tag before, seems like I have a good lead to investigate further.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2484
-- Commit Summary --
* dialog: dlg_cell, always check for a to-tag match
-- File Changes --
M src/modules/dialog/dlg_hash.c (13)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2484.patchhttps://github.com/kamailio/kamailio/pull/2484.diff
--
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/pull/2484
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [ ] Commit message has the format required by CONTRIBUTING guide
- [ ] Commits are split per component (core, individual modules, libs, utils, ...)
- [ ] Each component has a single commit (if not, squash them into one commit)
- [ ] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [ ] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
<!-- Describe your changes in detail -->
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2483
-- Commit Summary --
* dialog: no-ack-extra-debug
-- File Changes --
M src/modules/dialog/dlg_handlers.c (48)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2483.patchhttps://github.com/kamailio/kamailio/pull/2483.diff
--
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/pull/2483
training of the latency estimator
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [x] Small bug fix (non-breaking change which fixes an issue)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [x] Tested changes locally
#### Description
<!-- Describe your changes in detail -->
minor issue with the estimator initialization / training
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2485
-- Commit Summary --
* dispatcher: fix an error in initially
-- File Changes --
M src/modules/dispatcher/dispatch.c (8)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2485.patchhttps://github.com/kamailio/kamailio/pull/2485.diff
--
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/pull/2485
i'm use it on freeswitch public ip 47.xx.xx.xx and private ip 172.31.239.38
i'm test it http://kb.asipto.com/freeswitch:kamailio-3.3.x-freeswitch-1.2.x-sbc (freeswitch.bindip= 47.xx.xx.xx )
and 101 to 100 and return 488
There seems to be no problem using it on the intranet
and log:
8(21255) NOTICE: {2 26129640 INVITE b1b6df17-7ccd-1239-9990-00163e05779b} acc [acc.c:279]: acc_log_request(): ACC: call missed: timestamp=1601366864;method=INVITE;from_tag=t7jr1405ee9gp;to_tag=dGSi5k2;call_id=b1b6df17-7ccd-1239-9990-00163e05779b;code=488;reason=Not acceptable here;src_user=101;src_domain=172.31.239.38;src_ip=47.xxx.xx.xx;dst_ouser=100;dst_user=100;dst_domain=220.207.94.221
fs log:
to 100 ask return INCOMPATIBLE_DESTINATION error
Do you need to modify anything in the public network?
I can't find any information. Please help me? thinks
--
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/2487
<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for bug reports.
If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
If there is no content to be filled in a section, the entire section can be removed.
You can delete the comments from the template sections when filling.
You can delete next line and everything above before submitting (it is a comment).
-->
### Description
<!--
Explain what you did, what you expected to happen, and what actually happened.
-->
I am using keepalive module to send keepalives to all the destinations registered with an application server which sits behind kamailio.
When Kamailio recieves 200 Ok. I take URI contact from 200 OK and pass it as a param to ka_add_destination function.Most of the time it works fine but sometimes kamailio crashes when it recieves 200 OK of OPTIONS.
### Troubleshooting
#### Reproduction
I am able to reproduce it easily in below scenario :
All the URIs which we are feeding to KA module has this syntax :
sip:2003@10.50.8.11:9090;alias=10.50.8.1~5060~1;pb-ip=35.185.177.49;pb-pt=5060;tp=udp
1. So request will be generate by KA module and it will be send to 10.50.8.11:9090 ( which is another port of same kamailio instance ) via UDP protocol.
2. On recieving OPTION on 9090 port ,
- We are calling handle_ruri_alias() function which will set $du =sip:10.50.8.1:5060;transport=udp
- Modify RURI from sip:2003@10.50.8.11:9090;alias=10.50.8.1~5060~1;pb-ip=35.185.177.49;pb-pt=5060;tp=udp to
sip:2003@**35.185.177.49:5060**;pb-ip=35.185.177.49;pb-pt=5060;**transport**=udp
- and relay to 10.50.8.1
3. 10.50.8.1 is another instance of Kamailio which will relay OPTION packet to final destination
<!--
If the issue can be reproduced, describe how it can be done.
-->
#### Debugging Data
<!--
If you got a core dump, use gdb to extract troubleshooting data - full backtrace,
local variables and the list of the code at the issue location.
gdb /path/to/kamailio /path/to/corefile
bt full
info locals
list
If you are familiar with gdb, feel free to attach more of what you consider to
be relevant.
-->
```
[root@SBC-4-2 /]# gdb kamailio core.67771
GNU gdb (GDB) Red Hat Enterprise Linux 7.6.1-110.el7
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/local/sbin/kamailio...done.
[New LWP 67771]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
Core was generated by `/usr/local/sbin/kamailio -m 5000 -M 500 -P /run/kamailio/kamailio.pid'.
Program terminated with signal 11, Segmentation fault.
#0 0x00000000abcdefed in ?? ()
Missing separate debuginfos, use: debuginfo-install cyrus-sasl-lib-2.1.26-23.el7.x86_64 glibc-2.17-222.el7.x86_64 keyutils-libs-1.5.8-3.el7.x86_64 krb5-libs-1.15.1-19.el7.x86_64 libcom_err-1.42.9-12.el7_5.x86_64 libcurl-7.29.0-51.el7.x86_64 libevent-2.0.21-4.el7.x86_64 libgcc-4.8.5-36.el7_6.2.x86_64 libidn-1.28-4.el7.x86_64 libselinux-2.5-12.el7.x86_64 libssh2-1.4.3-10.el7_2.1.x86_64 libstdc++-4.8.5-36.el7_6.2.x86_64 libuuid-2.23.2-52.el7_5.1.x86_64 mariadb-libs-5.5.64-1.el7.x86_64 nspr-4.19.0-1.el7_5.x86_64 nss-3.36.0-5.el7_5.x86_64 nss-softokn-freebl-3.36.0-5.el7_5.x86_64 nss-util-3.36.0-1.el7_5.x86_64 openldap-2.4.44-15.el7_5.x86_64 openssl-libs-1.0.2k-16.el7_6.1.x86_64 pcre-8.32-17.el7.x86_64 zlib-1.2.7-18.el7.x86_64
(gdb) bt full
#0 0x00000000abcdefed in ?? ()
No symbol table info available.
#1 0x00007f931dc69c7e in ka_options_callback (t=0x7f91e58f05c0, type=1024, ps=0x7ffda0977bd0) at keepalive_core.c:126
uri = {
s = 0x7f91e58f63f0 "sip:2003@10.50.8.11:9090;alias=10.50.8.1~5060~1;pb-ip=35.185.177.49;pb-pt=5060;tp=udp>\r\nFrom: <sip:keepalive@fromsbc>;tag=c7bfd876be500fff196414658218fc27-d6989f6d\r\nCSeq: 10 OPTIONS\r\nCall-ID: 3f2c3c7c"..., len = 85}
msg = 0x0
state = 2
state_routes = {0x7f931dc6f844 "", 0x7f931dc6f93d "keepalive:dst-up", 0x7f931dc6f94e "keepalive:dst-down"}
ka_dest = 0x7f91e5898988
__FUNCTION__ = "ka_options_callback"
#2 0x00007f9324bfddd8 in run_trans_callbacks_internal (cb_lst=0x7f91e58f0638, type=1024, trans=0x7f91e58f05c0, params=0x7ffda0977bd0)
at t_hooks.c:258
cbp = 0x7f91e58f6590
backup_from = 0xb2a750 <def_list+16>
backup_to = 0xb2a758 <def_list+24>
backup_dom_from = 0xb2a760 <def_list+32>
backup_dom_to = 0xb2a768 <def_list+40>
backup_uri_from = 0xb2a740 <def_list>
backup_uri_to = 0xb2a748 <def_list+8>
backup_xavps = 0xb29fd0 <_xavp_list_head>
backup_xavus = 0xb29fd8 <_xavu_list_head>
backup_xavis = 0xb29fe0 <_xavi_list_head>
__FUNCTION__ = "run_trans_callbacks_internal"
#3 0x00007f9324bfdf0a in run_trans_callbacks (type=1024, trans=0x7f91e58f05c0, req=0x0, rpl=0xffffffffffffffff, code=408) at t_hooks.c:285
params = {req = 0x0, rpl = 0xffffffffffffffff, param = 0x7f91e58f65a0, code = 408, flags = 0, branch = 0, t_rbuf = 0x0, dst = 0x0,
send_buf = {s = 0x0, len = 0}}
#4 0x00007f9324b943f1 in local_reply (t=0x7f91e58f05c0, p_msg=0xffffffffffffffff, branch=0, msg_status=408, cancel_data=0x7ffda0977d50)
at t_reply.c:2265
local_store = 0
local_winner = 0
reply_status = RPS_COMPLETED
winning_msg = 0xffffffffffffffff
winning_code = 408
totag_retr = 0
---Type <return> to continue, or q <return> to quit---
__FUNCTION__ = "local_reply"
#5 0x00007f9324bcc9fd in fake_reply (t=0x7f91e58f05c0, branch=0, code=408) at timer.c:290
cancel_data = {cancel_bitmap = 0, reason = {cause = 0, u = {text = {s = 0x0, len = -443611712}, e2e_cancel = 0x0, packed_hdrs = {s = 0x0,
len = -443611712}}}}
do_cancel_branch = 0
reply_status = 67771
#6 0x00007f9324bcce95 in final_response_handler (r_buf=0x7f91e58f0860, t=0x7f91e58f05c0) at timer.c:462
silent = 0
branch_ret = 0
prev_branch = 0
now = 0
#7 0x00007f9324bccf56 in retr_buf_handler (ticks=112894435, tl=0x7f91e58f0880, p=0xfa0) at timer.c:518
rbuf = 0x7f91e58f0860
fr_remainder = 1
retr_remainder = 32657
retr_interval = 3847088576
new_retr_interval_ms = 6989250208
crt_retr_interval_ms = 140264594074048
t = 0x7f91e58f05c0
__FUNCTION__ = "retr_buf_handler"
#8 0x00000000004b7bcd in slow_timer_main () at core/timer.c:1105
n = 12
ret = 4294967295
tl = 0x7f91e58f0880
i = 700
__FUNCTION__ = "slow_timer_main"
#9 0x000000000042a4c3 in main_loop () at main.c:1737
i = 16
pid = 0
si = 0x0
si_desc = "udp receiver child=15 sock=10.50.8.11:9090\000:0:0:11]:5060\000\061:5060)\000\000\000\000\000\000\000\000\000\000F\345\221\177\000\000\000\000\000\000\000\000\000\000\bLv\345\221\177\000\000P\201\227\240\375\177\000\000\210\212K\000\000\000\000\000\260\270A\000\000\000\000\000\b{\017(\223\177\000"
nrprocs = 16
woneinit = 1
---Type <return> to continue, or q <return> to quit---
__FUNCTION__ = "main_loop"
#10 0x0000000000433a66 in main (argc=7, argv=0x7ffda09786b8) at main.c:2856
cfg_stream = 0x27e7010
c = -1
r = 0
tmp = 0x7ffda0979f26 ""
tmp_len = 0
port = 0
proto = 0
ahost = 0x0
aport = 0
options = 0x7d2498 ":f:cm:M:dVIhEeb:l:L:n:vKrRDTN:W:w:t:u:g:P:G:SQ:O:a:A:x:X:Y:"
ret = -1
seed = 791137056
rfd = 4
debug_save = 0
debug_flag = 0
dont_fork_cnt = 0
n_lst = 0x7f934718ea00 <intel_02_known>
p = 0x0
st = {st_dev = 23, st_ino = 30676, st_nlink = 2, st_mode = 16877, st_uid = 0, st_gid = 5001, __pad0 = 0, st_rdev = 0, st_size = 40,
st_blksize = 4096, st_blocks = 0, st_atim = {tv_sec = 1597841333, tv_nsec = 176009291}, st_mtim = {tv_sec = 1597841333,
tv_nsec = 166009247}, st_ctim = {tv_sec = 1597841333, tv_nsec = 176009291}, __unused = {0, 0, 0}}
tbuf = "\377\377\377\377", '\000' <repeats 12 times>, "\340\263\001G\223\177\000\000\310T\320G\223\177", '\000' <repeats 90 times>, "p\342\252\000\000\000\000\000\260\270A\000\000\000\000\000\260\206\227\240\375\177", '\000' <repeats 26 times>, "\036_\260G\223\177\000\000\001", '\000' <repeats 23 times>...
option_index = 0
long_options = {{name = 0x7d468f "help", has_arg = 0, flag = 0x0, val = 104}, {name = 0x7cfc94 "version", has_arg = 0, flag = 0x0,
val = 118}, {name = 0x7d4694 "alias", has_arg = 1, flag = 0x0, val = 1024}, {name = 0x7d469a "subst", has_arg = 1, flag = 0x0,
val = 1025}, {name = 0x7d46a0 "substdef", has_arg = 1, flag = 0x0, val = 1026}, {name = 0x7d46a9 "substdefs", has_arg = 1, flag = 0x0,
val = 1027}, {name = 0x7d46b3 "server-id", has_arg = 1, flag = 0x0, val = 1028}, {name = 0x7d46bd "loadmodule", has_arg = 1, flag = 0x0,
val = 1029}, {name = 0x7d46c8 "modparam", has_arg = 1, flag = 0x0, val = 1030}, {name = 0x7d46d1 "log-engine", has_arg = 1, flag = 0x0,
val = 1031}, {name = 0x7d46dc "debug", has_arg = 1, flag = 0x0, val = 1032}, {name = 0x0, has_arg = 0, flag = 0x0, val = 0}}
__FUNCTION__ = "main"
(gdb)
```
#### Log Messages
<!--
Check the syslog file and if there are relevant log messages printed by Kamailio, add them next, or attach to issue, or provide a link to download them (e.g., to a pastebin site).
-->
```
Aug 19 12:58:26 SBC-4-2 /usr/local/sbin/kamailio[67772]: CRITICAL: <core> [core/mem/q_malloc.c:138]: qm_debug_check_frag(): BUG: qm: fragm. 0x7f91e5898950 (address 0x7f91e5898988) end overwritten (c0c0c0c1, abcdefed)! Memory allocator was called from core: core/usr_avp.c:626. Fragment marked by core: core/usr_avp.c:175. Exec from core/mem/q_malloc.c:511.
Aug 19 12:58:38 SBC-4-2 /usr/local/sbin/kamailio[67793]: CRITICAL: <core> [core/pass_fd.c:277]: receive_fd(): EOF on 94
```
#### SIP Traffic
<!--
If the issue is exposed by processing specific SIP messages, grab them with ngrep or save in a pcap file, then add them next, or attach to issue, or provide a link to download them (e.g., to a pastebin site).
-->
```
(paste your sip traffic here)
```
### Possible Solutions
<!--
If you found a solution or workaround for the issue, describe it. Ideally, provide a pull request with a fix.
-->
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
[root@SBC-4-2 /]# kamailio -v
version: kamailio 5.4.0 (x86_64/linux) 6c4fce
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 6c4fce
compiled on 14:16:47 Aug 14 2020 with gcc 4.8.5
```
* **Operating System**:
<!--
Details about the operating system, the type: Linux (e.g.,: Debian 8.4, Ubuntu 16.04, CentOS 7.1, ...), MacOS, xBSD, Solaris, ...;
Kernel details (output of `uname -a`)
-->
```
[root@SBC-4-2 /]# uname -a
Linux SBC-4-2.netcarrier.net 5.1.0 #1 SMP Mon May 6 13:44:38 GMT 2019 x86_64 x86_64 x86_64 GNU/Linux
```
--
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/2448
Module: kamailio
Branch: 5.4
Commit: 463498565029aced931b44fd686f5c9d15b49341
URL: https://github.com/kamailio/kamailio/commit/463498565029aced931b44fd686f5c9…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2020-09-23T09:03:52+02:00
ndb_redis: set message level to debug on exec
* logging error makes no sense here since there's going
to be a reconnection afterwards
> ERROR: ndb_redis [redis_client.c:903]: redisc_exec_argv(): Redis error: Server closed the connection
(cherry picked from commit a9c331d70dbed6827874aa99296203ac5a9d5c7b)
---
Modified: src/modules/ndb_redis/redis_client.c
---
Diff: https://github.com/kamailio/kamailio/commit/463498565029aced931b44fd686f5c9…
Patch: https://github.com/kamailio/kamailio/commit/463498565029aced931b44fd686f5c9…
---
diff --git a/src/modules/ndb_redis/redis_client.c b/src/modules/ndb_redis/redis_client.c
index 5ad063f89a..bd97012c8e 100644
--- a/src/modules/ndb_redis/redis_client.c
+++ b/src/modules/ndb_redis/redis_client.c
@@ -770,7 +770,7 @@ int redisc_exec_pipelined(redisc_server_t *rsrv)
/* null reply, reconnect and try again */
if (rsrv->ctxRedis->err)
{
- LM_ERR("Redis error: %s\n", rsrv->ctxRedis->errstr);
+ LM_DBG("Redis error: %s\n", rsrv->ctxRedis->errstr);
}
if (redisc_create_pipelined_message(rsrv) == 0)
{
Module: kamailio
Branch: master
Commit: a9c331d70dbed6827874aa99296203ac5a9d5c7b
URL: https://github.com/kamailio/kamailio/commit/a9c331d70dbed6827874aa99296203a…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2020-09-23T09:02:43+02:00
ndb_redis: set message level to debug on exec
* logging error makes no sense here since there's going
to be a reconnection afterwards
> ERROR: ndb_redis [redis_client.c:903]: redisc_exec_argv(): Redis error: Server closed the connection
---
Modified: src/modules/ndb_redis/redis_client.c
---
Diff: https://github.com/kamailio/kamailio/commit/a9c331d70dbed6827874aa99296203a…
Patch: https://github.com/kamailio/kamailio/commit/a9c331d70dbed6827874aa99296203a…
---
diff --git a/src/modules/ndb_redis/redis_client.c b/src/modules/ndb_redis/redis_client.c
index 5bc1bf0e47..15a86f7b10 100644
--- a/src/modules/ndb_redis/redis_client.c
+++ b/src/modules/ndb_redis/redis_client.c
@@ -770,7 +770,7 @@ int redisc_exec_pipelined(redisc_server_t *rsrv)
/* null reply, reconnect and try again */
if (rsrv->ctxRedis->err)
{
- LM_ERR("Redis error: %s\n", rsrv->ctxRedis->errstr);
+ LM_DBG("Redis error: %s\n", rsrv->ctxRedis->errstr);
}
if (redisc_create_pipelined_message(rsrv) == 0)
{
<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for bug reports.
If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
If there is no content to be filled in a section, the entire section can be removed.
You can delete the comments from the template sections when filling.
You can delete next line and everything above before submitting (it is a comment).
-->
### Description
<!--
Explain what you did, what you expected to happen, and what actually happened.
-->
When issuing `#members` command via IMC, the following error occurs, though the member list is returned to the client:
```
ERROR: imc [imc_cmd.c:1007]: imc_handle_members(): Message-ID: '185434_mobile-rel120YmVmYzE0ZjMwNzgyYWIxOWVjYWZhNmM1MzY5ZjY1YzU'
ERROR: imc [imc_cmd.c:1012]: imc_handle_members(): Buffer too small for member list message
```
When issuing `#rooms` command via IMC, the following error occurs, though the room list is returned to the client:
```
ERROR: imc [imc_cmd.c:1070]: imc_handle_rooms(): Buffer too small for member list message
```
In case it's relevant, the clients are using TLS connections.
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.4.1-2.git99b2a0c066.fc32 (x86_64/linux) 09fd6a
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 09fd6a
compiled on 00:00:00 Sep 12 2020 with gcc 10.2.1
```
* **Operating System**:
<!--
Details about the operating system, the type: Linux (e.g.,: Debian 8.4, Ubuntu 16.04, CentOS 7.1, ...), MacOS, xBSD, Solaris, ...;
Kernel details (output of `uname -a`)
-->
```
Fedora 32 x86_64
Linux 5.8.9-200.fc32.x86_64 #1 SMP Mon Sep 14 18:28:45 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
```
--
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/2481
Module: kamailio
Branch: 5.4
Commit: 609685c91d92337a1d0832d709ebff437fb193ef
URL: https://github.com/kamailio/kamailio/commit/609685c91d92337a1d0832d709ebff4…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-22T19:46:21+02:00
modules: readme files regenerated - modules ... [skip ci]
---
Modified: src/modules/usrloc/README
---
Diff: https://github.com/kamailio/kamailio/commit/609685c91d92337a1d0832d709ebff4…
Patch: https://github.com/kamailio/kamailio/commit/609685c91d92337a1d0832d709ebff4…
---
diff --git a/src/modules/usrloc/README b/src/modules/usrloc/README
index ac3a6b7bb6..d075042834 100644
--- a/src/modules/usrloc/README
+++ b/src/modules/usrloc/README
@@ -94,8 +94,9 @@ Carsten Bock
3.52. ka_from (str)
3.53. ka_domain (str)
3.54. ka_filter (int)
- 3.55. ka_loglevel (int)
- 3.56. ka_logmsg (str)
+ 3.55. ka_timeout (int)
+ 3.56. ka_loglevel (int)
+ 3.57. ka_logmsg (str)
4. RPC Commands
@@ -197,8 +198,9 @@ Carsten Bock
1.52. ka_from parameter usage
1.53. ka_domain parameter usage
1.54. ka_filter parameter usage
- 1.55. ka_loglevel parameter usage
- 1.56. ka_logmsg parameter usage
+ 1.55. Set ka_timeout parameter
+ 1.56. ka_loglevel parameter usage
+ 1.57. ka_logmsg parameter usage
Chapter 1. Admin Guide
@@ -269,8 +271,9 @@ Chapter 1. Admin Guide
3.52. ka_from (str)
3.53. ka_domain (str)
3.54. ka_filter (int)
- 3.55. ka_loglevel (int)
- 3.56. ka_logmsg (str)
+ 3.55. ka_timeout (int)
+ 3.56. ka_loglevel (int)
+ 3.57. ka_logmsg (str)
4. RPC Commands
@@ -404,8 +407,9 @@ Chapter 1. Admin Guide
3.52. ka_from (str)
3.53. ka_domain (str)
3.54. ka_filter (int)
- 3.55. ka_loglevel (int)
- 3.56. ka_logmsg (str)
+ 3.55. ka_timeout (int)
+ 3.56. ka_loglevel (int)
+ 3.57. ka_logmsg (str)
3.1. nat_bflag (int)
@@ -683,8 +687,8 @@ modparam("usrloc", "desc_time_order", 1)
3.25. timer_interval (int)
Number of seconds between two timer runs. The module uses a timer to
- delete expired contacts, synchronize with database and other tasks,
- that need to be run periodically.
+ delete expired contacts, synchronize with database, send keepalives and
+ other tasks, that need to be run periodically.
Default value is 60.
@@ -1163,19 +1167,38 @@ modparam("usrloc", "ka_domain", "mydomain.com")
modparam("usrloc", "ka_filter", 1)
...
-3.55. ka_loglevel (int)
+3.55. ka_timeout (int)
+
+ The parameter sets the interval in seconds after which a contact is
+ removed from location table if it does not reply to SIP keepalives
+ (usually OPTIONS ping requests).
+
+ The features is available only for contacts that are stored in memory
+ (not working for db only mode of the usrloc module).
+
+ Keepalives are sent stateless, not using TM module. The value of this
+ parameter has to be few times higher than timer interval.
+
+ Default value is “0” (feature disabled).
+
+ Example 1.55. Set ka_timeout parameter
+...
+modparam("usrloc", "ka_timeout", 120)
+...
+
+3.56. ka_loglevel (int)
The level to print the log message when the keepalive response is
received. It should be a value between -5 (L_ALERT) and 3 (L_DBG).
Default value is “255” (disabled).
- Example 1.55. ka_loglevel parameter usage
+ Example 1.56. ka_loglevel parameter usage
...
modparam("usrloc", "ka_loglevel", 1)
...
-3.56. ka_logmsg (str)
+3.57. ka_logmsg (str)
The formatted log specification to be added to the message printed when
the keepalive is received and roundtrip time is computed. The log
@@ -1187,7 +1210,7 @@ modparam("usrloc", "ka_loglevel", 1)
Default value is “ to-uri: [$tu] remote-addr: [$sas]”.
- Example 1.56. ka_logmsg parameter usage
+ Example 1.57. ka_logmsg parameter usage
...
modparam("usrloc", "ka_logmsg", " to-uri: [$tu] remote-addr: [$sas]")
...
Module: kamailio
Branch: 5.4
Commit: 79ec049ba50c0c48c02748c2679c07f4da2a766e
URL: https://github.com/kamailio/kamailio/commit/79ec049ba50c0c48c02748c2679c07f…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-22T19:28:58+02:00
usrloc: docs for ka_timeout module parameter
(cherry picked from commit 2e9d4e2dc45bf5baab1bff9c13fc841b66793cb4)
---
Modified: src/modules/usrloc/doc/usrloc_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/79ec049ba50c0c48c02748c2679c07f…
Patch: https://github.com/kamailio/kamailio/commit/79ec049ba50c0c48c02748c2679c07f…
---
diff --git a/src/modules/usrloc/doc/usrloc_admin.xml b/src/modules/usrloc/doc/usrloc_admin.xml
index 396d89828d..4b624fb81f 100644
--- a/src/modules/usrloc/doc/usrloc_admin.xml
+++ b/src/modules/usrloc/doc/usrloc_admin.xml
@@ -604,8 +604,8 @@ modparam("usrloc", "desc_time_order", 1)
<title><varname>timer_interval</varname> (int)</title>
<para>
Number of seconds between two timer runs. The module uses a timer to
- delete expired contacts, synchronize with database and other tasks,
- that need to be run periodically.
+ delete expired contacts, synchronize with database, send keepalives
+ and other tasks, that need to be run periodically.
</para>
<para>
<emphasis>
@@ -1424,6 +1424,36 @@ modparam("usrloc", "ka_filter", 1)
</example>
</section>
+ <section id="usrloc.p.ka_timeout">
+ <title><varname>ka_timeout</varname> (int)</title>
+ <para>
+ The parameter sets the interval in seconds after which a
+ contact is removed from location table if it does not reply to SIP
+ keepalives (usually OPTIONS ping requests).
+ </para>
+ <para>
+ The features is available only for contacts that are stored in memory
+ (not working for db only mode of the usrloc module).
+ </para>
+ <para>
+ Keepalives are sent stateless, not using TM module. The value of this
+ parameter has to be few times higher than timer interval.
+ </para>
+ <para>
+ <emphasis>
+ Default value is <quote>0</quote> (feature disabled).
+ </emphasis>
+ </para>
+ <example>
+ <title>Set <varname>ka_timeout</varname> parameter</title>
+ <programlisting format="linespecific">
+...
+modparam("usrloc", "ka_timeout", 120)
+...
+</programlisting>
+ </example>
+ </section>
+
<section id="usrloc.p.ka_loglevel">
<title><varname>ka_loglevel</varname> (int)</title>
<para>
### Description
If the SIP request URI has a parameter ;user=phone, then the match with `myself` fails with error in log.
### Troubleshooting
Sending an OPTIONS request through the proxy:
```
OPTIONS sip:+358removed@example.com;user=phone SIP/2.0.
...
From: <sip:+358removed@example.com;user=phone>;tag=JJhksk01ou7PFTq8xz1-GlhgGNG-c94A.
To: <sip:+358removed@example.com;user=phone>.
...
Content-Length: 0.
```
Note: The R-URI does NOT match myself. It never does in my case unless it's an attacker.
#### Reproduction
My config is very simple in terms of aliases:
```
auto_aliases=no
alias=172.29.1.21:5060
```
and in routing block:
` if (uri==myself) return;`
Log shows:
```
Listening on
udp: 172.29.1.21 [172.29.1.21]:5060
Aliases:
*: 172.29.1.21:5060
...
7(20681) ERROR: <core> [core/resolve.c:1808]: str2ip6buf(): invalid name, no conversion to IP address possible
...
```
### Possible Solutions
Sorry, I couldn't figure out where in the source this call to resolve.c functions happens.
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.3.6 (x86_64/linux) bf6c08
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: bf6c08
compiled on 09:25:09 Sep 10 2020 with gcc 4.8.5
```
* **Operating System**:
```
Amazon Linux 2 (up to date) on AWS
```
--
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/2482
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [x] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [x] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
<!-- Describe your changes in detail -->
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2474
-- Commit Summary --
* WIP
-- File Changes --
M src/modules/keepalive/keepalive.h (1)
M src/modules/keepalive/keepalive_api.c (23)
M src/modules/keepalive/keepalive_core.c (4)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2474.patchhttps://github.com/kamailio/kamailio/pull/2474.diff
--
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/pull/2474
Module: kamailio
Branch: master
Commit: fb115679228b19944f886893b47743db44465072
URL: https://github.com/kamailio/kamailio/commit/fb115679228b19944f886893b47743d…
Author: Nacho Garcia Segovia <nacho.gs(a)zaleos.net>
Committer: Nacho Garcia Segovia <nacho.gs(a)zaleos.net>
Date: 2020-09-14T13:18:37+02:00
keepalive: prevent race condition when deleting a destination
- Added a lock to ka_dest type, so we get it when we run callbacks that may be associated to an OPTIONS response
- Same lock is used to not remove destinations that are running callbacks
- Now find destinations consider owner and uri
---
Modified: src/modules/keepalive/keepalive.h
Modified: src/modules/keepalive/keepalive_api.c
Modified: src/modules/keepalive/keepalive_core.c
---
Diff: https://github.com/kamailio/kamailio/commit/fb115679228b19944f886893b47743d…
Patch: https://github.com/kamailio/kamailio/commit/fb115679228b19944f886893b47743d…
``cfgt_process_route()`` just tries to get every value that it's at ``pv_cache`` when entering or leaving a route. It relies on ``pv_get_spec_value()`` for values that are not ``$avp()`` nor ``$xavp()``
--
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/2479#issuecomment-694205484
Not familiar with the cfgt module, when is it executed in this case? I can see in the trace that it relies on some debugger api, maybe you can present more details about execution context to understand what happens behind the module.
--
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/2479#issuecomment-694181287
Module: kamailio
Branch: master
Commit: f1278a20bb37b29285c9d7cac298a3b1905f1c88
URL: https://github.com/kamailio/kamailio/commit/f1278a20bb37b29285c9d7cac298a3b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-17T13:19:13+02:00
corex: added rpc command shm.info
---
Added: src/modules/corex/corex_rpc_shm.c
Added: src/modules/corex/corex_rpc_shm.h
Modified: src/modules/corex/corex_mod.c
---
Diff: https://github.com/kamailio/kamailio/commit/f1278a20bb37b29285c9d7cac298a3b…
Patch: https://github.com/kamailio/kamailio/commit/f1278a20bb37b29285c9d7cac298a3b…
---
diff --git a/src/modules/corex/corex_mod.c b/src/modules/corex/corex_mod.c
index 8d0e649548..194efcdb8e 100644
--- a/src/modules/corex/corex_mod.c
+++ b/src/modules/corex/corex_mod.c
@@ -39,6 +39,7 @@
#include "corex_lib.h"
#include "corex_rpc.h"
+#include "corex_rpc_shm.h"
#include "corex_var.h"
#include "corex_nio.h"
@@ -188,6 +189,12 @@ static int mod_init(void)
return -1;
}
+ if(corex_init_rpc_shm()<0)
+ {
+ LM_ERR("failed to register RPC shm commands\n");
+ return -1;
+ }
+
if(corex_register_check_self()<0)
{
LM_ERR("failed to register check self callback\n");
diff --git a/src/modules/corex/corex_rpc_shm.c b/src/modules/corex/corex_rpc_shm.c
new file mode 100644
index 0000000000..5316cdc7bc
--- /dev/null
+++ b/src/modules/corex/corex_rpc_shm.c
@@ -0,0 +1,72 @@
+/**
+ * Copyright (C) 2020 Daniel-Constantin Mierla (asipto.com)
+ *
+ * This file is part of Kamailio, a free SIP server.
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ */
+
+#include <stdio.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <string.h>
+
+#include "../../core/dprint.h"
+#include "../../core/ut.h"
+#include "../../core/mem/shm.h"
+#include "../../core/globals.h"
+#include "../../core/rpc.h"
+#include "../../core/rpc_lookup.h"
+
+static const char* corex_rpc_shm_info_doc[2] = {
+ "Return details of the shared memory manager",
+ 0
+};
+
+
+/*
+ * RPC command to list the listening sockets
+ */
+static void corex_rpc_shm_info(rpc_t* rpc, void* ctx)
+{
+ void* th;
+
+ if (rpc->add(ctx, "{", &th) < 0) {
+ rpc->fault(ctx, 500, "Internal error creating rpc");
+ return;
+ }
+ if(rpc->struct_add(th, "su",
+ "name", (_shm_root.mname)?_shm_root.mname:"unknown",
+ "size", (unsigned int)shm_mem_size) <0) {
+ rpc->fault(ctx, 500, "Internal error adding fields");
+ return;
+ }
+}
+
+rpc_export_t corex_rpc_shm_cmds[] = {
+ {"shm.info", corex_rpc_shm_info, corex_rpc_shm_info_doc, 0},
+ {0, 0, 0, 0}
+};
+
+/**
+ * register RPC shm commands
+ */
+int corex_init_rpc_shm(void)
+{
+ if (rpc_register_array(corex_rpc_shm_cmds)!=0) {
+ LM_ERR("failed to register RPC shm commands\n");
+ return -1;
+ }
+ return 0;
+}
diff --git a/src/modules/corex/corex_rpc_shm.h b/src/modules/corex/corex_rpc_shm.h
new file mode 100644
index 0000000000..392dcafc08
--- /dev/null
+++ b/src/modules/corex/corex_rpc_shm.h
@@ -0,0 +1,25 @@
+/**
+ * Copyright (C) 2020 Daniel-Constantin Mierla (asipto.com)
+ *
+ * This file is part of Kamailio, a free SIP server.
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ */
+
+#ifndef _COREX_RPC_SHM_H_
+#define _COREX_RPC_SHM_H_
+
+int corex_init_rpc_shm(void);
+
+#endif
and we have the check of the value before at tmx/t_var.c 176:
```
if(t->uac[branch].reply==NULL || t->uac[branch].reply==FAKED_REPLY)
return 1;
```
So it seems other worker touched that shared memory part meanwhile
--
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/2479#issuecomment-693346859
Module: kamailio
Branch: 5.2
Commit: 07e51b97c9a409eeb4d735f8d20a67b6f6c7e097
URL: https://github.com/kamailio/kamailio/commit/07e51b97c9a409eeb4d735f8d20a67b…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-15T18:01:51+02:00
modules: readme files regenerated - modules ... [skip ci]
---
Modified: src/modules/registrar/README
---
Diff: https://github.com/kamailio/kamailio/commit/07e51b97c9a409eeb4d735f8d20a67b…
Patch: https://github.com/kamailio/kamailio/commit/07e51b97c9a409eeb4d735f8d20a67b…
---
diff --git a/src/modules/registrar/README b/src/modules/registrar/README
index c5f35ed381..ab3a38a260 100644
--- a/src/modules/registrar/README
+++ b/src/modules/registrar/README
@@ -239,21 +239,22 @@ Chapter 1. Admin Guide
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into
usrloc. There are three modes regarding the reply to a REGISTER
- including one or more Path HFs:
+ including one or more Path header fields:
* off - stores the value of the Path headers into usrloc without
passing it back to the UAC in the reply.
* lazy - stores the Path header and passes it back to the UAC if
- Path-support is indicated by the “path” param in the Supported HF.
+ Path-support is indicated by the “path” param in the Supported
+ header field.
* strict - rejects the registration with “420 Bad Extension” if
there's a Path header but no support for it is indicated by the
UAC. Otherwise it's stored and passed back to the UAC.
A call to lookup(...) always uses the path header if found, and inserts
- it as Route HF either in front of the first Route HF, or after the last
- Via HF if no Route is present. It also sets the destination uri to the
- first Path uri, thus overwriting the received-uri, because NAT has to
- be handled at the outbound-proxy of the UAC (the first hop after
- client's NAT).
+ it as Route header field either in front of the first Route header
+ field, or after the last Via header field if no Route is present. It
+ also sets the destination uri to the first Path uri, thus overwriting
+ the received-uri, because NAT has to be handled at the outbound-proxy
+ of the UAC (the first hop after client's NAT).
The whole process is transparent to the user, so no config changes are
required beside setting the registrar-parameters “use_path” and
@@ -322,10 +323,10 @@ Chapter 1. Admin Guide
3.1. default_expires (integer)
- If the processed message contains neither Expires HFs nor expires
- contact parameters, this value will be used for newly created usrloc
- records. The parameter contains number of second to expire (for example
- use 3600 for one hour). If it is set to a lower value than the
+ If the processed message contains neither Expires header fields nor
+ expires contact parameters, this value will be used for newly created
+ usrloc records. The parameter contains number of second to expire (for
+ example use 3600 for one hour). If it is set to a lower value than the
“min_expires” parameter then it will be ignored. This parameter can be
modified via ser config framework. A random value in a specific
interval can be selected by using the default_expires_range parameter
@@ -853,8 +854,8 @@ end
4.1. save(domain, [, flags [, uri]])
The function processes a REGISTER message. It can add, remove or modify
- location records (in usrloc) depending on Contact and Expires HFs in
- the REGISTER message. On success and when called from the
+ location records (in usrloc) depending on Contact and Expires header
+ fields in the REGISTER message. On success and when called from the
REQUEST_ROUTE, “200 OK” will be returned listing all contacts that are
currently in the location database. On an error, an error message will
be sent with a short description in reason phrase.
@@ -864,7 +865,7 @@ end
then this must be name of the table which stores the contacts.
* flags (optional) - the value may be a bitwise OR of the following
flags:
- + 0x01 - save the contacts only in memory cache without no DB
+ + 0x01 - save the contacts only in memory cache with no DB
operation;
+ 0x02 - do not generate a SIP reply to the current REGISTER
request. When used in ONREPLY_ROUTE, this parameter is
Module: kamailio
Branch: 5.3
Commit: 458d96d9cabf679efbcaaa81f69086c50940e495
URL: https://github.com/kamailio/kamailio/commit/458d96d9cabf679efbcaaa81f69086c…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-15T18:01:38+02:00
modules: readme files regenerated - modules ... [skip ci]
---
Modified: src/modules/registrar/README
---
Diff: https://github.com/kamailio/kamailio/commit/458d96d9cabf679efbcaaa81f69086c…
Patch: https://github.com/kamailio/kamailio/commit/458d96d9cabf679efbcaaa81f69086c…
---
diff --git a/src/modules/registrar/README b/src/modules/registrar/README
index e4516756e6..2a611ef564 100644
--- a/src/modules/registrar/README
+++ b/src/modules/registrar/README
@@ -245,21 +245,22 @@ Chapter 1. Admin Guide
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into
usrloc. There are three modes regarding the reply to a REGISTER
- including one or more Path HFs:
+ including one or more Path header fields:
* off - stores the value of the Path headers into usrloc without
passing it back to the UAC in the reply.
* lazy - stores the Path header and passes it back to the UAC if
- Path-support is indicated by the “path” param in the Supported HF.
+ Path-support is indicated by the “path” param in the Supported
+ header field.
* strict - rejects the registration with “420 Bad Extension” if
there's a Path header but no support for it is indicated by the
UAC. Otherwise it's stored and passed back to the UAC.
A call to lookup(...) always uses the path header if found, and inserts
- it as Route HF either in front of the first Route HF, or after the last
- Via HF if no Route is present. It also sets the destination uri to the
- first Path uri, thus overwriting the received-uri, because NAT has to
- be handled at the outbound-proxy of the UAC (the first hop after
- client's NAT).
+ it as Route header field either in front of the first Route header
+ field, or after the last Via header field if no Route is present. It
+ also sets the destination uri to the first Path uri, thus overwriting
+ the received-uri, because NAT has to be handled at the outbound-proxy
+ of the UAC (the first hop after client's NAT).
The whole process is transparent to the user, so no config changes are
required beside setting the registrar-parameters “use_path” and
@@ -329,10 +330,10 @@ Chapter 1. Admin Guide
3.1. default_expires (integer)
- If the processed message contains neither Expires HFs nor expires
- contact parameters, this value will be used for newly created usrloc
- records. The parameter contains number of second to expire (for example
- use 3600 for one hour). If it is set to a lower value than the
+ If the processed message contains neither Expires header fields nor
+ expires contact parameters, this value will be used for newly created
+ usrloc records. The parameter contains number of second to expire (for
+ example use 3600 for one hour). If it is set to a lower value than the
“min_expires” parameter then it will be ignored. This parameter can be
modified via ser config framework. A random value in a specific
interval can be selected by using the default_expires_range parameter
@@ -892,8 +893,8 @@ request_route {
4.1. save(domain, [, flags [, uri]])
The function processes a REGISTER message. It can add, remove or modify
- location records (in usrloc) depending on Contact and Expires HFs in
- the REGISTER message. On success and when called from the
+ location records (in usrloc) depending on Contact and Expires header
+ fields in the REGISTER message. On success and when called from the
REQUEST_ROUTE, “200 OK” will be returned listing all contacts that are
currently in the location database. On an error, an error message will
be sent with a short description in reason phrase.
@@ -903,7 +904,7 @@ request_route {
then this must be name of the table which stores the contacts.
* flags (optional) - the value may be a bitwise OR of the following
flags:
- + 0x01 - save the contacts only in memory cache without no DB
+ + 0x01 - save the contacts only in memory cache with no DB
operation;
+ 0x02 - do not generate a SIP reply to the current REGISTER
request. When used in ONREPLY_ROUTE, this parameter is
Module: kamailio
Branch: 5.4
Commit: 5cbec397d4dbe338400aefacddcce69dd0547f39
URL: https://github.com/kamailio/kamailio/commit/5cbec397d4dbe338400aefacddcce69…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-15T18:01:22+02:00
modules: readme files regenerated - modules ... [skip ci]
---
Modified: src/modules/registrar/README
---
Diff: https://github.com/kamailio/kamailio/commit/5cbec397d4dbe338400aefacddcce69…
Patch: https://github.com/kamailio/kamailio/commit/5cbec397d4dbe338400aefacddcce69…
---
diff --git a/src/modules/registrar/README b/src/modules/registrar/README
index fe9c969ce9..f4f5ccae0d 100644
--- a/src/modules/registrar/README
+++ b/src/modules/registrar/README
@@ -254,21 +254,22 @@ Chapter 1. Admin Guide
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into
usrloc. There are three modes regarding the reply to a REGISTER
- including one or more Path HFs:
+ including one or more Path header fields:
* off - stores the value of the Path headers into usrloc without
passing it back to the UAC in the reply.
* lazy - stores the Path header and passes it back to the UAC if
- Path-support is indicated by the “path” param in the Supported HF.
+ Path-support is indicated by the “path” param in the Supported
+ header field.
* strict - rejects the registration with “420 Bad Extension” if
there's a Path header but no support for it is indicated by the
UAC. Otherwise it's stored and passed back to the UAC.
A call to lookup(...) always uses the path header if found, and inserts
- it as Route HF either in front of the first Route HF, or after the last
- Via HF if no Route is present. It also sets the destination uri to the
- first Path uri, thus overwriting the received-uri, because NAT has to
- be handled at the outbound-proxy of the UAC (the first hop after
- client's NAT).
+ it as Route header field either in front of the first Route header
+ field, or after the last Via header field if no Route is present. It
+ also sets the destination uri to the first Path uri, thus overwriting
+ the received-uri, because NAT has to be handled at the outbound-proxy
+ of the UAC (the first hop after client's NAT).
The whole process is transparent to the user, so no config changes are
required beside setting the registrar-parameters “use_path” and
@@ -341,10 +342,10 @@ Chapter 1. Admin Guide
3.1. default_expires (integer)
- If the processed message contains neither Expires HFs nor expires
- contact parameters, this value will be used for newly created usrloc
- records. The parameter contains number of second to expire (for example
- use 3600 for one hour). If it is set to a lower value than the
+ If the processed message contains neither Expires header fields nor
+ expires contact parameters, this value will be used for newly created
+ usrloc records. The parameter contains number of second to expire (for
+ example use 3600 for one hour). If it is set to a lower value than the
“min_expires” parameter then it will be ignored. This parameter can be
modified via ser config framework. A random value in a specific
interval can be selected by using the default_expires_range parameter
@@ -955,8 +956,8 @@ kamcmd cfg.set_now_int registrar use_expired_contacts 0
4.1. save(domain, [, flags [, uri]])
The function processes a REGISTER message. It can add, remove or modify
- location records (in usrloc) depending on Contact and Expires HFs in
- the REGISTER message. On success and when called from the
+ location records (in usrloc) depending on Contact and Expires header
+ fields in the REGISTER message. On success and when called from the
REQUEST_ROUTE, “200 OK” will be returned listing all contacts that are
currently in the location database. On an error, an error message will
be sent with a short description in reason phrase.
@@ -966,7 +967,7 @@ kamcmd cfg.set_now_int registrar use_expired_contacts 0
then this must be name of the table which stores the contacts.
* flags (optional) - the value may be a bitwise OR of the following
flags:
- + 0x01 - save the contacts only in memory cache without no DB
+ + 0x01 - save the contacts only in memory cache with no DB
operation;
+ 0x02 - do not generate a SIP reply to the current REGISTER
request. When used in ONREPLY_ROUTE, this parameter is
Module: kamailio
Branch: 5.2
Commit: 8e62b35f97ba34268fbde35599ecd1645f0d7f76
URL: https://github.com/kamailio/kamailio/commit/8e62b35f97ba34268fbde35599ecd16…
Author: whosgonna <ben.whosgonna.com(a)gmail.com>
Committer: Henning Westerholt <hw(a)skalatan.de>
Date: 2020-09-15T15:50:10Z
registrar: Update documentation
- Fix double negative "without no DB operation". Changed to
"with no DB operation".
(cherry picked from commit be0382fa11920de972ddbcdbe17c3ff583da87e4)
---
Modified: src/modules/registrar/doc/registrar_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/8e62b35f97ba34268fbde35599ecd16…
Patch: https://github.com/kamailio/kamailio/commit/8e62b35f97ba34268fbde35599ecd16…
---
diff --git a/src/modules/registrar/doc/registrar_admin.xml b/src/modules/registrar/doc/registrar_admin.xml
index 7c4226ad3c..3edede4096 100644
--- a/src/modules/registrar/doc/registrar_admin.xml
+++ b/src/modules/registrar/doc/registrar_admin.xml
@@ -1026,7 +1026,7 @@ end
<itemizedlist>
<listitem>
<para><emphasis>0x01</emphasis> - save the contacts only
- in memory cache without no DB operation;
+ in memory cache with no DB operation;
</para>
</listitem>
<listitem>
Module: kamailio
Branch: 5.2
Commit: 59cede2607d8847cfff96aa6221f00e0abbb625d
URL: https://github.com/kamailio/kamailio/commit/59cede2607d8847cfff96aa6221f00e…
Author: whosgonna <ben.whosgonna.com(a)gmail.com>
Committer: Henning Westerholt <hw(a)skalatan.de>
Date: 2020-09-15T15:50:15Z
registrar: Update documentation
- Replace all occurences of "HF" with "header field"
- Replace all occurences of "HFs" with "header fields"
(cherry picked from commit d936c6276b6d8e45efd87a4fc25a55b9c3ab1fce)
---
Modified: src/modules/registrar/doc/registrar_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/59cede2607d8847cfff96aa6221f00e…
Patch: https://github.com/kamailio/kamailio/commit/59cede2607d8847cfff96aa6221f00e…
---
diff --git a/src/modules/registrar/doc/registrar_admin.xml b/src/modules/registrar/doc/registrar_admin.xml
index 3edede4096..54bfea5ff6 100644
--- a/src/modules/registrar/doc/registrar_admin.xml
+++ b/src/modules/registrar/doc/registrar_admin.xml
@@ -28,7 +28,7 @@
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into usrloc.
There are three modes regarding the reply to a REGISTER including
- one or more Path HFs:
+ one or more Path header fields:
</para>
<itemizedlist>
<listitem>
@@ -42,7 +42,7 @@
<para>
<emphasis>lazy</emphasis> - stores the Path header and
passes it back to the UAC if Path-support is indicated
- by the <quote>path</quote> param in the Supported HF.
+ by the <quote>path</quote> param in the Supported header field.
</para>
</listitem>
<listitem>
@@ -56,8 +56,8 @@
</itemizedlist>
<para>
A call to lookup(...) always uses the path header if
- found, and inserts it as Route HF either in front of
- the first Route HF, or after the last Via HF if no
+ found, and inserts it as Route header field either in front of
+ the first Route header field, or after the last Via header field if no
Route is present. It also sets the destination uri to
the first Path uri, thus overwriting the received-uri,
because NAT has to be handled at the outbound-proxy of
@@ -131,7 +131,7 @@
<title><varname>default_expires</varname> (integer)</title>
<para>
If the processed message contains neither Expires
- <acronym>HFs</acronym> nor expires contact parameters, this value
+ header fields nor expires contact parameters, this value
will be used for newly created usrloc records. The parameter contains
number of second to expire (for example use 3600 for one hour). If it
is set to a lower value than the <quote>min_expires</quote> parameter
@@ -1003,7 +1003,7 @@ end
</title>
<para>
The function processes a <emphasis>REGISTER</emphasis> message. It can add, remove or
- modify location records (in usrloc) depending on Contact and Expires HFs in the
+ modify location records (in usrloc) depending on Contact and Expires header fields in the
REGISTER message. On success and when called from the REQUEST_ROUTE,
<quote>200 OK</quote> will be returned listing all contacts that are currently in
the location database. On an error, an error message will be sent with a short
Module: kamailio
Branch: 5.3
Commit: 9be13ba9668b1c0aea9122ef4d8bfbb22e29eabb
URL: https://github.com/kamailio/kamailio/commit/9be13ba9668b1c0aea9122ef4d8bfbb…
Author: whosgonna <ben.whosgonna.com(a)gmail.com>
Committer: Henning Westerholt <hw(a)skalatan.de>
Date: 2020-09-15T15:49:47Z
registrar: Update documentation
- Replace all occurences of "HF" with "header field"
- Replace all occurences of "HFs" with "header fields"
(cherry picked from commit d936c6276b6d8e45efd87a4fc25a55b9c3ab1fce)
---
Modified: src/modules/registrar/doc/registrar_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/9be13ba9668b1c0aea9122ef4d8bfbb…
Patch: https://github.com/kamailio/kamailio/commit/9be13ba9668b1c0aea9122ef4d8bfbb…
---
diff --git a/src/modules/registrar/doc/registrar_admin.xml b/src/modules/registrar/doc/registrar_admin.xml
index 1a8942d3b4..8b83e3c00e 100644
--- a/src/modules/registrar/doc/registrar_admin.xml
+++ b/src/modules/registrar/doc/registrar_admin.xml
@@ -28,7 +28,7 @@
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into usrloc.
There are three modes regarding the reply to a REGISTER including
- one or more Path HFs:
+ one or more Path header fields:
</para>
<itemizedlist>
<listitem>
@@ -42,7 +42,7 @@
<para>
<emphasis>lazy</emphasis> - stores the Path header and
passes it back to the UAC if Path-support is indicated
- by the <quote>path</quote> param in the Supported HF.
+ by the <quote>path</quote> param in the Supported header field.
</para>
</listitem>
<listitem>
@@ -56,8 +56,8 @@
</itemizedlist>
<para>
A call to lookup(...) always uses the path header if
- found, and inserts it as Route HF either in front of
- the first Route HF, or after the last Via HF if no
+ found, and inserts it as Route header field either in front of
+ the first Route header field, or after the last Via header field if no
Route is present. It also sets the destination uri to
the first Path uri, thus overwriting the received-uri,
because NAT has to be handled at the outbound-proxy of
@@ -131,7 +131,7 @@
<title><varname>default_expires</varname> (integer)</title>
<para>
If the processed message contains neither Expires
- <acronym>HFs</acronym> nor expires contact parameters, this value
+ header fields nor expires contact parameters, this value
will be used for newly created usrloc records. The parameter contains
number of second to expire (for example use 3600 for one hour). If it
is set to a lower value than the <quote>min_expires</quote> parameter
@@ -1048,7 +1048,7 @@ request_route {
</title>
<para>
The function processes a <emphasis>REGISTER</emphasis> message. It can add, remove or
- modify location records (in usrloc) depending on Contact and Expires HFs in the
+ modify location records (in usrloc) depending on Contact and Expires header fields in the
REGISTER message. On success and when called from the REQUEST_ROUTE,
<quote>200 OK</quote> will be returned listing all contacts that are currently in
the location database. On an error, an error message will be sent with a short
Module: kamailio
Branch: 5.4
Commit: acce084fcab7249d52862bef0f4c32ed488222bc
URL: https://github.com/kamailio/kamailio/commit/acce084fcab7249d52862bef0f4c32e…
Author: whosgonna <ben.whosgonna.com(a)gmail.com>
Committer: Henning Westerholt <hw(a)skalatan.de>
Date: 2020-09-15T15:49:00Z
registrar: Update documentation
- Replace all occurences of "HF" with "header field"
- Replace all occurences of "HFs" with "header fields"
(cherry picked from commit d936c6276b6d8e45efd87a4fc25a55b9c3ab1fce)
---
Modified: src/modules/registrar/doc/registrar_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/acce084fcab7249d52862bef0f4c32e…
Patch: https://github.com/kamailio/kamailio/commit/acce084fcab7249d52862bef0f4c32e…
---
diff --git a/src/modules/registrar/doc/registrar_admin.xml b/src/modules/registrar/doc/registrar_admin.xml
index 75a4104fb2..461605f3d0 100644
--- a/src/modules/registrar/doc/registrar_admin.xml
+++ b/src/modules/registrar/doc/registrar_admin.xml
@@ -28,7 +28,7 @@
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into usrloc.
There are three modes regarding the reply to a REGISTER including
- one or more Path HFs:
+ one or more Path header fields:
</para>
<itemizedlist>
<listitem>
@@ -42,7 +42,7 @@
<para>
<emphasis>lazy</emphasis> - stores the Path header and
passes it back to the UAC if Path-support is indicated
- by the <quote>path</quote> param in the Supported HF.
+ by the <quote>path</quote> param in the Supported header field.
</para>
</listitem>
<listitem>
@@ -56,8 +56,8 @@
</itemizedlist>
<para>
A call to lookup(...) always uses the path header if
- found, and inserts it as Route HF either in front of
- the first Route HF, or after the last Via HF if no
+ found, and inserts it as Route header field either in front of
+ the first Route header field, or after the last Via header field if no
Route is present. It also sets the destination uri to
the first Path uri, thus overwriting the received-uri,
because NAT has to be handled at the outbound-proxy of
@@ -131,7 +131,7 @@
<title><varname>default_expires</varname> (integer)</title>
<para>
If the processed message contains neither Expires
- <acronym>HFs</acronym> nor expires contact parameters, this value
+ header fields nor expires contact parameters, this value
will be used for newly created usrloc records. The parameter contains
number of second to expire (for example use 3600 for one hour). If it
is set to a lower value than the <quote>min_expires</quote> parameter
@@ -1151,7 +1151,7 @@ kamcmd cfg.set_now_int registrar use_expired_contacts 0
</title>
<para>
The function processes a <emphasis>REGISTER</emphasis> message. It can add, remove or
- modify location records (in usrloc) depending on Contact and Expires HFs in the
+ modify location records (in usrloc) depending on Contact and Expires header fields in the
REGISTER message. On success and when called from the REQUEST_ROUTE,
<quote>200 OK</quote> will be returned listing all contacts that are currently in
the location database. On an error, an error message will be sent with a short
Module: kamailio
Branch: master
Commit: 56a257509aabb41e8eddc0f18347b0289aa0ab01
URL: https://github.com/kamailio/kamailio/commit/56a257509aabb41e8eddc0f18347b02…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-15T17:46:10+02:00
modules: readme files regenerated - registrar ... [skip ci]
---
Modified: src/modules/registrar/README
---
Diff: https://github.com/kamailio/kamailio/commit/56a257509aabb41e8eddc0f18347b02…
Patch: https://github.com/kamailio/kamailio/commit/56a257509aabb41e8eddc0f18347b02…
---
diff --git a/src/modules/registrar/README b/src/modules/registrar/README
index fe9c969ce9..f4f5ccae0d 100644
--- a/src/modules/registrar/README
+++ b/src/modules/registrar/README
@@ -254,21 +254,22 @@ Chapter 1. Admin Guide
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into
usrloc. There are three modes regarding the reply to a REGISTER
- including one or more Path HFs:
+ including one or more Path header fields:
* off - stores the value of the Path headers into usrloc without
passing it back to the UAC in the reply.
* lazy - stores the Path header and passes it back to the UAC if
- Path-support is indicated by the “path” param in the Supported HF.
+ Path-support is indicated by the “path” param in the Supported
+ header field.
* strict - rejects the registration with “420 Bad Extension” if
there's a Path header but no support for it is indicated by the
UAC. Otherwise it's stored and passed back to the UAC.
A call to lookup(...) always uses the path header if found, and inserts
- it as Route HF either in front of the first Route HF, or after the last
- Via HF if no Route is present. It also sets the destination uri to the
- first Path uri, thus overwriting the received-uri, because NAT has to
- be handled at the outbound-proxy of the UAC (the first hop after
- client's NAT).
+ it as Route header field either in front of the first Route header
+ field, or after the last Via header field if no Route is present. It
+ also sets the destination uri to the first Path uri, thus overwriting
+ the received-uri, because NAT has to be handled at the outbound-proxy
+ of the UAC (the first hop after client's NAT).
The whole process is transparent to the user, so no config changes are
required beside setting the registrar-parameters “use_path” and
@@ -341,10 +342,10 @@ Chapter 1. Admin Guide
3.1. default_expires (integer)
- If the processed message contains neither Expires HFs nor expires
- contact parameters, this value will be used for newly created usrloc
- records. The parameter contains number of second to expire (for example
- use 3600 for one hour). If it is set to a lower value than the
+ If the processed message contains neither Expires header fields nor
+ expires contact parameters, this value will be used for newly created
+ usrloc records. The parameter contains number of second to expire (for
+ example use 3600 for one hour). If it is set to a lower value than the
“min_expires” parameter then it will be ignored. This parameter can be
modified via ser config framework. A random value in a specific
interval can be selected by using the default_expires_range parameter
@@ -955,8 +956,8 @@ kamcmd cfg.set_now_int registrar use_expired_contacts 0
4.1. save(domain, [, flags [, uri]])
The function processes a REGISTER message. It can add, remove or modify
- location records (in usrloc) depending on Contact and Expires HFs in
- the REGISTER message. On success and when called from the
+ location records (in usrloc) depending on Contact and Expires header
+ fields in the REGISTER message. On success and when called from the
REQUEST_ROUTE, “200 OK” will be returned listing all contacts that are
currently in the location database. On an error, an error message will
be sent with a short description in reason phrase.
@@ -966,7 +967,7 @@ kamcmd cfg.set_now_int registrar use_expired_contacts 0
then this must be name of the table which stores the contacts.
* flags (optional) - the value may be a bitwise OR of the following
flags:
- + 0x01 - save the contacts only in memory cache without no DB
+ + 0x01 - save the contacts only in memory cache with no DB
operation;
+ 0x02 - do not generate a SIP reply to the current REGISTER
request. When used in ONREPLY_ROUTE, this parameter is
### Description
Use of acronym "HF" (header field) in the REGISTRAR is a bit obscure. It probably makes sense to experienced Kamailio admins, but it's not immediately apparent to beginners. Since there is little gained by using the acronym in this document it would be more friendly to use "header field".
Also, there is a double negative in section 4.1/flags/0x01:
```
0x01 - save the contacts only in memory cache without no DB operation;
```
The literal meaning of this sentence is that it performs a DB operation. This should be changed to "with no" or possibly just "without", or even "with no".
### Expected behavior
Use 'header field' instead of 'HF'. Use "with" instead of "without no".
#### Actual observed behavior
As indicated above
#### Debugging Data
Not applicable
#### Log Messages
Not applicable
#### SIP Traffic
Not applicable
### Possible Solutions
Use 'header field' instead of 'HF'. Use "with" instead of "without no".
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
Exists in most recent code branch.
* **Operating System**:
Not applicable.
--
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/2477
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [X] Commit message has the format required by CONTRIBUTING guide
- [X] Commits are split per component (core, individual modules, libs, utils, ...)
- [X] Each component has a single commit (if not, squash them into one commit)
- [X] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [X] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [X] PR should be backported to stable branches
- [X] Tested changes locally
- [X] Related to issue #2477
#### Description
Minor doc changes to Registrar module as described in Issue #2477
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2478
-- Commit Summary --
* registrar: Update documentation
* registrar: Update documentation
-- File Changes --
M src/modules/registrar/doc/registrar_admin.xml (14)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2478.patchhttps://github.com/kamailio/kamailio/pull/2478.diff
--
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/pull/2478
Module: kamailio
Branch: master
Commit: d936c6276b6d8e45efd87a4fc25a55b9c3ab1fce
URL: https://github.com/kamailio/kamailio/commit/d936c6276b6d8e45efd87a4fc25a55b…
Author: whosgonna <ben.whosgonna.com(a)gmail.com>
Committer: Henning Westerholt <hw(a)skalatan.de>
Date: 2020-09-15T17:41:40+02:00
registrar: Update documentation
- Replace all occurences of "HF" with "header field"
- Replace all occurences of "HFs" with "header fields"
---
Modified: src/modules/registrar/doc/registrar_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/d936c6276b6d8e45efd87a4fc25a55b…
Patch: https://github.com/kamailio/kamailio/commit/d936c6276b6d8e45efd87a4fc25a55b…
---
diff --git a/src/modules/registrar/doc/registrar_admin.xml b/src/modules/registrar/doc/registrar_admin.xml
index e3140965d4..bb2d8f8646 100644
--- a/src/modules/registrar/doc/registrar_admin.xml
+++ b/src/modules/registrar/doc/registrar_admin.xml
@@ -28,7 +28,7 @@
If path support is enabled in the registrar module, a call to save(...)
stores the values of the Path Header(s) along with the contact into usrloc.
There are three modes regarding the reply to a REGISTER including
- one or more Path HFs:
+ one or more Path header fields:
</para>
<itemizedlist>
<listitem>
@@ -42,7 +42,7 @@
<para>
<emphasis>lazy</emphasis> - stores the Path header and
passes it back to the UAC if Path-support is indicated
- by the <quote>path</quote> param in the Supported HF.
+ by the <quote>path</quote> param in the Supported header field.
</para>
</listitem>
<listitem>
@@ -56,8 +56,8 @@
</itemizedlist>
<para>
A call to lookup(...) always uses the path header if
- found, and inserts it as Route HF either in front of
- the first Route HF, or after the last Via HF if no
+ found, and inserts it as Route header field either in front of
+ the first Route header field, or after the last Via header field if no
Route is present. It also sets the destination uri to
the first Path uri, thus overwriting the received-uri,
because NAT has to be handled at the outbound-proxy of
@@ -131,7 +131,7 @@
<title><varname>default_expires</varname> (integer)</title>
<para>
If the processed message contains neither Expires
- <acronym>HFs</acronym> nor expires contact parameters, this value
+ header fields nor expires contact parameters, this value
will be used for newly created usrloc records. The parameter contains
number of second to expire (for example use 3600 for one hour). If it
is set to a lower value than the <quote>min_expires</quote> parameter
@@ -1151,7 +1151,7 @@ kamcmd cfg.set_now_int registrar use_expired_contacts 0
</title>
<para>
The function processes a <emphasis>REGISTER</emphasis> message. It can add, remove or
- modify location records (in usrloc) depending on Contact and Expires HFs in the
+ modify location records (in usrloc) depending on Contact and Expires header fields in the
REGISTER message. On success and when called from the REQUEST_ROUTE,
<quote>200 OK</quote> will be returned listing all contacts that are currently in
the location database. On an error, an error message will be sent with a short
<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for feature requests.
If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
If you submit a feature request (or enhancement) add the description of what you would like to be added.
If there is no content to be filled in a section, the entire section can be removed.
You can delete the comments from the template sections when filling.
You can delete next line and everything above before submitting (it is a comment).
-->
### Description
<!--
Explain what you did, what you expected to happen, and what actually happened.
-->
I'd like to reduce the number of contacts per AOR for certain UAs, while maintaining a default higher limit.
```
modparam("registrar", "max_contacts", 10)
modparam("registrar", "xavp_cfg", "reg")
route[REGISTRAR] {
if($ua=~"^Yealink") {
$xavp(reg=>max_contacts)=1;
}
if(!save("location")) {
sl_reply_error();
}
exit;
}
```
### Expected behavior
https://www.kamailio.org/docs/modules/stable/modules/registrar#registrar.p.… states:
* max_contacts - the number of maximum contacts to be stored for the current registration AoR. It **overwrites** the 'max_contacts' module parameter value.
I expect that the UA will register with the new contact and have all others removed.
#### Actual observed behavior
`$xavp(reg=>max_contacts)` set to a value lower than the `max_contacts` modparam does not achieve the **overwrites** expectation from the documentation.
#### Log Messages
<!--
Check the syslog file and if there are relevant log messages printed by Kamailio, add them next, or attach to issue, or provide a link to download them (e.g., to a pastebin site).
-->
```
INFO: registrar [save.c:619]: test_max_contacts(): too many contacts for AOR <user(a)example.com>
```
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.4.1-1.gite1d4ddcb6c.fc32 (x86_64/linux) 09fd6a
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 09fd6a
compiled on 00:00:00 Sep 5 2020 with gcc 10.2.1
```
* **Operating System**:
<!--
Details about the operating system, the type: Linux (e.g.,: Debian 8.4, Ubuntu 16.04, CentOS 7.1, ...), MacOS, xBSD, Solaris, ...;
Kernel details (output of `uname -a`)
-->
```
Fedora 32, kernel-5.8.4-200.fc32.x86_64
```
--
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/2471
Module: kamailio
Branch: master
Commit: 628d2d3fa7a6b61c85f0211838640bc5713ba3e7
URL: https://github.com/kamailio/kamailio/commit/628d2d3fa7a6b61c85f0211838640bc…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-15T07:46:18+02:00
modules: readme files regenerated - topos ... [skip ci]
---
Modified: src/modules/topos/README
---
Diff: https://github.com/kamailio/kamailio/commit/628d2d3fa7a6b61c85f0211838640bc…
Patch: https://github.com/kamailio/kamailio/commit/628d2d3fa7a6b61c85f0211838640bc…
---
diff --git a/src/modules/topos/README b/src/modules/topos/README
index b70fdd3737..72b1ae8b3f 100644
--- a/src/modules/topos/README
+++ b/src/modules/topos/README
@@ -98,17 +98,21 @@ Chapter 1. Admin Guide
1. Overview
- This module offers topology hiding by stripping the SIP routing headers
- that show topology details. The script interpreter gets the SIP
- messages with full content, so all existing functionality is preserved.
+ This module offers topology hiding for INVITE-based dialogs, by
+ stripping the SIP routing headers that show topology details . The
+ script interpreter gets the SIP messages with full content, so all
+ existing functionality is preserved.
The module is transparent for the configuration writer. It only needs
- to be loaded (tune the parameters if needed).
+ to be loaded (tune the module parameters if needed).
It also works for SIP MESSAGE or other requests that do not create a
- call dialog -- record_route() must be used for them as well, the
- headers are not going to be in the messages sent to the network, they
- are needed to know local addresses used to communicate with each side.
+ dialog -- record_route() must be used for them as well, the headers are
+ not going to be in the messages sent to the network, they are needed to
+ know local addresses used to communicate with each side. At this moment
+ it is not designed to work for presence (SUBSCRIBE-based) dialogs. The
+ REGISTER and PUBLISH requests are skipped from processing by this
+ module, expected to be terminated on a local SIP server.
2. Dependencies
Module: kamailio
Branch: master
Commit: 878971f2c0bc32233b6f18728f9b88537b3d19e8
URL: https://github.com/kamailio/kamailio/commit/878971f2c0bc32233b6f18728f9b885…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-15T07:33:00+02:00
topos: docs - more details about what SIP traffic is handled
---
Modified: src/modules/topos/doc/topos_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/878971f2c0bc32233b6f18728f9b885…
Patch: https://github.com/kamailio/kamailio/commit/878971f2c0bc32233b6f18728f9b885…
---
diff --git a/src/modules/topos/doc/topos_admin.xml b/src/modules/topos/doc/topos_admin.xml
index 46edd04a6c..973391430b 100644
--- a/src/modules/topos/doc/topos_admin.xml
+++ b/src/modules/topos/doc/topos_admin.xml
@@ -16,20 +16,23 @@
<section>
<title>Overview</title>
<para>
- This module offers topology hiding by stripping the SIP routing
- headers that show topology details.
+ This module offers topology hiding for INVITE-based dialogs, by stripping
+ the SIP routing headers that show topology details .
The script interpreter gets the SIP messages with full content,
so all existing functionality is preserved.
</para>
<para>
The module is transparent for the configuration writer. It only needs to be
- loaded (tune the parameters if needed).
+ loaded (tune the module parameters if needed).
</para>
<para>
It also works for SIP MESSAGE or other requests that do not create
- a call dialog -- record_route() must be used for them as well, the
+ a dialog -- record_route() must be used for them as well, the
headers are not going to be in the messages sent to the network, they
are needed to know local addresses used to communicate with each side.
+ At this moment it is not designed to work for presence (SUBSCRIBE-based)
+ dialogs. The REGISTER and PUBLISH requests are skipped from processing
+ by this module, expected to be terminated on a local SIP server.
</para>
</section>
<section>
Module: kamailio
Branch: master
Commit: e771c554d8ca8ec691c8f02efdf6f85187f49b0f
URL: https://github.com/kamailio/kamailio/commit/e771c554d8ca8ec691c8f02efdf6f85…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-14T13:34:38+02:00
rr: docs for loose_route_mode() function
---
Modified: src/modules/rr/doc/rr_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/e771c554d8ca8ec691c8f02efdf6f85…
Patch: https://github.com/kamailio/kamailio/commit/e771c554d8ca8ec691c8f02efdf6f85…
---
diff --git a/src/modules/rr/doc/rr_admin.xml b/src/modules/rr/doc/rr_admin.xml
index fb7b4d03ca..514c8b4a04 100644
--- a/src/modules/rr/doc/rr_admin.xml
+++ b/src/modules/rr/doc/rr_admin.xml
@@ -442,6 +442,34 @@ if(!loose_route_preloaded()) {
</example>
</section>
+ <section id="rr.f.loose_route_mode">
+ <title><function moreinfo="none">loose_route_mode(vmode)</function></title>
+
+ <para>The function is similar to `loose_route()`, but it does only
+ loose routing processing if vmode==1, skipping the testing of r-uri==myself
+ for performing strict routing. If vmode==0, it behaves like loose_route().
+ </para>
+ <para>It is a convenient function to use with application servers that
+ set the Contact URI to SIP server address.
+ </para>
+ <para>This function can be used from REQUEST_ROUTE.</para>
+
+ <example>
+ <title><function>loose_route_mode</function> usage</title>
+
+ <programlisting format="linespecific">
+...
+if(has_totag() and uri==myself) {
+ if(loose_route_mode("1")) {
+ rewritehostport("my.app.server:5090");
+ t_relay();
+ exit;
+ }
+}
+...
+</programlisting>
+ </example>
+ </section>
<section id="rr.f.record_route">
<title><function moreinfo="none">record_route([sparams])</function></title>
I am setting up a redundant active/active environment and I am in need of
having 2 kamailios operate as full proxies (meaning both of them will
accept registrations).
I am using DMQ in order to keep htables synched as well as dialogs.
For locations, I have a PostgreSQL database with the registrations.
My problem is that since both kamailios are accepting registrations the
UACs are only able to receive packets from the UAS on which they are
registered. Therefore when let's say UAC-1 registers to Kamailio A and it
tries to call UAC-2 which is registered on Kamailio B nothing happens
because UAC-2 receives the INVITE from Kamailio A and just ignores them.
I've spent almost a month trying to play with inter-kamailio communication
(that is, detecting these types of scenarios and sending the INVITE to
Kamailio B and have Kamailio B send the INVITE to UAC-2) but there are a
LOT of things that are not working properly let alone having to keep track
of all the dialog information and to/from tags and doing proper route of
all ACK/BYE/CANCEL, etc.
My question is, is there a way to achieve this scenario where multiple
kamailios can coexist with all responsibilities?
Things I've tried:
- Keep track of to/from tag in an htable and forward requests based on
who sent the request
- Use append_branches to handle multiple AOR (with the possibility of 1
user having multiple registrations in different kamailios)
- Manually tweaking $ru/$du based on what type of request is and who is
it destined to.
Any orientation will be appreciated as this is a crucial piece of the
project I'm working on.
Saludos,
[image: Facebook] <https://www.facebook.com/bvisonl>[image: Twitter]
<https://twitter.com/benjaminvison>[image: Instagram]
<https://instagram.com/bvisonl/>
Benjamín Visón / IT Engineer / Software Developer
bvisonl(a)gmail.com / (829)-664-5163
Module: kamailio
Branch: master
Commit: e52c1f334fb98e00809226cde190da3406976348
URL: https://github.com/kamailio/kamailio/commit/e52c1f334fb98e00809226cde190da3…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-11T22:16:12+02:00
modules: readme files regenerated - usrloc ... [skip ci]
---
Modified: src/modules/usrloc/README
---
Diff: https://github.com/kamailio/kamailio/commit/e52c1f334fb98e00809226cde190da3…
Patch: https://github.com/kamailio/kamailio/commit/e52c1f334fb98e00809226cde190da3…
---
diff --git a/src/modules/usrloc/README b/src/modules/usrloc/README
index ac3a6b7bb6..d075042834 100644
--- a/src/modules/usrloc/README
+++ b/src/modules/usrloc/README
@@ -94,8 +94,9 @@ Carsten Bock
3.52. ka_from (str)
3.53. ka_domain (str)
3.54. ka_filter (int)
- 3.55. ka_loglevel (int)
- 3.56. ka_logmsg (str)
+ 3.55. ka_timeout (int)
+ 3.56. ka_loglevel (int)
+ 3.57. ka_logmsg (str)
4. RPC Commands
@@ -197,8 +198,9 @@ Carsten Bock
1.52. ka_from parameter usage
1.53. ka_domain parameter usage
1.54. ka_filter parameter usage
- 1.55. ka_loglevel parameter usage
- 1.56. ka_logmsg parameter usage
+ 1.55. Set ka_timeout parameter
+ 1.56. ka_loglevel parameter usage
+ 1.57. ka_logmsg parameter usage
Chapter 1. Admin Guide
@@ -269,8 +271,9 @@ Chapter 1. Admin Guide
3.52. ka_from (str)
3.53. ka_domain (str)
3.54. ka_filter (int)
- 3.55. ka_loglevel (int)
- 3.56. ka_logmsg (str)
+ 3.55. ka_timeout (int)
+ 3.56. ka_loglevel (int)
+ 3.57. ka_logmsg (str)
4. RPC Commands
@@ -404,8 +407,9 @@ Chapter 1. Admin Guide
3.52. ka_from (str)
3.53. ka_domain (str)
3.54. ka_filter (int)
- 3.55. ka_loglevel (int)
- 3.56. ka_logmsg (str)
+ 3.55. ka_timeout (int)
+ 3.56. ka_loglevel (int)
+ 3.57. ka_logmsg (str)
3.1. nat_bflag (int)
@@ -683,8 +687,8 @@ modparam("usrloc", "desc_time_order", 1)
3.25. timer_interval (int)
Number of seconds between two timer runs. The module uses a timer to
- delete expired contacts, synchronize with database and other tasks,
- that need to be run periodically.
+ delete expired contacts, synchronize with database, send keepalives and
+ other tasks, that need to be run periodically.
Default value is 60.
@@ -1163,19 +1167,38 @@ modparam("usrloc", "ka_domain", "mydomain.com")
modparam("usrloc", "ka_filter", 1)
...
-3.55. ka_loglevel (int)
+3.55. ka_timeout (int)
+
+ The parameter sets the interval in seconds after which a contact is
+ removed from location table if it does not reply to SIP keepalives
+ (usually OPTIONS ping requests).
+
+ The features is available only for contacts that are stored in memory
+ (not working for db only mode of the usrloc module).
+
+ Keepalives are sent stateless, not using TM module. The value of this
+ parameter has to be few times higher than timer interval.
+
+ Default value is “0” (feature disabled).
+
+ Example 1.55. Set ka_timeout parameter
+...
+modparam("usrloc", "ka_timeout", 120)
+...
+
+3.56. ka_loglevel (int)
The level to print the log message when the keepalive response is
received. It should be a value between -5 (L_ALERT) and 3 (L_DBG).
Default value is “255” (disabled).
- Example 1.55. ka_loglevel parameter usage
+ Example 1.56. ka_loglevel parameter usage
...
modparam("usrloc", "ka_loglevel", 1)
...
-3.56. ka_logmsg (str)
+3.57. ka_logmsg (str)
The formatted log specification to be added to the message printed when
the keepalive is received and roundtrip time is computed. The log
@@ -1187,7 +1210,7 @@ modparam("usrloc", "ka_loglevel", 1)
Default value is “ to-uri: [$tu] remote-addr: [$sas]”.
- Example 1.56. ka_logmsg parameter usage
+ Example 1.57. ka_logmsg parameter usage
...
modparam("usrloc", "ka_logmsg", " to-uri: [$tu] remote-addr: [$sas]")
...
Module: kamailio
Branch: master
Commit: 2e9d4e2dc45bf5baab1bff9c13fc841b66793cb4
URL: https://github.com/kamailio/kamailio/commit/2e9d4e2dc45bf5baab1bff9c13fc841…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-11T22:07:31+02:00
usrloc: docs for ka_timeout module parameter
---
Modified: src/modules/usrloc/doc/usrloc_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/2e9d4e2dc45bf5baab1bff9c13fc841…
Patch: https://github.com/kamailio/kamailio/commit/2e9d4e2dc45bf5baab1bff9c13fc841…
---
diff --git a/src/modules/usrloc/doc/usrloc_admin.xml b/src/modules/usrloc/doc/usrloc_admin.xml
index 396d89828d..4b624fb81f 100644
--- a/src/modules/usrloc/doc/usrloc_admin.xml
+++ b/src/modules/usrloc/doc/usrloc_admin.xml
@@ -604,8 +604,8 @@ modparam("usrloc", "desc_time_order", 1)
<title><varname>timer_interval</varname> (int)</title>
<para>
Number of seconds between two timer runs. The module uses a timer to
- delete expired contacts, synchronize with database and other tasks,
- that need to be run periodically.
+ delete expired contacts, synchronize with database, send keepalives
+ and other tasks, that need to be run periodically.
</para>
<para>
<emphasis>
@@ -1424,6 +1424,36 @@ modparam("usrloc", "ka_filter", 1)
</example>
</section>
+ <section id="usrloc.p.ka_timeout">
+ <title><varname>ka_timeout</varname> (int)</title>
+ <para>
+ The parameter sets the interval in seconds after which a
+ contact is removed from location table if it does not reply to SIP
+ keepalives (usually OPTIONS ping requests).
+ </para>
+ <para>
+ The features is available only for contacts that are stored in memory
+ (not working for db only mode of the usrloc module).
+ </para>
+ <para>
+ Keepalives are sent stateless, not using TM module. The value of this
+ parameter has to be few times higher than timer interval.
+ </para>
+ <para>
+ <emphasis>
+ Default value is <quote>0</quote> (feature disabled).
+ </emphasis>
+ </para>
+ <example>
+ <title>Set <varname>ka_timeout</varname> parameter</title>
+ <programlisting format="linespecific">
+...
+modparam("usrloc", "ka_timeout", 120)
+...
+</programlisting>
+ </example>
+ </section>
+
<section id="usrloc.p.ka_loglevel">
<title><varname>ka_loglevel</varname> (int)</title>
<para>
#### Pre-Submission Checklist
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [*] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
Fix relaying MSRP messages to IPv6 uri.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2472
-- Commit Summary --
* msrp: fixed IPv6 addrees parsing
-- File Changes --
M src/modules/msrp/msrp_parser.c (12)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2472.patchhttps://github.com/kamailio/kamailio/pull/2472.diff
--
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/pull/2472
<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for bug reports.
If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
If there is no content to be filled in a section, the entire section can be removed.
You can delete the comments from the template sections when filling.
You can delete next line and everything above before submitting (it is a comment).
-->
### Description
`topos-redis` does not clean entries for failed and canceled calls.
modules are loaded in this order:
```
...
loadmodule "topos.so"
loadmodule "ndb_redis.so"
loadmodule "topos_redis.so"
# ----- ndb_redis params -----
modparam("ndb_redis", "server", "name=srvC;addr=REDIS_HOST;port=REDIS_PORT;db=REDIS_DB_TOPOS")
# ----- topos params -----
modparam("topos", "storage", "redis")
modparam("topos_redis", "serverid", "srvC")
modparam("topos", "mask_callid", 0)
modparam("topos", "sanity_checks", 0)
modparam("topos", "branch_expire", 30)
modparam("topos", "dialog_expire", 14400)
modparam("topos", "clean_interval", 10)
...
```
When a call is answered the timer are working fine and the records are cleaned after branch_expire timer.
1. call established
```
10.0.1.11:6379[9]> KEYS *
1) "b:x:z9hG4bKe33b.1c2d440696a8e6d47f678fcf80962608.0"
2) "d:z:atpsh-5d305fc4-51c0-1"
3) "b:x:INVITE:6cbb3f3c-0470-474a-90e9-1d3f07d42a1a:as32b06c60"
```
2. after 30s
```
10.0.1.11:6379[9]> KEYS *
1) "d:z:atpsh-5d305fc4-51c0-1"
```
4. call ends
```
10.0.1.11:6379[9]> KEYS *
1) "b:x:z9hG4bKa4f4.d283ab69d26e3eadea338bb3cc28860e.0"
2) "d:z:atpsh-5d305fc4-51c0-1"
```
5. after 30s
```
10.0.1.11:6379[9]> KEYS *
(empty list or set)
```
#### Issue description
When the call fails or it's canceled
```
10.0.1.11:6379[9]> KEYS *
1) "b:x:z9hG4bK6b04.0b594f71aba72f5f7f6f3ca8d7e57f04.0"
2) "d:z:atpsh-5d305fc4-51c3-1"
3) "b:x:INVITE:0319e114-c5b9-4dfc-91f0-392dc4239255:as018c9b6b"
```
after 30s
```
10.0.1.11:6379[9]> KEYS *
1) "d:z:atpsh-5d305fc4-51c3-1"
10.0.1.11:6379[9]> TTL "d:z:atpsh-5d305fc4-51c3-1"
(integer) 14319
```
The record `d:z:atpsh-5d305fc4-51c3-1` is not cleaned by the cancel or busy...it will persist in the redis until it expires.
I upgraded my machine from 5.1.3 to 5.1.8 after finding this fix #1608 which I noticed in the beginning.
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.1.8 (x86_64/linux) c7a172
flags: STATS: Off, USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144 MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: c7a172
compiled on 05:42:57 Jun 19 2019 with gcc 4.8.5
```
* **Operating System**:
```
3.10.0-693.17.1.el7.x86_64 #1 SMP Thu Jan 25 20:13:58 UTC 2018 x86_64 x86_64 x86_64 GNU/Lin
```
```
CentOS Linux release 7.4.1708 (Core)
```
--
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/2012
<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for bug reports.
If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
If there is no content to be filled in a section, the entire section can be removed.
You can delete the comments from the template sections when filling.
You can delete next line and everything above before submitting (it is a comment).
-->
### Description
I use kamilio to deploy as P-cscf, I-cscf,S-cscf to implement IMS functions, two test phones attach kamilio and make volte call. The P-cscf will exit every time.
### Troubleshooting
I think it may related to the collaboration between tm module and ipsec module.
#### Reproduction
I set up a test environment according to the instructions https://open5gs.org/open5gs/docs/tutorial/02-VoLTE-setup/ . two iphones connetc to the EPC and attach to kamailio,and the IPSec is available.
#### Debugging Data
Here is the gdb info
```
Reading symbols from /usr/local/sbin/kamailio...done.
[New LWP 22934]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/local/sbin/kamailio -f /etc/kamailio_pcscf/kamailio_pcscf.cfg -P /var/run/'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x00007f1f4951f2d0 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
(gdb) bt
#0 0x00007f1f4951f2d0 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#1 0x00007f1f494cefb4 in vfprintf () from /lib/x86_64-linux-gnu/libc.so.6
#2 0x00007f1f494d1370 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#3 0x00007f1f494ce7ea in vfprintf () from /lib/x86_64-linux-gnu/libc.so.6
#4 0x00007f1f494d78c4 in fprintf () from /lib/x86_64-linux-gnu/libc.so.6
#5 0x00007f1f44290629 in fill_contact (ci=0x7fff6d0ae1a0, m=0x7f1f48ee3280) at cmd.c:218
#6 0x00007f1f4429a29a in ipsec_forward (m=0x7f1f48ee3280, d=0x7f1f44a7efb8) at cmd.c:693
#7 0x00007f1f442890ac in w_forward (_m=0x7f1f48ee3280, _d=0x7f1f44a7efb8 "\270\356\247D\037\177", _cflags=0x0) at ims_ipsec_pcscf_mod.c:355
#8 0x000055713f26f2f1 in do_action (h=0x7fff6d0af080, a=0x7f1f48e7d3d8, msg=0x7f1f48ee3280) at core/action.c:1079
#9 0x000055713f27d2ab in run_actions (h=0x7fff6d0af080, a=0x7f1f48e79710, msg=0x7f1f48ee3280) at core/action.c:1578
#10 0x000055713f27dabd in run_top_route (a=0x7f1f48e79710, msg=0x7f1f48ee3280, c=0x7fff6d0af080) at core/action.c:1663
#11 0x00007f1f489dd18a in reply_received (p_msg=0x7f1f48ee3280) at t_reply.c:2418
#12 0x000055713f382183 in do_forward_reply (msg=0x7f1f48ee3280, mode=0) at core/forward.c:745
#13 0x000055713f383fcb in forward_reply (msg=0x7f1f48ee3280) at core/forward.c:846
#14 0x000055713f3e82a9 in receive_msg (
buf=0x55713f6c9ea0 <buf> "SIP/2.0 183 Session Progress\r\nRecord-Route: <sip:mt@192.168.4.207;transport=tcp;r2=on;lr=on;ftag=2573636716;rm=7;did=a1e.1e8>,<sip:mt@192.168.4.207;r2=on;lr=on;ftag=2573636716;rm=7;did=a1e.1e8>,<sip:m"..., len=1958, rcv_info=0x7fff6d0af5c0) at core/receive.c:510
#15 0x000055713f2d05e1 in udp_rcv_loop () at core/udp_server.c:548
#16 0x000055713f233c1e in main_loop () at main.c:1673
#17 0x000055713f23cff2 in main (argc=13, argv=0x7fff6d0afea8) at main.c:2802
```
#### Log Messages
Here is the P-cscf logs
[pcscf.log](https://github.com/kamailio/kamailio/files/4401553/pcscf.log)
#### SIP Traffic
[traffic.zip](https://github.com/kamailio/kamailio/files/4401567/traffic.zip)
### Possible Solutions
<!--
If you found a solution or workaround for the issue, describe it. Ideally, provide a pull request with a fix.
-->
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
(paste your output here)
```
* **Operating System**:
<!--
Details about the operating system, the type: Linux (e.g.,: Debian 8.4, Ubuntu 16.04, CentOS 7.1, ...), MacOS, xBSD, Solaris, ...;
Kernel details (output of `uname -a`)
-->
```
(paste your output here)
```
--
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/2267
Hello,
Kamailio SIP Server v5.3.6 stable release is out.
This is a maintenance release of the latest stable branch, 5.3, that
includes fixes since the release of v5.3.5. There is no change to
database schema or configuration language structure that you have to do
on previous installations of v5.3.x. Deployments running previous v5.3.x
versions are strongly recommended to be upgraded to v5.3.6.
Note that 5.3 is the second last stable branch, still officially maintained
by Kamailio development team. The latest stable branch is 5.4, with
v5.4.1 being release out of it.
For more details about version 5.3.6 (including links and guidelines to
download the tarball or from GIT repository), visit:
* https://www.kamailio.org/w/2020/09/kamailio-v5-3-6-released/
RPM, Debian/Ubuntu packages will be available soon as well.
Many thanks to all contributing and using Kamailio!
Cheers,
Daniel
--
Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
Hello,
I am considering to release v5.3.6 from the branch 5.3 in the next days,
aiming from Thursday (Sep 10, 2020) if everything goes as planned at
this moment, or on Monday (Sep 14, 2020) if a little bit of time is
needed. Should you be aware of any issue that needs to be addressed in
the branch 5.3 (e.g., a bug, or a missing backport), inform us as soon
as possible to try to sort it out in time.
Cheers,
Daniel
--
Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
Funding: https://www.paypal.me/dcmierla
<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for bug reports.
If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
* http://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
If there is no content to be filled in a section, the entire section can be removed.
You can delete the comments from the template sections when filling.
You can delete next line and everything above before submitting (it is a comment).
-->
### Description
We have segfault in Kamailio v5.3.1 installed on Debain 9.x 64 bit occured while kamailio was shutting down while our script tryed to get metric using kamcmd utility at the same time.
### Troubleshooting
No troubleshooting was done, since it happened on a production server. We simply restarted the server.
#### Reproduction
The problem periodically happens on production servers during restart. Kamailio crashes when one of our scripts tried getting statistics about websocket and tls modules using kamcmd during server restart. As I see in core dump, shared memory was already freed when rpc_mod_print called in the child process.
#### Debugging Data
<!--
If you got a core dump, use gdb to extract troubleshooting data - full backtrace,
local variables and the list of the code at the issue location.
gdb /path/to/kamailio /path/to/corefile
bt full
info locals
list
If you are familiar with gdb, feel free to attach more of what you consider to
be relevant.
-->
```
core.kamailio.17684
/var/lib/ums/sbin/kamailio
GNU gdb (Debian 7.12-6) 7.12.0.20161007-git
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /var/lib/ums/sbin/kamailio...done.
[New LWP 17684]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/var/lib/ums/sbin/kamailio -m 2048 -M 12 -P /var/run/kamailio/kamailio.pid -f /'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 __strcmp_ssse3 () at ../sysdeps/x86_64/multiarch/../strcmp.S:1197
#0 __strcmp_ssse3 () at ../sysdeps/x86_64/multiarch/../strcmp.S:1197
#1 0x00007ff4d6ddb2f5 in rpc_mod_print (rpc=0x7ff4d66f0540 <binrpc_callbacks>, ctx=0x7fff11cd5658, mname=0x1f140b8 "tls", stats=0x1f2f180, flag=2) at mod_stats.c:117
#2 0x00007ff4d6ddb0eb in rpc_mod_print_one (rpc=0x7ff4d66f0540 <binrpc_callbacks>, ctx=0x7fff11cd5658, mname=0x1f140b8 "tls", pkg_stats=0x1f2d9c0, shm_stats=0x1f2f180, flag=2) at mod_stats.c:159
#3 0x00007ff4d6ddaee1 in rpc_mod_mem_stats_mode (rpc=0x7ff4d66f0540 <binrpc_callbacks>, ctx=0x7fff11cd5658, fmode=0) at mod_stats.c:239
#4 0x00007ff4d6dda84f in rpc_mod_mem_stats (rpc=0x7ff4d66f0540 <binrpc_callbacks>, ctx=0x7fff11cd5658) at mod_stats.c:251
#5 0x00007ff4d64bfc80 in process_rpc_req (buf=0x1f140a4 "\241\003\026t\256\214=\221\nmod.stats", size=29, bytes_needed=0x7fff11cd5aa0, sh=0x7fff11cd5a10, saved_state=0x1f240a8) at binrpc_run.c:678
#6 0x00007ff4d64ad72f in handle_stream_read (s_c=0x1f14070, idx=-1) at io_listener.c:511
#7 0x00007ff4d64a9121 in handle_io (fm=0x7ff55a4e4ae0, events=1, idx=-1) at io_listener.c:706
#8 0x00007ff4d64a793a in io_wait_loop_epoll (h=0x7ff4d66f0348 <io_h>, t=10, repeat=0) at ./../../core/io_wait.h:1062
#9 0x00007ff4d649b62c in io_listen_loop (fd_no=2, cs_lst=0x1e28940) at io_listener.c:281
#10 0x00007ff4d64d172c in mod_child (rank=0) at ctl.c:338
#11 0x0000000000638c14 in init_mod_child (m=0x7ff55a3634b0, rank=0) at core/sr_module.c:780
#12 0x000000000063862d in init_mod_child (m=0x7ff55a363b78, rank=0) at core/sr_module.c:776
#13 0x000000000063862d in init_mod_child (m=0x7ff55a364018, rank=0) at core/sr_module.c:776
#14 0x000000000063862d in init_mod_child (m=0x7ff55a364528, rank=0) at core/sr_module.c:776
#15 0x000000000063862d in init_mod_child (m=0x7ff55a3649c8, rank=0) at core/sr_module.c:776
#16 0x000000000063862d in init_mod_child (m=0x7ff55a365140, rank=0) at core/sr_module.c:776
#17 0x000000000063862d in init_mod_child (m=0x7ff55a3657b0, rank=0) at core/sr_module.c:776
#18 0x000000000063862d in init_mod_child (m=0x7ff55a365c38, rank=0) at core/sr_module.c:776
#19 0x00000000006385b2 in init_child (rank=0) at core/sr_module.c:825
#20 0x000000000043140c in main_loop () at main.c:1753
#21 0x000000000043df6f in main (argc=9, argv=0x7fff11cd9dd8) at main.c:2802
```
#### Log Messages
No any useful logs available.
#### SIP Traffic
No SIP traffic available.
### Possible Solutions
<!--
If you found a solution or workaround for the issue, describe it. Ideally, provide a pull request with a fix.
-->
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.3.1 (x86_64/linux) 283e46
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 283e46
compiled on 14:23:37 Jul 28 2020 with clang 9.0
```
* **Operating System**:
<!--
Details about the operating system, the type: Linux (e.g.,: Debian 8.4, Ubuntu 16.04, CentOS 7.1, ...), MacOS, xBSD, Solaris, ...;
Kernel details (output of `uname -a`)
-->
```
Linux devhpbx005-1.vx 4.9.0-12-amd64 #1 SMP Debian 4.9.210-1 (2020-01-20) x86_64 GNU/Linux
```
--
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/2433
#### Pre-Submission Checklist
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
- [x] PR should be backported to stable branches
- [x] Tested changes locally
#### Description
Allows to pass unique address part into contact header for REGISTER requests for each uacreg entry
If contact_addr wasn't passed into uacreg for a particular entry default reg_contact_addr will be used instead.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2470
-- Commit Summary --
* uacreg contact_addr added into db as configrable parameter for each entry
* docs generated
* formatting
* Merge branch 'uacreg-contact_addr-field-in-db' of https://github.com/ovoshlook/kamailio into uacreg-contact_addr-field-in-db
* reverted readme
* formatting
* formatting
-- File Changes --
M src/modules/uac/doc/uac_admin.xml (11)
M src/modules/uac/uac_reg.c (43)
M src/modules/uac/uac_reg.h (2)
M utils/kamctl/db_berkeley/kamailio/uacreg (4)
M utils/kamctl/db_berkeley/kamailio/version (2)
M utils/kamctl/db_redis/kamailio/uacreg (2)
M utils/kamctl/db_sqlite/uac-create.sql (3)
M utils/kamctl/dbtext/kamailio/uacreg (2)
M utils/kamctl/mongodb/kamailio/uacreg.json (7)
M utils/kamctl/mysql/uac-create.sql (3)
M utils/kamctl/oracle/uac-create.sql (3)
M utils/kamctl/postgres/uac-create.sql (3)
M utils/kamctl/xhttp_pi/uac-mod (3)
M utils/kamctl/xhttp_pi/uac-table (1)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2470.patchhttps://github.com/kamailio/kamailio/pull/2470.diff
--
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/pull/2470
Module: kamailio
Branch: master
Commit: 3c643c023626e0de744c4960f2a7af4a401f6df0
URL: https://github.com/kamailio/kamailio/commit/3c643c023626e0de744c4960f2a7af4…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-09T13:31:27+02:00
modules: readme files regenerated - uac ... [skip ci]
---
Modified: src/modules/uac/README
---
Diff: https://github.com/kamailio/kamailio/commit/3c643c023626e0de744c4960f2a7af4…
Patch: https://github.com/kamailio/kamailio/commit/3c643c023626e0de744c4960f2a7af4…
---
diff --git a/src/modules/uac/README b/src/modules/uac/README
index a018d29a16..ae8376ab15 100644
--- a/src/modules/uac/README
+++ b/src/modules/uac/README
@@ -524,6 +524,9 @@ modparam("uac", "reg_db_table", "uacreg")
username part of the Contact: URI will be the L_UUID field in the
database.
+ A contact_addr value in the uacreg table will override the parameter
+ for this particular entry.
+
Example 1.17. Set reg_contact_addr parameter
...
modparam("uac", "reg_contact_addr", "192.168.1.2:5080")
@@ -1111,8 +1114,10 @@ event_route[uac:reply] {
* flags
* reg_delay
* socket
+ * contact_addr
- Use a dot (.) if no value should be set for auth_password or auth_ha1.
+ Use a dot (.) if no value should be set for auth_password, auth_ha1, or
+ contact_addr.
Example 1.45. uac.reg_add usage
...
@@ -1155,6 +1160,11 @@ event_route[uac:reply] {
* reg_delay - delay initial registration with at least reg_delay
seconds, e.g.,: 3
+ * contact_addr - contact address to be used for this record instead
+ of reg_contact_addr module parameter, e.g.:, 192.168.0.125:5060. It
+ can be set to '.' (dot) to skip setting it and then
+ reg_contact_addr modparam is used.
+
* socket - Used socket for sending out registration requests, e.g.:,
udp:192.168.0.125:5060
Module: kamailio
Branch: master
Commit: 89656680c6ff3aae00bbffae03131a1e983198dd
URL: https://github.com/kamailio/kamailio/commit/89656680c6ff3aae00bbffae03131a1…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-09T13:26:54+02:00
uac: docs - updates for uacreg contact addr field
---
Modified: src/modules/uac/doc/uac_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/89656680c6ff3aae00bbffae03131a1…
Patch: https://github.com/kamailio/kamailio/commit/89656680c6ff3aae00bbffae03131a1…
---
diff --git a/src/modules/uac/doc/uac_admin.xml b/src/modules/uac/doc/uac_admin.xml
index 42645e891a..d43b8afa0c 100644
--- a/src/modules/uac/doc/uac_admin.xml
+++ b/src/modules/uac/doc/uac_admin.xml
@@ -1359,12 +1359,13 @@ event_route[uac:reply] {
<listitem><para>expires</para></listitem>
<listitem><para>flags</para></listitem>
<listitem><para>reg_delay</para></listitem>
- <listitem><para>contact_addr</para></listitem>
<listitem><para>socket</para></listitem>
+ <listitem><para>contact_addr</para></listitem>
</itemizedlist>
</para>
<para>
- Use a dot (.) if no value should be set for auth_password or auth_ha1.
+ Use a dot (.) if no value should be set for auth_password, auth_ha1,
+ or contact_addr.
</para>
<example>
@@ -1463,8 +1464,9 @@ event_route[uac:reply] {
</itemizedlist>
<itemizedlist>
<listitem><para>
- <emphasis>contact_addr</emphasis> - Used contact address for sending out registration requests,
- e.g.:, 192.168.0.125:5060
+ <emphasis>contact_addr</emphasis> - contact address to be used for this record
+ instead of reg_contact_addr module parameter, e.g.:, 192.168.0.125:5060. It can
+ be set to '.' (dot) to skip setting it and then reg_contact_addr modparam is used.
</para></listitem>
</itemizedlist>
<itemizedlist>
Module: kamailio
Branch: 5.3
Commit: e1dc051e4171cb7a441987d0c184fc210fa57063
URL: https://github.com/kamailio/kamailio/commit/e1dc051e4171cb7a441987d0c184fc2…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-09-08T12:47:01+02:00
modules: readme files regenerated - modules ... [skip ci]
---
Modified: src/modules/app_lua/README
Modified: src/modules/pike/README
Modified: src/modules/tls/README
---
Diff: https://github.com/kamailio/kamailio/commit/e1dc051e4171cb7a441987d0c184fc2…
Patch: https://github.com/kamailio/kamailio/commit/e1dc051e4171cb7a441987d0c184fc2…
---
diff --git a/src/modules/app_lua/README b/src/modules/app_lua/README
index a1f0c05984..545fb78f14 100644
--- a/src/modules/app_lua/README
+++ b/src/modules/app_lua/README
@@ -94,6 +94,9 @@ Chapter 1. Admin Guide
To read more about KEMI exports and available KSR submodules, see:
* http://kamailio.org/docs/tutorials/devel/kamailio-kemi-framework/
+ Note: to have the old Lua module 'sr' available, load the 'app_lua_sr'
+ Kamailio module.
+
Lua (http://www.lua.org) is a fast and easy to embed scripting
language. Exported API from SIP router to Lua is documented in the
dokuwiki.
@@ -203,7 +206,7 @@ lua_dofile("/usr/local/etc/kamailio/lua/myscript.lua");
Example 1.6. lua_dostring usage
...
-if(!lua_dostring("sr.log([[err]], [[----------- Hello World from $fU\n]])"))
+if(!lua_dostring("KSR.log([[err]], [[----------- Hello World from $fU\n]])"))
{
xdbg("SCRIPT: failed to execute lua script!\n");
}
@@ -237,7 +240,7 @@ lua_run("lua_func3", "$rU", "2", "$si");
Example 1.8. lua_runstring usage
...
-if(!lua_runstring("sr.log([[err]], [[----------- Hello World from $fU\n]])"))
+if(!lua_runstring("KSR.log([[err]], [[----------- Hello World from $fU\n]])"))
{
xdbg("SCRIPT: failed to execute lua script!\n");
}
@@ -297,7 +300,7 @@ if(!lua_runstring("sr.log([[err]], [[----------- Hello World from $fU\n]])"))
'/usr/local/etc/kamailio/lua/myscript.lua'.
...
function sr_append_fu_to_reply()
- sr.hdr.append_to_reply("P-From: " .. sr.pv.get("$fu") .. "\r\n");
+ KSR.hdr.append_to_reply("P-From: " .. KSR.pv.get("$fu") .. "\r\n");
end
...
diff --git a/src/modules/pike/README b/src/modules/pike/README
index a7f66697e7..beea746f45 100644
--- a/src/modules/pike/README
+++ b/src/modules/pike/README
@@ -39,6 +39,7 @@ Bogdan-Andrei Iancu
2. RPC calls
1. pike.top
+ 2. pike.list
3. Developer Guide
@@ -49,6 +50,7 @@ Bogdan-Andrei Iancu
1.3. Set remove_latency parameter
1.4. Set pike_log_level parameter
1.5. pike_check_req usage
+ 2.1. Using pike.top
3.1. Tree of IP addresses
Chapter 1. Admin Guide
@@ -219,6 +221,7 @@ Chapter 2. RPC calls
Table of Contents
1. pike.top
+ 2. pike.list
1. pike.top
@@ -230,9 +233,9 @@ Chapter 2. RPC calls
Some IPs could be marked as HOT depending on theirs request rates.
- pike.top command takes one string parameter which specifies what kind
- of nodes you are interested in. Possible values are HOT or ALL. If no
- argument is given, it behaves as HOT was used.
+ pike.top command can take one string parameter which specifies what
+ kind of nodes you are interested in. Possible values are HOT or ALL. If
+ no argument is given, it behaves as HOT was used.
Marking nodes HOT is done on server side, client only presents given
data and make some postprocessing like sorting.
@@ -240,6 +243,15 @@ Chapter 2. RPC calls
Output of this command is a simple dump of ip_tree nodes marked as
ip-leafs.
+ Example 2.1. Using pike.top
+...
+kamcli rpc pike.top ALL
+...
+
+2. pike.list
+
+ Alias for "pike.top" command.
+
Chapter 3. Developer Guide
One single tree (for both IPv4 and IPv6) is used. Each node contains a
diff --git a/src/modules/tls/README b/src/modules/tls/README
index 0a0e6650d7..99f05e22c5 100644
--- a/src/modules/tls/README
+++ b/src/modules/tls/README
@@ -1426,7 +1426,7 @@ end
10.34. rand_engine (str)
- Set the ranondom number generator engine for libssl.
+ Set the random number generator engine for libssl.
Note: the default random number generator (PRNG) engine of libssl
v1.1.x is not designed for multi-process applications and can result in
- URL: https://github.com/kamailio/kamailio/commit/fa7042676c0dc2ea8760c928ef70fd1…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:52:35+02:00
kamctl: added pstrap command
- use ps to get list of PIDs for Kamailio instance, instead of RPC
core.psx
(cherry picked from commit 97ec85559f1e33405fff2320443dc86d2df13456)
- URL: https://github.com/kamailio/kamailio/commit/12aecb27779637b90ef83efea4dfaf0…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:52:44+02:00
kamctl: print process details in pstrap output
(cherry picked from commit 904a1590dbcdbb0fda9f676b4768596f797e9e27)
- URL: https://github.com/kamailio/kamailio/commit/7ac48ca1a6bd0462199ebb6cf1be61b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:52:57+02:00
kamctl: skip tracing kamctl itself in pstrap
(cherry picked from commit 626c0dee863fa517e473148ca8010d737a8f7ffe)
- URL: https://github.com/kamailio/kamailio/commit/c79cc69ac27bd1d6b506634e8a9d768…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:56:49+02:00
tls: docs - fixed typo
- GH #2410
(cherry picked from commit a12064696ac37cadf954a89b58daa1e05e182180)
(cherry picked from commit eb2abae40b36ad123528cddb25e0ddd217b68b22)
- URL: https://github.com/kamailio/kamailio/commit/5896f8e31078ff9b5d704c7393d7a7a…
Author: Luis Martin Gil <luismartingil(a)zaleos.net>
Date: 2020-09-08T09:57:08+02:00
tm - remove not used route_mode var
(cherry picked from commit 6619be46249dfe0b2f2cbc863cb8b2f44716122b)
- URL: https://github.com/kamailio/kamailio/commit/6474444f12b15b443f9f0ed96e509b2…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:57:50+02:00
log_custom: print to stderror if sending log message fails
- help troubleshooting while avoiding looping to same function in case
the log engine is set to log custom module
(cherry picked from commit f16d046f6330f897b374d9bb7dab3b2ce8eab3a7)
(cherry picked from commit 1ecade5cbd323e1ab45ec6f83236e1d389739d3b)
- URL: https://github.com/kamailio/kamailio/commit/9db407d0ad2a2e48725ddc2fd370269…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:58:18+02:00
app_lua: docs - note about availability of 'sr' Lua module
- use KSR in the examples
(cherry picked from commit 34efa83569bedb1f36c3661ee063ff6334633e4a)
(cherry picked from commit c98d9e8c6687f2311f51016ed9cc2e089d4eb242)
- URL: https://github.com/kamailio/kamailio/commit/4f9a5cdefb8d6baf9c069e277012d6d…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:58:30+02:00
xcap_server: check before going to the end of the buffer
- use marcros to set and restore char for ending 0
(cherry picked from commit 6ce5c0bdf136ecffd7917f2d60093e1b2c49fa54)
(cherry picked from commit 4aeb071b26df08e1dfc902340475c077e468c661)
- URL: https://github.com/kamailio/kamailio/commit/2d581622496e2141401a00a47011cf1…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:58:58+02:00
db_text: free pointer in case of error
(cherry picked from commit bddf16db74ea779bb01805fc2cbabfdaf8f4d62b)
(cherry picked from commit aabb2b2cfab6dc664ebc4b3d15db0d2ecb3cafd5)
- URL: https://github.com/kamailio/kamailio/commit/0f8528d4705e0e7060708f6108c47bc…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:59:07+02:00
Makefile.defs: get clang version only from --version output
- the full version with stderr output included has a different first
line on MacOS, making head -n 1 not extract the version number line
(cherry picked from commit bff689cfedca70149e17b6ec3584ca9ecab71418)
(cherry picked from commit b14b0a116791b85f2048e5fc863e50b7f7d93405)
- URL: https://github.com/kamailio/kamailio/commit/148cf4bb35cb94e111cf8ade1294519…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:59:17+02:00
Makefile.defs: map gcc v10.x to 9.0+ options
- detect properly the 10.x gcc version number, GH #2425
(cherry picked from commit 79e7738027a40affa4c7f606bf55a3ad0fe31bc4)
(cherry picked from commit 6d79c954469082aeb8518fdcca80217ce4826992)
- URL: https://github.com/kamailio/kamailio/commit/58043293132efa043a1d9ebfb2473d1…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:59:27+02:00
pike: docs - section for pike.list rpc command
(cherry picked from commit 720e929a87c6d3ee29c316ca63886c7142320f43)
(cherry picked from commit c783f19708bfd1d8c2334f739c8960b2de5f4fb3)
- URL: https://github.com/kamailio/kamailio/commit/0567c42a324deaa8dfe60cf1d8281aa…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T09:59:39+02:00
topoh: check if via param has the expected prefix, otherwise skip
- GH #2437
(cherry picked from commit 046126b4a90090bf5b8f9b517ba5218793e6b973)
(cherry picked from commit c8c884c4db353d4fac83752a494989e699fc36ff)
- URL: https://github.com/kamailio/kamailio/commit/e956b3c7dbb931f719e11a44887c5ee…
Author: Dmitry <dmitry.wagin(a)ya.ru>
Date: 2020-09-08T09:59:55+02:00
Makefile.defs: Fixed libs option for FreeBSD
(cherry picked from commit f490c4e0f5888963a01fa99fe94a464d44223199)
(cherry picked from commit 0efd0d63a8f8d7b644d0eba13552778d3b746c67)
- URL: https://github.com/kamailio/kamailio/commit/659edfc219c850ac464869589d11fb8…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T10:00:18+02:00
topoh: remove the Via cookie when skipping topoh via event route
- event route is now executed with parsed sip message to be sent out
- GH #2437
(cherry picked from commit 06a1d20fdcae42c8f2130c547c6c6cf5fb6dce26)
(cherry picked from commit b5176749605808af737aca00992f549152f9c38a)
- URL: https://github.com/kamailio/kamailio/commit/4c80e4c71a44fbe26761bee730e423f…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-09-08T10:00:37+02:00
usrloc: get_udomain() - safety checks for location table name parameter
(cherry picked from commit 29dde9fea1eb21b4bb484286f7443dd32f611bd2)
(cherry picked from commit ac56dfde20c5e689fb911debdd33a6155f7b130c)
Do Module RTPENGINE Supports 'Replaces' header (RFC 3891), if yes then how to use this feature, if no then will module RTPEngine will have support for 'Replaces' in the near future? I have been using Freeswitch for this functionality but facing many difficulties in it.
--
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/2473
- This avoids a race condition that may happen processing tm_request callbacl
- Allows to identify uniquely a ka_dest record
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [x] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [x] Tested changes locally
- [x] Related to issue #2448
#### Description
<!-- Describe your changes in detail -->
Check issue
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2462
-- Commit Summary --
* keepalive: added uuid to ka_dest structure to avoid passing the whole struct to tm
-- File Changes --
M src/modules/keepalive/keepalive.h (5)
M src/modules/keepalive/keepalive_api.c (39)
M src/modules/keepalive/keepalive_core.c (15)
M src/modules/keepalive/keepalive_mod.c (5)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2462.patchhttps://github.com/kamailio/kamailio/pull/2462.diff
--
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/pull/2462
### Description
Applying a simple `{s.prefixes}` transformation on a variable with an empty value crashes Kamailio. It is not specific to a particular SIP message being processed.
### Troubleshooting
#### Reproduction
```
request_route {
$var(empty) = "";
$var(result) = $(var(empty){s.prefixes});
drop;
}
```
#### Debugging Data
```
(paste your debugging data here)
```
#### Log Messages
```
kernel: [27707776.714159] kamailio[13060]: segfault at 562232762ff0 ip 00007f82a1e76391 sp 00007ffc3bc7fcd8 error 4 in libc-2.24.so[7f82a1d4d000+195000]
```
#### SIP Traffic
Any SIP traffic will do, as long as this particular scenario is hit, for whatever reason. Could be buggy business logic.
### Possible Solutions
The only thing I could think of is to place the transformation inside an `if` statement which checks for an empty value of the variable the `{s.prefixes]` transformation is being applied to.
### Additional Information
I've tested this with Kamailio 5.1 and 5.4, and both have this issue.
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.4.0 (x86_64/linux)
version: kamailio 5.1.10 (x86_64/linux)
```
* **Operating System**:
```
Kamailio 5.1.10 -> Debian GNU/Linux 9.13 (stretch)
Kamailio 5.4.0 -> Debian GNU/Linux 9.8 (stretch)
```
--
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/2467
Module: kamailio
Branch: master
Commit: bffd78f14921f67735a64caea2fb130393daa2bc
URL: https://github.com/kamailio/kamailio/commit/bffd78f14921f67735a64caea2fb130…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2020-09-02T14:27:24+02:00
Revert "tls: added define condition on version functions"
This reverts commit 99c6a68dea60ca745dfdfa33085bb6acbcee846a.
---
Modified: src/modules/tls/tls_domain.c
Modified: src/modules/tls/tls_init.c
---
Diff: https://github.com/kamailio/kamailio/commit/bffd78f14921f67735a64caea2fb130…
Patch: https://github.com/kamailio/kamailio/commit/bffd78f14921f67735a64caea2fb130…
---
diff --git a/src/modules/tls/tls_domain.c b/src/modules/tls/tls_domain.c
index 2930bde2be..fc84033e68 100644
--- a/src/modules/tls/tls_domain.c
+++ b/src/modules/tls/tls_domain.c
@@ -63,11 +63,9 @@ static void setup_ecdh(SSL_CTX *ctx)
{
EC_KEY *ecdh;
-#if OPENSSL_VERSION_NUMBER < 0x010100000L
- if (SSLeay() < 0x1000005fL) {
+ if (OpenSSL_version_num() < 0x1000005fL) {
return;
}
-#endif
ecdh = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1);
SSL_CTX_set_options(ctx, SSL_OP_SINGLE_ECDH_USE);
diff --git a/src/modules/tls/tls_init.c b/src/modules/tls/tls_init.c
index f10d0c0344..351ed4187e 100644
--- a/src/modules/tls/tls_init.c
+++ b/src/modules/tls/tls_init.c
@@ -645,7 +645,6 @@ int tls_h_mod_init_f(void)
{
/*struct socket_info* si;*/
long ssl_version;
- const char *ssl_version_txt;
#if OPENSSL_VERSION_NUMBER < 0x010100000L && !defined(LIBRESSL_VERSION_NUMBER)
int lib_kerberos;
int lib_zlib;
@@ -668,15 +667,7 @@ int tls_h_mod_init_f(void)
#if OPENSSL_VERSION_NUMBER < 0x00907000L
LM_WARN("You are using an old version of OpenSSL (< 0.9.7). Upgrade!\n");
#endif
-
-#if OPENSSL_VERSION_NUMBER < 0x010100000L
- ssl_version=SSLeay();
- ssl_version_txt=SSLeay_version(SSLEAY_VERSION);
-#else
ssl_version=OpenSSL_version_num();
- ssl_version_txt=OpenSSL_version(OPENSSL_VERSION);
-#endif
-
/* check if version have the same major minor and fix level
* (e.g. 0.9.8a & 0.9.8c are ok, but 0.9.8 and 0.9.9x are not)
* - values is represented as 0xMMNNFFPPS: major minor fix patch status
@@ -688,7 +679,7 @@ int tls_h_mod_init_f(void)
" compiled \"%s\" (0x%08lx).\n"
" Please make sure a compatible version is used"
" (tls_force_run in kamailio.cfg will override this check)\n",
- ssl_version_txt, ssl_version,
+ OpenSSL_version(OPENSSL_VERSION), ssl_version,
OPENSSL_VERSION_TEXT, (long)OPENSSL_VERSION_NUMBER);
if (cfg_get(tls, tls_cfg, force_run))
LM_WARN("tls_force_run turned on, ignoring "
Module: kamailio
Branch: 5.4
Commit: e7cf0625893125bb45029f6e055ec7910f70d88f
URL: https://github.com/kamailio/kamailio/commit/e7cf0625893125bb45029f6e055ec79…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2020-09-02T14:20:53+02:00
Revert "tls: added define condition on version functions"
This reverts commit 67979e07b63b574687b1924c38fabd724d0ad876.
---
Modified: src/modules/tls/tls_domain.c
Modified: src/modules/tls/tls_init.c
---
Diff: https://github.com/kamailio/kamailio/commit/e7cf0625893125bb45029f6e055ec79…
Patch: https://github.com/kamailio/kamailio/commit/e7cf0625893125bb45029f6e055ec79…
---
diff --git a/src/modules/tls/tls_domain.c b/src/modules/tls/tls_domain.c
index 2930bde2be..fc84033e68 100644
--- a/src/modules/tls/tls_domain.c
+++ b/src/modules/tls/tls_domain.c
@@ -63,11 +63,9 @@ static void setup_ecdh(SSL_CTX *ctx)
{
EC_KEY *ecdh;
-#if OPENSSL_VERSION_NUMBER < 0x010100000L
- if (SSLeay() < 0x1000005fL) {
+ if (OpenSSL_version_num() < 0x1000005fL) {
return;
}
-#endif
ecdh = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1);
SSL_CTX_set_options(ctx, SSL_OP_SINGLE_ECDH_USE);
diff --git a/src/modules/tls/tls_init.c b/src/modules/tls/tls_init.c
index f10d0c0344..351ed4187e 100644
--- a/src/modules/tls/tls_init.c
+++ b/src/modules/tls/tls_init.c
@@ -645,7 +645,6 @@ int tls_h_mod_init_f(void)
{
/*struct socket_info* si;*/
long ssl_version;
- const char *ssl_version_txt;
#if OPENSSL_VERSION_NUMBER < 0x010100000L && !defined(LIBRESSL_VERSION_NUMBER)
int lib_kerberos;
int lib_zlib;
@@ -668,15 +667,7 @@ int tls_h_mod_init_f(void)
#if OPENSSL_VERSION_NUMBER < 0x00907000L
LM_WARN("You are using an old version of OpenSSL (< 0.9.7). Upgrade!\n");
#endif
-
-#if OPENSSL_VERSION_NUMBER < 0x010100000L
- ssl_version=SSLeay();
- ssl_version_txt=SSLeay_version(SSLEAY_VERSION);
-#else
ssl_version=OpenSSL_version_num();
- ssl_version_txt=OpenSSL_version(OPENSSL_VERSION);
-#endif
-
/* check if version have the same major minor and fix level
* (e.g. 0.9.8a & 0.9.8c are ok, but 0.9.8 and 0.9.9x are not)
* - values is represented as 0xMMNNFFPPS: major minor fix patch status
@@ -688,7 +679,7 @@ int tls_h_mod_init_f(void)
" compiled \"%s\" (0x%08lx).\n"
" Please make sure a compatible version is used"
" (tls_force_run in kamailio.cfg will override this check)\n",
- ssl_version_txt, ssl_version,
+ OpenSSL_version(OPENSSL_VERSION), ssl_version,
OPENSSL_VERSION_TEXT, (long)OPENSSL_VERSION_NUMBER);
if (cfg_get(tls, tls_cfg, force_run))
LM_WARN("tls_force_run turned on, ignoring "
Hello,
Kamailio SIP Server v5.4.1 stable release is out.
This is a maintenance release of the latest stable branch, 5.4, that
includes fixes since the release of v5.4.1. There is no change to
database schema or configuration language structure that you have to do
on previous installations of v5.4.x. Deployments running previous v5.4.x
versions are strongly recommended to be upgraded to v5.4.1.
For more details about version 5.4.1 (including links and guidelines to
download the tarball or from GIT repository), visit:
* https://www.kamailio.org/w/2020/09/kamailio-v5-4-1-released/
RPM, Debian/Ubuntu packages will be available soon as well.
Many thanks to all contributing and using Kamailio!
Cheers,
Daniel
--
Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
Hello,
I am considering to release Kamailio v5.4.1 as the first patch release
in the 5.4 series, likely to be done next week, on the 1st of September,
2020. There are a few issues reported on the tracker, hopefully they
will be tackled till then. If you are aware of something else not
working as expected, report them to issue tracker asap to give a better
chance to be fixed till the release day.
Cheers,
Daniel
--
Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
Funding: https://www.paypal.me/dcmierla
Hello,
the schedule for Kamailio World Updates has been published - it is an
online event happening this week, on Wed-Thu, Sep 2-3, 2020, from
13:00UTC to 17:00UTC, more details are available at:
* https://www.kamailioworld.com/k08-online/
The agenda includes presentations, live demos and open discussion
sessions, as well as an online party to celebrate 19 years of
development for Kamailio project. Being shorter than the usual Kamailio
World, the event has an obvious focus on Kamailio only, with sessions
about what is new in Kamailio ecosystem.
The sessions are done live, in a self-hosted Jitsi Meet video
conferencing room (hosting sponsored by lod.com), with live streaming to
YouTube KamailioWorld channel:
* https://www.youtube.com/c/KamailioWorld/
If streaming goes without problems, the recordings of presentations and
live demos will be made available on YouTube channel after the event.
If you want to join the video conferencing room, be sure you are muted
and with video turned off, in order not to disturb the sessions with
unexpected noise. Un-mute/turn video on only when you want to
participate in a discussion.
Asking questions and text discussions can be done on our self hosted
Matrix server, in the room "kamailio" (full room id:
#kamailio:matrix.kamailio.dev):
* https://riot.kamailio.dev/#/room/#kamailio:matrix.kamailio.dev
The server is federated, so if you have a Matrix account on another
server, you can join easily. During the event, we will allow guests to
join the room, so it is not really required to have a Matrix account.
Should anyone have issues joining the chat room during the event, reply
on sr-users and we will try to assist you.
As an alternative for posting questions, I will keep an eye on YouTube
comments during the live streaming and try to pass them to the speaker,
if something pops up there.
The last session on the 2nd day is the online celebration party for 19
years of development for Kamailio project. Grab a drink, prepare your
birthday speech and say it live, tell an interesting story about your
experiences in RTC or just enjoy open discussions with the other
participants!
It is the first time we are experimenting with a live online event,
testing looked good so far and we hope everything will run smooth during
the sessions! Anyhow, I am confident everyone will enjoy the event and
be able to (re-)connect with people from Kamailio community, no matter
where they are located around the world!
Cheers,
Daniel
--
Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda
### Description
In my environment, I use AAAA dns names without A dns records.
When kamailio start, using `tcpdump` I can see only A request and does not see AAAA.
In config file configred
```
dns_cache_flags = 4
```
### Troubleshooting
#### Reproduction
Configure kamailio to use rtpengine servers AAAA dns names. A dns records os not exists.
#### Debugging Data
None
#### Log Messages
None
#### SIP Traffic
None
### Possible Solutions
I do now know
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
[root@ip-172-23-6-136 ~]# kamailio -v
version: kamailio 5.5.0-dev1 (x86_64/linux) d9dd2a
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: d9dd2a
compiled on 04:01:13 Aug 22 2020 with gcc 8.3.1
```
* **Operating System**:
```
[root@ip-172-23-6-136 ~]# cat /etc/os-release
NAME="CentOS Linux"
VERSION="8 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="8"
PLATFORM_ID="platform:el8"
PRETTY_NAME="CentOS Linux 8 (Core)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:8"
HOME_URL="https://www.centos.org/"
BUG_REPORT_URL="https://bugs.centos.org/"
CENTOS_MANTISBT_PROJECT="CentOS-8"
CENTOS_MANTISBT_PROJECT_VERSION="8"
REDHAT_SUPPORT_PRODUCT="centos"
REDHAT_SUPPORT_PRODUCT_VERSION="8"
```
--
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/2458
- URL: https://github.com/kamailio/kamailio/commit/12095fd3948ca776dd2d03b8efa1129…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:53:20+02:00
evapi: export async_unicast() to kemi
- PR #2415
(cherry picked from commit 7116c04c61cf789a371568fb593c109e195a1574)
- URL: https://github.com/kamailio/kamailio/commit/c98d9e8c6687f2311f51016ed9cc2e0…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:53:33+02:00
app_lua: docs - note about availability of 'sr' Lua module
- use KSR in the examples
(cherry picked from commit 34efa83569bedb1f36c3661ee063ff6334633e4a)
- URL: https://github.com/kamailio/kamailio/commit/4aeb071b26df08e1dfc902340475c07…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:53:48+02:00
xcap_server: check before going to the end of the buffer
- use marcros to set and restore char for ending 0
(cherry picked from commit 6ce5c0bdf136ecffd7917f2d60093e1b2c49fa54)
- URL: https://github.com/kamailio/kamailio/commit/aabb2b2cfab6dc664ebc4b3d15db0d2…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:54:03+02:00
db_text: free pointer in case of error
(cherry picked from commit bddf16db74ea779bb01805fc2cbabfdaf8f4d62b)
- URL: https://github.com/kamailio/kamailio/commit/b14b0a116791b85f2048e5fc863e50b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:54:35+02:00
Makefile.defs: get clang version only from --version output
- the full version with stderr output included has a different first
line on MacOS, making head -n 1 not extract the version number line
(cherry picked from commit bff689cfedca70149e17b6ec3584ca9ecab71418)
- URL: https://github.com/kamailio/kamailio/commit/6d79c954469082aeb8518fdcca80217…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:55:09+02:00
Makefile.defs: map gcc v10.x to 9.0+ options
- detect properly the 10.x gcc version number, GH #2425
(cherry picked from commit 79e7738027a40affa4c7f606bf55a3ad0fe31bc4)
- URL: https://github.com/kamailio/kamailio/commit/c783f19708bfd1d8c2334f739c8960b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:55:34+02:00
pike: docs - section for pike.list rpc command
(cherry picked from commit 720e929a87c6d3ee29c316ca63886c7142320f43)
- URL: https://github.com/kamailio/kamailio/commit/c8c884c4db353d4fac83752a494989e…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:56:06+02:00
topoh: check if via param has the expected prefix, otherwise skip
- GH #2437
(cherry picked from commit 046126b4a90090bf5b8f9b517ba5218793e6b973)
- URL: https://github.com/kamailio/kamailio/commit/10af8efa9061c2f52ee1db51c4cf665…
Author: Rosen Penev <rosenp(a)gmail.com>
Date: 2020-08-26T22:56:42+02:00
tls: support compilation without deprecated OpenSSL APIs
- GH #2428
(cherry picked from commit 234b02236b3ad13cdaf5624d11c727ad7d804747)
- URL: https://github.com/kamailio/kamailio/commit/67979e07b63b574687b1924c38fabd7…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:57:02+02:00
tls: added define condition on version functions
- libssl 1.1 variants are not in 1.0
- following the changes by 234b02236b3ad13cdaf5624d11c727ad7d804747
(cherry picked from commit 99c6a68dea60ca745dfdfa33085bb6acbcee846a)
- URL: https://github.com/kamailio/kamailio/commit/0efd0d63a8f8d7b644d0eba13552778…
Author: Dmitry <dmitry.wagin(a)ya.ru>
Date: 2020-08-26T22:57:48+02:00
Makefile.defs: Fixed libs option for FreeBSD
(cherry picked from commit f490c4e0f5888963a01fa99fe94a464d44223199)
- URL: https://github.com/kamailio/kamailio/commit/474d77b8743834a14d00ad285534cf2…
Author: Yufei Tao <yufei.tao(a)syntec.co.uk>
Date: 2020-08-26T22:58:42+02:00
uac: added uac_event_callback for kemi
(cherry picked from commit 767d3ca88a4e4fa093a6a81a36d95d116251b578)
- URL: https://github.com/kamailio/kamailio/commit/daab7955e91c4537547c89eacb7ecd0…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:59:03+02:00
cfgutils: exported route check functions to kemi
(cherry picked from commit ecba550f5d35435adfa9c692cec8cee6cae8a77b)
- URL: https://github.com/kamailio/kamailio/commit/f1d194d0d83f94a495c539436918a09…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:59:13+02:00
core: kemi - exported core route function
(cherry picked from commit d9dd2abeb82be8b992ddf534864b6d84594b7a47)
- URL: https://github.com/kamailio/kamailio/commit/a3763403b22b21974e401929de4ef3f…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:59:30+02:00
keepalive: docs - documented owner parameter for add/delete functions
- related to GH #2438
(cherry picked from commit 7284a61125bb0cacd1adc2289af616061df03258)
- URL: https://github.com/kamailio/kamailio/commit/b5176749605808af737aca00992f549…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-08-26T22:59:57+02:00
topoh: remove the Via cookie when skipping topoh via event route
- event route is now executed with parsed sip message to be sent out
- GH #2437
(cherry picked from commit 06a1d20fdcae42c8f2130c547c6c6cf5fb6dce26)
- URL: https://github.com/kamailio/kamailio/commit/05b4b85b6d977fddfd23b3c556328c5…
Author: Juha Heinanen <jh(a)tutpro.com>
Date: 2020-08-26T23:00:14+02:00
sqlops module: added one more sql query function return value to README
(cherry picked from commit d93de03c10eb7b88024d7eb9ba85200601cf6c7a)
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [ ] Commit message has the format required by CONTRIBUTING guide
- [ ] Commits are split per component (core, individual modules, libs, utils, ...)
- [ ] Each component has a single commit (if not, squash them into one commit)
- [ ] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [ ] Tested changes locally
- [ ] Related to issue #1911
#### Description
<!-- Describe your changes in detail -->
The goal was to have a different, more complex hashing algorithm that would offer a better distribution among nodes. We've seen in production that the current algorithm does not perform well under heavy load therefore we decided to add SHA1 hashing. After running performance tests we've decided that we need a cryptographic function in order to have the best results mostly when the callids have small entropy.
In order to add SHA1, a new API was added in crypto module exporting a function applying SHA1 to a string. The API was used in rtpengine module over the callid. After this operation the hash was calculated as before except for applying 0xFF mask over the hash as it was done before, which restrains the power of this algorithm.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/1986
-- Commit Summary --
* crypto: add exportable API and expose SHA1 hashing function
* rtpengine: use SHA1 over callid for better distribution among nodes
* rtpengine: add modparam to switch between legacy hashing algorithm and SHA1
* rtpengine: update README
-- File Changes --
A src/modules/crypto/api.c (30)
A src/modules/crypto/api.h (63)
M src/modules/crypto/crypto_mod.c (2)
M src/modules/crypto/crypto_uuid.c (34)
M src/modules/crypto/crypto_uuid.h (8)
M src/modules/rtpengine/doc/rtpengine_admin.xml (25)
M src/modules/rtpengine/rtpengine.c (53)
M src/modules/rtpengine/rtpengine.h (1)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/1986.patchhttps://github.com/kamailio/kamailio/pull/1986.diff
--
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/pull/1986
### Description
Add a redis_cmd() call with more than two %s insertions. Kamailio throws parse errors at startup. See below for example and log messages.
### Troubleshooting
This line works fine:
`redis_cmd("kam_redis", "SET %s %s-bar, "test_key", "foo" "r");`
This one does not:
`redis_cmd("kam_redis", "SET %s %s-%s, "test_key", "foo", "bar, "r");`
#### Reproduction
Add a line like this:
`redis_cmd("kam_redis", "SET %s %s-%s, "test_key", "foo", "bar, "r");`
#### Log Messages
```
2020-08-13T16:39:05.468806+00:00,vagrant-ubuntu-xenial-64: CRITICAL: <core> [core/cfg.y:3517]: yyerror_at(): parse error in config file /etc/kamailio/kamailio.cfg, line 424, column 117: Too many arguments
2020-08-13T16:39:05.472800+00:00,vagrant-ubuntu-xenial-64: CRITICAL: <core> [core/cfg.y:3517]: yyerror_at(): parse error in config file /etc/kamailio/kamailio.cfg, line 424, column 117: '('')' expected (function call)
2020-08-13T16:39:05.473289+00:00,vagrant-ubuntu-xenial-64: CRITICAL: <core> [core/cfg.y:3517]: yyerror_at(): parse error in config file /etc/kamailio/kamailio.cfg, line 424, column 117: bad command: missing ';'?
2020-08-13T16:39:05.473927+00:00,vagrant-ubuntu-xenial-64: ERROR: <core> [core/cfg.y:3363]: yyparse(): function used inside params of another function: xlog
2020-08-13T16:39:05.475417+00:00,vagrant-ubuntu-xenial-64: CRITICAL: <core> [core/cfg.y:3517]: yyerror_at(): parse error in config file /etc/kamailio/kamailio.cfg, line 426, column 9: use of function execution inside params not allowed`
```
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.2.7 (x86_64/linux)
flags: STATS: Off, USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144 MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: unknown
compiled with gcc 5.4.0
```
I have confirmed the issue with the available later version packages as well.
* **Operating System**:
Ubuntu 16.04
--
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/2456
README should tell that:
- 1 is returned when query succeeds and result set is not empty
- 2 is returned when query succeeds but result set is not empty
- 3 is returned when result set is not empty, but result param was not given
- -1 is returned in case of error
--
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/2454
Module: kamailio
Branch: master
Commit: d93de03c10eb7b88024d7eb9ba85200601cf6c7a
URL: https://github.com/kamailio/kamailio/commit/d93de03c10eb7b88024d7eb9ba85200…
Author: Juha Heinanen <jh(a)tutpro.com>
Committer: Juha Heinanen <jh(a)tutpro.com>
Date: 2020-08-25T20:11:59+03:00
sqlops module: added one more sql query function return value to README
---
Modified: src/modules/sqlops/doc/sqlops_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/d93de03c10eb7b88024d7eb9ba85200…
Patch: https://github.com/kamailio/kamailio/commit/d93de03c10eb7b88024d7eb9ba85200…
---
diff --git a/src/modules/sqlops/doc/sqlops_admin.xml b/src/modules/sqlops/doc/sqlops_admin.xml
index aaec64f302..671fe79858 100644
--- a/src/modules/sqlops/doc/sqlops_admin.xml
+++ b/src/modules/sqlops/doc/sqlops_admin.xml
@@ -237,6 +237,10 @@ modparam("sqlops", "connect_mode", 1)
<para>
<emphasis>2</emphasis> - query successful, no rows returned
</para>
+ <para>
+ <emphasis>3</emphasis> - query successful, at least one row
+ returned, but result parameter was not given
+ </para>
</listitem>
</itemizedlist>
<section>
### Description
I'm running two kamailio registrars with dmq replication
```
modparam("usrloc", "db_mode", 0)
modparam("usrloc", "use_domain", 1)
loadmodule "dmq.so"
modparam("dmq", "server_address", "sip:own_ip:5062" )
modparam("dmq", "notification_address", "sip:peer_ip:5062")
modparam("dmq", "ping_interval", 15)
modparam("dmq_usrloc", "enable", 1)
modparam("dmq_usrloc", "sync", 1)
modparam("dmq_usrloc", "replicate_socket_info", 1)
modparam("dmq_usrloc", "usrloc_delete", 1)
```
Replication works fine I can see contacts on both registrars. Problem starts when I try to restart one of regsitrars, than another one crashes just after tries to sync with first one.
I did some more investigation and if 1st node starts when he is still in "active" status in DMQ donor node will crash.
```
# kamcmd dmq.list_nodes
{
host: 10.0.210.67
port: 5062
resolved_ip: 10.0.210.67
status: disabled
last_notification: 0
local: 0
}
{
host: 10.0.210.58
port: 5062
resolved_ip: 10.0.210.58
status: active
last_notification: 0
local: 1
}
```
If 1st node will be down for bit longer time (so DMQ marks is as pending) crash will not happen and sync will be successfull.
```
# kamcmd dmq.list_nodes
{
host: 10.0.210.67
port: 5062
resolved_ip: 10.0.210.67
status: pending
last_notification: 0
local: 0
}
{
host: 10.0.210.58
port: 5062
resolved_ip: 10.0.210.58
status: active
last_notification: 0
local: 1
}
```
### Troubleshooting
#### Reproduction
restart one of nodes in time when all cluster members are in active state
#### Debugging Da
```
[root /]# gdb /usr/sbin/kamailio /core.50795
GNU gdb (GDB) Red Hat Enterprise Linux 7.6.1-119.el7
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/sbin/kamailio...Reading symbols from /usr/sbin/kamailio...(no debugging symbols found)...done.
(no debugging symbols found)...done.
[New LWP 50795]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
Core was generated by `/usr/sbin/kamailio -DD -P /run/kamailio/kamailio.pid -f /etc/kamailio/kamailio.'.
Program terminated with signal 11, Segmentation fault.
#0 0x00007f7027eaca38 in usrloc_dmq_send_contact () from /usr/lib64/kamailio/modules/dmq_usrloc.so
Missing separate debuginfos, use: debuginfo-install kamailio-5.4.0-0.el7.centos.x86_64
(gdb) backtrace
#0 0x00007f7027eaca38 in usrloc_dmq_send_contact () from /usr/lib64/kamailio/modules/dmq_usrloc.so
#1 0x00007f7027ea29de in usrloc_get_all_ucontact () from /usr/lib64/kamailio/modules/dmq_usrloc.so
#2 0x00007f7027ea5e3c in usrloc_dmq_execute_action () from /usr/lib64/kamailio/modules/dmq_usrloc.so
#3 0x00007f7027ea8937 in usrloc_dmq_handle_msg () from /usr/lib64/kamailio/modules/dmq_usrloc.so
#4 0x00007f7028c43b88 in worker_loop () from /usr/lib64/kamailio/modules/dmq.so
#5 0x00007f7028c41304 in child_init () from /usr/lib64/kamailio/modules/dmq.so
#6 0x000000000057c313 in init_mod_child ()
#7 0x000000000057bf88 in init_mod_child ()
#8 0x000000000057bf88 in init_mod_child ()
#9 0x000000000057bf88 in init_mod_child ()
#10 0x000000000057bf88 in init_mod_child ()
#11 0x000000000057bf88 in init_mod_child ()
#12 0x000000000057bf88 in init_mod_child ()
#13 0x000000000057cab2 in init_child ()
#14 0x000000000042ab0d in main_loop ()
#15 0x0000000000433a76 in main ()
(gdb) bt full
#0 0x00007f7027eaca38 in usrloc_dmq_send_contact () from /usr/lib64/kamailio/modules/dmq_usrloc.so
No symbol table info available.
#1 0x00007f7027ea29de in usrloc_get_all_ucontact () from /usr/lib64/kamailio/modules/dmq_usrloc.so
No symbol table info available.
#2 0x00007f7027ea5e3c in usrloc_dmq_execute_action () from /usr/lib64/kamailio/modules/dmq_usrloc.so
No symbol table info available.
#3 0x00007f7027ea8937 in usrloc_dmq_handle_msg () from /usr/lib64/kamailio/modules/dmq_usrloc.so
No symbol table info available.
#4 0x00007f7028c43b88 in worker_loop () from /usr/lib64/kamailio/modules/dmq.so
No symbol table info available.
#5 0x00007f7028c41304 in child_init () from /usr/lib64/kamailio/modules/dmq.so
No symbol table info available.
#6 0x000000000057c313 in init_mod_child ()
No symbol table info available.
#7 0x000000000057bf88 in init_mod_child ()
No symbol table info available.
#8 0x000000000057bf88 in init_mod_child ()
No symbol table info available.
#9 0x000000000057bf88 in init_mod_child ()
No symbol table info available.
#10 0x000000000057bf88 in init_mod_child ()
No symbol table info available.
#11 0x000000000057bf88 in init_mod_child ()
No symbol table info available.
#12 0x000000000057bf88 in init_mod_child ()
No symbol table info available.
#13 0x000000000057cab2 in init_child ()
No symbol table info available.
#14 0x000000000042ab0d in main_loop ()
No symbol table info available.
#15 0x0000000000433a76 in main ()
No symbol table info available.
(gdb) quit
[root /]#
```
#### Log Messages
```
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53012]: ALERT: <core> [main.c:777]: handle_sigs(): child process 53050 exited by a signal 11
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53012]: ALERT: <core> [main.c:780]: handle_sigs(): core was not generated
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53012]: INFO: <core> [main.c:802]: handle_sigs(): terminating due to SIGCHLD
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53021]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53014]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53022]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53013]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53023]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53024]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53018]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53028]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53025]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53031]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53026]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53032]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53027]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53035]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53047]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53054]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53038]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53053]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53045]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53057]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53079]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53072]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53033]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53074]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53070]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53077]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53056]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53019]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53036]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53040]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53075]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53043]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53041]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53030]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53020]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53052]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53029]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53015]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53017]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
Aug 20 11:18:08 10.0.210.58 kamailio-dispatcher[53016]: INFO: <core> [main.c:857]: sig_usr(): signal 15 received
```
#### SIP Traffic
### Possible Solutions
shared db sync
### Additional Information
```
# kamailio -v
version: kamailio 5.4.0 (x86_64/linux) 6c4fce
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 6c4fce
compiled on 17:15:32 Jul 29 2020 with gcc 4.8.5
```
* **Operating System**:
```
CentOS Linux release 7.8.2003 (Core)
3.10.0-1127.18.2.el7.x86_64 #1 SMP Sun Jul 26 15:27:06 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
```
--
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/2451
Hello!
There is a ```delete from `location` where `expires`<'XYZ' AND `expires`<>'1970-01-01 03:00:00'``` query that runs before every time when insert, update or delete for location table is executed. The last query from the provided example was unsuccessful before the second last query deleted the corresponding record.
The test was made on the Kamailio v5.4.0. Usrloc module configuration is:
```
modparam("usrloc", "db_url", DATABASE_URL)
modparam("usrloc", "timer_interval", 10)
modparam("usrloc", "db_mode", 2)
modparam("usrloc", "nat_bflag", FLB_NATB)
modparam("usrloc", "db_timer_clean", 1)
```
The test phone I was using - Zoiper softphone updates registration 5 seconds before the expiration. The first registration was at 15:04:43. The following update was at 15:05:38. Following DB queries were executed:
```
529486 Query delete from `location` where `expires`<'2020-08-24 15:04:45' AND `expires`<>'1970-01-01 03:00:00'
529485 Query insert into `location` (`username`,`contact`,`expires`,`q`,`callid`,`cseq`,`flags`,`cflags`,`user_agent`,`received`,`socket`,`last_modified`,`ruid`,`reg_id`,`server_id`,`connection_id`,`keepalive`,`partition` ) values ('300-test','sip:300-test@192.168.0.105:56022;rinstance=5dd76a9c6cb94169;transport=tcp','2020-08-24 15:05:43',-1.000000,'DQzsJiW2Cpjs66s88IkOMQ..',2,0,0,'Z 3.15.40006 rv2.8.20','sip:XXX.XXX.XXX.XXX:56317;transport=tcp','tcp:172.16.30.216:5060','2020-08-24 15:04:43','uloc-5f43acc8-1f59-1',0,0,1,0,0)
529486 Query delete from `location` where `expires`<'2020-08-24 15:04:55' AND `expires`<>'1970-01-01 03:00:00'
529486 Query delete from `location` where `expires`<'2020-08-24 15:05:05' AND `expires`<>'1970-01-01 03:00:00'
529486 Query delete from `location` where `expires`<'2020-08-24 15:05:15' AND `expires`<>'1970-01-01 03:00:00'
529486 Query delete from `location` where `expires`<'2020-08-24 15:05:25' AND `expires`<>'1970-01-01 03:00:00'
529486 Query delete from `location` where `expires`<'2020-08-24 15:05:35' AND `expires`<>'1970-01-01 03:00:00'
529486 Query delete from `location` where `expires`<'2020-08-24 15:05:45' AND `expires`<>'1970-01-01 03:00:00'
529485 Query update `location` set `expires`='2020-08-24 15:06:38',`q`=-1.000000 ,`cseq`=3,`flags`=0,`cflags`=0,`user_agent`='Z 3.15.40006 rv2.8.20',`received`='sip:XXX.XXX.XXX.XXX:56317;transport=tcp',`path`=NULL,`socket`='tcp:172.16.30.216:5060',`methods`=NULL,`last_modified`='2020-08-24 15:05:38',`callid`='DQzsJiW2Cpjs66s88IkOMQ..',`instance`=NULL,`reg_id`=0,`server_id`=0,`connection_id`=1,`keepalive`=0,`contact`='sip:300-test@192.168.0.105:56022;rinstance=5dd76a9c6cb94169;transport=tcp' where `ruid`='uloc-5f43acc8-1f59-1'
```
Reducing timer_interval value to 3 seconds corrected the behavior for me. But is it possible to run ```delete from `location` where `expires`<'XYZ' AND `expires`<>'1970-01-01 03:00:00'``` query not before but after queries that manage particular registrations are executed?
Thank you!
--
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/2455