<!--
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 am uac module with database. uacreg table have the send_socket column. i do have 2 kamailio server running. i want only kamailio-1 should send register to uacreg entries. for this i have used send_socket column with socket of kamailio-1. After this we can see both kamailio server sending registration and that's the problem.
<!--
Explain what you did, what you expected to happen, and what actually happened.
-->
### Troubleshooting
#### Reproduction
loadmodule "uac.so"
modparam("uac","auth_username_avp","$avp(auser)")
modparam("uac","auth_password_avp","$avp(apass)")
modparam("uac","auth_realm_avp","$avp(arealm)")
modparam("uac", "reg_contact_addr", "EXTERNAL_IP:5060")
modparam("uac", "reg_db_url", DBURL)
and use send_socket into uacreg with kamailio-1 socket.
<!--
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.
-->
```
(paste your debugging data here)
```
#### 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).
-->
```
(paste your log messages here)
```
#### 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`
```
version: kamailio 5.3.8 (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, 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: unknown
compiled with gcc 8.3.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`)
-->
```
root@ip-10-0-12-135:/etc/kamailio# uname -a
Linux ip-10-0-12-135 5.3.0-1019-aws #21~18.04.1-Ubuntu SMP Mon May 11 12:33:03 UTC 2020 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/2624
```
which: no lua-config in (/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin)
which: no lua-config in (/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin)
CC (gcc) [M app_lua.so] app_lua_api.o
app_lua_api.c: In function 'lua_sr_kemi_register_libs':
app_lua_api.c:1942:2: warning: implicit declaration of function 'luaL_openlib'; did you mean 'luaL_openlibs'? [-Wimplicit-f
unction-declaration]
1942 | luaL_openlib(L, "KSR", _sr_crt_KSRMethods, 0);
| ^~~~~~~~~~~~
| luaL_openlibs
CC (gcc) [M app_lua.so] app_lua_kemi_export.o
CC (gcc) [M app_lua.so] app_lua_mod.o
LD (gcc) [M app_lua.so] app_lua.so
which: no lua-config in (/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin)
which: no lua-config in (/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin)
CC (gcc) [M app_lua_sr.so] app_lua_sr_api.o
app_lua_sr_api.c: In function 'lua_sr_core_openlibs':
app_lua_sr_api.c:1614:2: warning: implicit declaration of function 'luaL_openlib'; did you mean 'luaL_openlibs'? [-Wimplici
t-function-declaration]
1614 | luaL_openlib(L, "sr", _sr_core_Map, 0);
| ^~~~~~~~~~~~
| luaL_openlibs
CC (gcc) [M app_lua_sr.so] app_lua_sr_exp.o
app_lua_sr_exp.c: In function 'lua_sr_exp_openlibs':
app_lua_sr_exp.c:3686:3: warning: implicit declaration of function 'luaL_openlib'; did you mean 'luaL_openlibs'? [-Wimplici
t-function-declaration]
3686 | luaL_openlib(L, "sr.sl", _sr_sl_Map, 0);
| ^~~~~~~~~~~~
| luaL_openlibs
CC (gcc) [M app_lua_sr.so] app_lua_sr_mod.o
LD (gcc) [M app_lua_sr.so] app_lua_sr.so
```
--
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/2728
Hi there,
I have a weird issue with kamailio (latest docker image kamailio-ci:5.5.2-alpine) and http_async_client.
Before posting a lot of logs, let me describe what I want to achieve.
I have a Kamailio and a SIP Phone.
The SIP phone sends a REGISTER to kamailio, then in my routing block, I check if I have an Authorization header.
Since I don't have an Authorization (first message), I use "www_challenge()".
This replies to the SIP phone, and then the SIP phone sends a new REGISTER with the correct Authorization header.
So far so good.
Now, when I get the REGISTER with Authorization header, I want to ask an HTTP endpoint if this user is allowed to connect and check the password using http_async_query().
The problem is that when the transaction resumes, the tmx module is unhappy and throws this error :
`30(36) CRITICAL: tmx [t_var.c:546]: pv_get_tm_reply_code(): no picked branch (-1) for a final response in MODE_ONFAILURE
`
And a 500 error is sent back to the sip phone.
The AUTH_REPLY route is still called and I can use the $http* values.
it seems that my AUTH_REPLY route is called but considered as a "failure_route"
`19(27) exec: *** cfgtrace:dbg_cfg_trace(): failure_route=[AUTH_REPLY] c=[/etc/kamailio/kamailio.cfg] l=665 a=16 n=if
`
Do you see something that I am doing wrong or missing in my logic?
Is pausing/resuming to use the async http client is allowed if I'm handling a REGISTER transaction?
Here's a simplified version of my routing block (not far from reality):
```
request_route{
route(AUTH);
route[AUTH]{
if (is_method("REGISTER"){
if(no_auth_header){
www_challenge("$td","1");
exit;
}
else{
t_newtran();
http_async_query("http://xxx.xxx.xxx.xxx:9000/auth?foo=bar", "AUTH_REPLY");
}
}
}
route[AUTH_REPLY]{
xlog("L_INFO", "route[HTTP_REPLY]: status $http_rs\n");
}
}
```
Best regards!
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3009
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3009(a)github.com>
Module: kamailio
Branch: 5.5
Commit: d0b14f3e64355aca6c1f0218c804b34b0810c703
URL: https://github.com/kamailio/kamailio/commit/d0b14f3e64355aca6c1f0218c804b34…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2022-01-26T14:01:43+01:00
modules: readme files regenerated - modules ... [skip ci]
---
Modified: src/modules/siputils/README
Modified: src/modules/statsc/README
---
Diff: https://github.com/kamailio/kamailio/commit/d0b14f3e64355aca6c1f0218c804b34…
Patch: https://github.com/kamailio/kamailio/commit/d0b14f3e64355aca6c1f0218c804b34…
---
diff --git a/src/modules/siputils/README b/src/modules/siputils/README
index 87d3ecf9e4..fb4508ebaa 100644
--- a/src/modules/siputils/README
+++ b/src/modules/siputils/README
@@ -452,6 +452,11 @@ modparam("auth", "rpid_avp", "$avp(myrpid)")
timeout value will be converted to a 180 message. Please note that you
need to set a positive timeout value in order to use this function.
+ Note: the change of sip reply can be done only in cases when it is not
+ parsed too much before config execution, otherwise it fails. For
+ example, setting global parameter "log_prefix" can cause this function
+ to fail changing the replies.
+
The function returns TRUE on success, and FALSE during processing
failures.
diff --git a/src/modules/statsc/README b/src/modules/statsc/README
index 2ef41cc72d..d06f3925b2 100644
--- a/src/modules/statsc/README
+++ b/src/modules/statsc/README
@@ -103,6 +103,8 @@ modparam("statsc", "interval", 300)
How many items to store for each statistic.
+ Note: it must be set before any 'track' parameter.
+
Default value is 100.
Example 1.2. Set items parameter