gedia created an issue (kamailio/kamailio#4242)
<!--
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:
* https://lists.kamailio.org/mailman3/postorius/lists/sr-users.lists.kamailio…
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
*…
[View More]https://lists.kamailio.org/mailman3/postorius/lists/sr-dev.lists.kamailio.o…
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
Note that an issue report may be closed automatically after about 2 months
if there is no interest from developers or community users on pursuing it, being
considered expired. In such case, it can be reopened by writing a comment that includes
the token `/notexpired`. About two weeks before considered expired, the issue is
marked with the label `stale`, trying to notify the submitter and everyone else
that might be interested in it. To remove the label `stale`, write a comment that
includes the token `/notstale`. Also, any comment postpone the `expire` timeline,
being considered that there is interest in pursuing 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
This is definitely not high priority, just a nuisance when auditing logs for actionable events.
The following is logged (see Log Messages section below) on edge proxies when the outbound module is loaded and the REGISTER contains:
```
Contact: *
Expires: 0
```
AFAIK this is legit when a UAC asks that all their contacts be removed from the location database.
### Troubleshooting
#### Reproduction
Force a UAC to send an unREGISTER towards an outbound-capable kamailio edge proxy.
#### Log Messages
```
outbound [outbound_mod.c:325]: use_outbound_register(): empty Contact:
```
#### 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).
-->
See description
### Possible Solutions
<!--
If you found a solution or workaround for the issue, describe it. Ideally, provide a pull request with a fix.
-->
I'm not sure what the best approach would be here, but I'm thinking one of the following:
* Either handle this case gracefully (contact is * in REGISTER with Expires=0), without logging anything, unless there's some misbehaviour here by the UAC I'm not aware of regarding outbound and unREGISTER behaviour
* Or, log this in a more verbose level (e.g. debug), when contact parsing fails due to it being set to '*'
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.8.6 (x86_64/linux)
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, MEM_JOIN_FREE, 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_BLOCKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_SEND_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 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 `lsb_release -a` and `uname -a`)
-->
```
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 11 (bullseye)
Release: 11
Codename: bullseye
Linux lbpub0-tis0-cn1 5.10.0-21-amd64 #1 SMP Debian 5.10.162-1 (2023-01-21) x86_64 GNU/Linux
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4242
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/4242(a)github.com>
[View Less]
<!-- 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, …
[View More]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
- [ ] Tested changes locally
- [x] Related to issue #4242
#### Description
<!-- Describe your changes in detail -->
This PR fixes the invalid case of empy Contact.
Contact:* and expires:0 is valid and should be handled accordingly.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/4279
-- Commit Summary --
* outbound: Use outbound if Register contains Contacts:* and Expires:0
-- File Changes --
M src/modules/outbound/outbound_mod.c (9)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/4279.patchhttps://github.com/kamailio/kamailio/pull/4279.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/4279
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/4279(a)github.com>
[View Less]
giangi created an issue (kamailio/kamailio#4236)
### Description
The mode flag value 16 (int) in `ds_is_from_list()` is supposed to provide a "best matching" candidate, however it does not seem to recognize anything other than exact matches.
### Troubleshooting
#### Reproduction
With the following `dispatcher.list`
```
# setid(int) destination(sip uri) flags(int,opt) priority(int,opt) attributes(str,opt)
1 sip:127.1.2.3:5060
1 sip:127.1.2.3:5060;transport=tcp
```
The following …
[View More]invocations result in a match
```
ds_is_from_list("-1", "16", "sip:127.1.2.3:5060");
ds_is_from_list("-1", "16", "sip:127.1.2.3:5060;transport=tcp");
```
while others, e.g. some with some mismatching ports, but a valid address, fail to match
```
ds_is_from_list("-1", "16", "sip:127.1.2.3:12345");
ds_is_from_list("-1", "16", "sip:127.1.2.3:12345;transport=tcp");
```
### Possible Solutions
The code of `ds_is_addr_from_set()` from `src/modules/dispatcher/dispatch.c` has some suspicious `continue` while evaluating the "strictness score" of nodes and deciding upon the best match. If I am not mistaken they may cause the code that updates the `ds_strictest_node` to never get executed, thus not providing any match at all.
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.8.6 (x86_64/linux)
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, MEM_JOIN_FREE, 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_BLOCKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_SEND_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 12.2.0
```
* **Operating System**: Debian 12 "bookworm"
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4236
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/4236(a)github.com>
[View Less]
Serg1289 created an issue (kamailio/kamailio#4285)
In case of event below, script execution takes too much time (40 sec):
_event_route[dispatcher:dst-down] {
exec_msg("/bin/bash -c '/usr/local/etc/kamailio/ipassign.sh &'");
}_
In case I run this script from shell it takes ~2 sec.
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4285
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/4285(a)github.com>
sergey-safarov created an issue (kamailio/kamailio#4264)
On `alpine:edge` upgraded `libjwt-dev` from `1.17.2-r0` to `3.2.1-r0` and on now present this error in the build log.
```
make[2]: --libs: No such file or directory
make[2]: --libs: No such file or directory
CC (cc) [M jwt.so] jwt_mod.o
jwt_mod.c: In function 'ki_jwt_generate_hdrs':
jwt_mod.c:215:17: error: implicit declaration of function 'jwt_free_str'; did you mean 'jwt_alg_str'? [-Wimplicit-function-declaration]
215 | …
[View More] jwt_free_str(_jwt_result.s);
| ^~~~~~~~~~~~
| jwt_alg_str
jwt_mod.c:275:15: error: implicit declaration of function 'jwt_new' [-Wimplicit-function-declaration]
275 | ret = jwt_new(&jwt);
| ^~~~~~~
jwt_mod.c:283:15: error: implicit declaration of function 'jwt_add_grant_int' [-Wimplicit-function-declaration]
283 | ret = jwt_add_grant_int(jwt, "iat", iat);
| ^~~~~~~~~~~~~~~~~
jwt_mod.c:293:39: error: implicit declaration of function 'jwt_add_grant' [-Wimplicit-function-declaration]
293 | ret = jwt_add_grant(jwt, pit->name.s, pit->body.s);
| ^~~~~~~~~~~~~
jwt_mod.c:311:39: error: implicit declaration of function 'jwt_add_header' [-Wimplicit-function-declaration]
311 | ret = jwt_add_header(jwt, header->name.s, header->body.s);
| ^~~~~~~~~~~~~~
jwt_mod.c:313:39: error: implicit declaration of function 'jwt_add_header_int'; did you mean 'jwt_header_get'? [-Wimplicit-function-declaration]
313 | ret = jwt_add_header_int(jwt, header->name.s, lval);
| ^~~~~~~~~~~~~~~~~~
| jwt_header_get
jwt_mod.c:324:15: error: implicit declaration of function 'jwt_set_alg'; did you mean 'jwt_get_alg'? [-Wimplicit-function-declaration]
324 | ret = jwt_set_alg(jwt, valg, (unsigned char *)kdata.s, (size_t)kdata.len);
| ^~~~~~~~~~~
| jwt_get_alg
jwt_mod.c:330:25: error: implicit declaration of function 'jwt_encode_str' [-Wimplicit-function-declaration]
330 | _jwt_result.s = jwt_encode_str(jwt);
| ^~~~~~~~~~~~~~
jwt_mod.c:330:23: error: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
330 | _jwt_result.s = jwt_encode_str(jwt);
| ^
jwt_mod.c:337:9: error: implicit declaration of function 'jwt_free'; did you mean 'jwks_free'? [-Wimplicit-function-declaration]
337 | jwt_free(jwt);
| ^~~~~~~~
| jwks_free
jwt_mod.c: In function 'ki_jwt_verify_key':
jwt_mod.c:443:9: error: unknown type name 'jwt_valid_t'; did you mean 'jwt_value_t'?
443 | jwt_valid_t *jwt_valid = NULL;
| ^~~~~~~~~~~
| jwt_value_t
jwt_mod.c:477:15: error: implicit declaration of function 'jwt_valid_new' [-Wimplicit-function-declaration]
477 | ret = jwt_valid_new(&jwt_valid, valg);
| ^~~~~~~~~~~~~
jwt_mod.c:484:9: error: implicit declaration of function 'jwt_valid_set_headers' [-Wimplicit-function-declaration]
484 | jwt_valid_set_headers(jwt_valid, 1);
| ^~~~~~~~~~~~~~~~~~~~~
jwt_mod.c:485:9: error: implicit declaration of function 'jwt_valid_set_now' [-Wimplicit-function-declaration]
485 | jwt_valid_set_now(jwt_valid, iat);
| ^~~~~~~~~~~~~~~~~
jwt_mod.c:492:39: error: implicit declaration of function 'jwt_valid_add_grant' [-Wimplicit-function-declaration]
492 | ret = jwt_valid_add_grant(jwt_valid, pit->name.s, pit->body.s);
| ^~~~~~~~~~~~~~~~~~~
jwt_mod.c:494:39: error: implicit declaration of function 'jwt_valid_add_grant_int' [-Wimplicit-function-declaration]
494 | ret = jwt_valid_add_grant_int(jwt_valid, pit->name.s, lval);
| ^~~~~~~~~~~~~~~~~~~~~~~
jwt_mod.c:505:15: error: implicit declaration of function 'jwt_decode' [-Wimplicit-function-declaration]
505 | ret = jwt_decode(
| ^~~~~~~~~~
jwt_mod.c:511:22: error: implicit declaration of function 'jwt_validate' [-Wimplicit-function-declaration]
511 | if((jwtret = jwt_validate(jwt, jwt_valid)) != JWT_VALIDATION_SUCCESS) {
| ^~~~~~~~~~~~
jwt_mod.c:511:55: error: 'JWT_VALIDATION_SUCCESS' undeclared (first use in this function)
511 | if((jwtret = jwt_validate(jwt, jwt_valid)) != JWT_VALIDATION_SUCCESS) {
| ^~~~~~~~~~~~~~~~~~~~~~
jwt_mod.c:511:55: note: each undeclared identifier is reported only once for each function it appears in
jwt_mod.c:512:38: error: implicit declaration of function 'jwt_valid_get_status' [-Wimplicit-function-declaration]
512 | _jwt_verify_status = jwt_valid_get_status(jwt_valid);
| ^~~~~~~~~~~~~~~~~~~~
jwt_mod.c:521:9: error: implicit declaration of function 'jwt_valid_free'; did you mean 'jwt_builder_free'? [-Wimplicit-function-declaration]
521 | jwt_valid_free(jwt_valid);
| ^~~~~~~~~~~~~~
| jwt_builder_free
make[2]: *** [../../Makefile.rules:100: jwt_mod.o] Error 1
make[1]: *** [Makefile:509: modules] Error 1
make[1]: Leaving directory '/usr/src/kamailio/pkg/kamailio/alpine/src/kamailio-78541805e73f1ca2a220e84734090ebd606bc5e4/src'
make: *** [Makefile:34: all] Error 2
>>> ERROR: kamailio: build failed
>>> kamailio: Uninstalling dependencies...
(1/1) Purging .makedepends-kamailio (20250527.180[501](https://github.com/sergey-safarov/kamailio/actions/runs/1…)
OK: 1028 MiB in 240 packages
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4264
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/4264(a)github.com>
[View Less]
### Description
Hi!
We are in the progress of upgrading from Kamailio 5.5 to 5.8. During our testing we have noticed a new error being reported from Kamailio. We don’t see any other errors following it.
```jsx
/usr/sbin/kamailio[201]: CRITICAL: <core> [core/tcp_main.c:5544]: tcp_timer_check_connections(): message processing timeout on connection id: 67896 (state: 3) - closing
```
It does seem to be [new code](https://github.com/kamailio/kamailio/blob/master/src/core/tcp_main.c#… in …
[View More]Kamailio reporting this issue.
Given that this is a fairly expected thing, cleaning up a connection which receives no traffic within the given time, is there a need for it to be reported on CRITICAL?
I’d also expect it to be caught by
```
event_route[tcp:timeout] {
xlog("L_INFO","connection $conid timeouts (unanswered keepalives)");
}
```
given that [the description](https://www.kamailio.org/docs/modules/stable/modules/tcpops.ht… of this one is `Called for connection timeouts (unanswered keepalives).`.
### Troubleshooting
We don't have any way to reproduce it, we are still investigating it to figure out the cause. It happens around every 2 hours, so we think there might some some scheduled test or job running in our test system causing this.
### Additional Information
* **Kamailio Version** - 5.8.3
* **Operating System**: Debian 12 AMI from the AWS Marketplace.
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3995
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3995(a)github.com>
[View Less]
Module: kamailio
Branch: master
Commit: 36c466bce5a57df72806a0915361612c32cc838e
URL: https://github.com/kamailio/kamailio/commit/36c466bce5a57df72806a0915361612…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2025-06-13T09:26:17+02:00
jwt: added to the notes about libjwt versions
- module is not compatible with the new libjwt3
---
Modified: src/modules/jwt/doc/jwt_admin.xml
---
Diff: https://github.com/…
[View More]kamailio/kamailio/commit/36c466bce5a57df72806a0915361612…
Patch: https://github.com/kamailio/kamailio/commit/36c466bce5a57df72806a0915361612…
---
diff --git a/src/modules/jwt/doc/jwt_admin.xml b/src/modules/jwt/doc/jwt_admin.xml
index 5389bb61f30..4aecc4d0a8b 100644
--- a/src/modules/jwt/doc/jwt_admin.xml
+++ b/src/modules/jwt/doc/jwt_admin.xml
@@ -20,7 +20,8 @@
in &kamailio; configuration file.
</para>
<para>
- It relies on libjwt (at least v1.12.0) library (https://github.com/benmcollins/libjwt).
+ It relies on libjwt (at least v1.12.0) library (https://github.com/benmcollins/libjwt),
+ but it is not working with the new libjwt3.
</para>
</section>
@@ -47,7 +48,8 @@
<itemizedlist>
<listitem>
<para>
- <emphasis>libjwt</emphasis> - minimum version 1.12.0.
+ <emphasis>libjwt</emphasis> - minimum version 1.12.0, but less
+ than libjwt 3.0.
</para>
</listitem>
</itemizedlist>
[View Less]
whosgonna created an issue (kamailio/kamailio#4283)
### Description
Using function `sht_setxi()` causes the script to exit and stop processing messages. Using the example from the documention:
```
#!KAMAILIO
loadmodule "pv"
loadmodule "ctl"
loadmodule "htable"
loadmodule "xlog"
modparam("htable", "htable", "ha=>size=4");
request_route {
xnotice("Request received [$ru]\n"); ## this prints
sht_setxi("ha", "test", "100", "10"); ## exactly as documented
xnotice("log …
[View More]line after sht_setxi()\n"); ## This does not print.
}
```
### Troubleshooting
As shown above. Note that the similar function `sht_setxs()` (for setting string values) works as expected.
#### Reproduction
Trivial to reproduce.
#### SIP Traffic
Tested from localhost with `sipsak -s sip:127.0.0.1`, but any message seems to do this.
### Possible Solutions
I believe that the issue is in [`/src/modules/htable/htable.c`](/src/modules/htable/htable.c) within function `static int ki_ht_setxi()` where the return is `0` (last line in the function). I'm guessing it should return `1`, like ``static int ki_ht_setxs()` (sting function equivilent)
### Additional Information
Tested in 6.0.1 and 5.8.5
```
version: kamailio 6.0.1 (x86_64/linux)
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, MEM_JOIN_FREE, 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_BLOCKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_SEND_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 12.2.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 `lsb_release -a` and `uname -a`)
-->
```
version: kamailio 5.8.5 (x86_64/linux)
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, MEM_JOIN_FREE, 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_BLOCKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_SEND_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 on 19:38:35 Jan 30 2025 with gcc 14.2.0
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4283
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/4283(a)github.com>
[View Less]
#### 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 …
[View More]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 #4249
#### Description
When sending an INVITE using t_uac_send, the transaction layer automatically generates ACK on final response. However this ack doesn't invoke the tm:local-request callback. This patch adds this functionality
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/4250
-- Commit Summary --
* tm: invoke tm:local-request on generated ACK messages
-- File Changes --
M src/modules/tm/uac.c (127)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/4250.patchhttps://github.com/kamailio/kamailio/pull/4250.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/4250
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/4250(a)github.com>
[View Less]
tianhao98 created an issue (kamailio/kamailio#4237)
### Description
I used the xhttp module to add a fake Via header to handle HTTP requests in Kamailio. But it will produce the following error
```
104(113) ERROR: <core> [core/parser/parse_uri.c:1417]: _parse_ruri(): bad uri </metrics>
104(113) ERROR: <core> [core/parser/parse_uri.c:1455]: parse_orig_ruri(): parse orig ruri failed
104(113) ERROR: pv [pv_core.c:355]: pv_get_ouri_attr(): failed to parse the R-URI
```
### …
[View More]Troubleshooting
#### Debugging Data
Set up a Kamailio server with the xhttp module enabled.
```
loadmodule "xhttp.so"
```
#### Log Messages
```
104(113) ERROR: <core> [core/parser/parse_uri.c:1417]: _parse_ruri(): bad uri </metrics>
104(113) ERROR: <core> [core/parser/parse_uri.c:1455]: parse_orig_ruri(): parse orig ruri failed
104(113) ERROR: pv [pv_core.c:355]: pv_get_ouri_attr(): failed to parse the R-URI
```
#### SIP Traffic
N/A — this is a pure HTTP request triggering the SIP parser.
### Additional Information
```
root@kamailio-60-bot-67d564c54c-xj97x:/# kamailio -V
version: kamailio 6.0.1 (x86_64/linux)
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, MEM_JOIN_FREE, 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_BLOCKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_SEND_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 8.3.0
```
* **Operating System**:
```
root@kamailio-60-bot-67d564c54c-xj97x:/# uname -a
Linux kamailio-60-bot-67d564c54c-xj97x 5.4.119-19.0009.28 #1 SMP Thu May 18 10:37:10 CST 2023 x86_64 GNU/Linux
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4237
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/4237(a)github.com>
[View Less]
sergey-safarov created an issue (kamailio/kamailio#4257)
### Description
We found a memory leak in the AVP cleanup
### Troubleshooting
#### Reproduction
To reproduce, you need to start Kaamilio 5.8 branch with the config
```
listen=127.0.0.1:5060
tcp_send_timeout=3
loadmodule "xlog.so"
loadmodule "kex.so"
loadmodule "pv.so"
loadmodule "ctl.so"
loadmodule "jsonrpcs.so"
loadmodule "tm.so"
loadmodule "siptrace.so"
modparam("siptrace", "trace_to_database", 0)
modparam("siptrace", "trace_on",…
[View More] 1)
modparam("siptrace", "trace_mode", 1)
modparam("siptrace", "trace_init_mode", 1)
loadmodule "permissions.so"
modparam("permissions", "address_file", "address.list")
modparam("permissions", "peer_tag_avp", "$avp(s:tag)")
modparam("permissions", "peer_tag_mode", 0)
modparam("permissions", "load_backends", 1)
modparam("permissions", "reload_delta", 1)
loadmodule "dispatcher.so"
modparam("dispatcher", "list_file", "/tmp/dispatcher.list")
modparam("dispatcher", "ds_ping_from", "sip:proxy@aggregator.nga911.com")
modparam("dispatcher", "ds_ping_interval", 3)
modparam("dispatcher", "ds_probing_mode", 1)
route{
drop;
}
event_route[siptrace:msg] {
if (allow_address("1", "$siptrace(src_hostip)", "0")) {
xerr("SIP message from $siptrace(src_hostip)\n");
}
}
```
Also need to create `address.list` with content
```
# address file - records to match with allow_address(...) and variants
# * file format details
# - comments start with # and go to end of line
# - each line corresponds to a record with following attributes:
#
# (groupid,int) (address,str) (netmask,int,o), (port,int,o) (tag,str,o)
#
# * description of the tokens used to describe line format
# - int: expected integer value
# - str: expected string value
# - o: optional field
1 127.0.0.0 16 0 tag
```
and `/tmp/dispatcher.list` with content
```
1 sip:sip.telnyx.com:5060;transport=tcp 8
```
When kamailio started required to execute a command
```
kamcmd mod.stats core shm| grep avp
```
This will produce output like
```
create_avp(178): 1360
init_avps(92): 16
init_avps(91): 16
```
Where `create_avp` is constantly increasing
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4257
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/4257(a)github.com>
[View Less]
<!-- 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, …
[View More]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 #4257
#### Description
When the dispatcher module sends ping requests then these requests are executed in a dedicated process, which handles timers and called `slow timer`. If during this ping request AVP variables are allocated, then these vars are allocated within `slow timer` process and this memory is never released and continiously accumulates in/by this process.
This change makes AVP vars being reset for every iteration of the `dispatcher` timer procedure (`ds_check_timer` function).
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/4258
-- Commit Summary --
* dispatcher: fixed memory leak when avp is indirectly used
-- File Changes --
M src/modules/dispatcher/dispatch.c (1)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/4258.patchhttps://github.com/kamailio/kamailio/pull/4258.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/4258
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/4258(a)github.com>
[View Less]