Hello,
I have kamailio in local network behind NAT. Kamailio have one interface eth1 with ip 10.130.0.23
UserAgent - (internet) - (178.0.0.169)router_NAT - (LAN) - (10.130.0.23)kamailio+rtpproxy - pbx
I made two listeners:
listen=udp:[10.130.0.23:5070](http://10.130.0.23:5070/) #to pbx in lan (I don`t want to put via header with 178.0.0.169)
listen=udp:[10.130.0.23:5060](http://10.130.0.23:5060/) advertise [178.0.0.169:5060](http://178.0.0.169:5060/) #to internet (UserAgent need to get via …
[View More]header with 178.0.0.169 )
mhomed = 1 # I think It not useful for my case
UserAgent send Register and Invite to [178.0.0.169:5060](http://178.0.0.169:5060/), Kamailio get it on udp:[10.130.0.23:5060](http://10.130.0.23:5060/)
Kamailio Relay it to udp:[10.130.0.23:5070](http://10.130.0.23:5070/)
My pbx get requests from udp:[10.130.0.23:5070](http://10.130.0.23:5070/) with via header 10.130.0.23
Responses to UserAgent go from udp:[10.130.0.23:5060](http://10.130.0.23:5060/) with via 178.0.0.169
In RELAY block:
if ($Ru == «udp:10.130.0.23:5070») {
#set_send_socket(«udp:10.130.0.23:5060»);
$fs = «udp:10.130.0.23:5060»;
#force_send_socket(«udp:10.130.0.23:5060»);
} else {
#set_send_socket(«udp:10.130.0.23:5070»);
$fs = «udp:10.130.0.23:5070»;
}
#$fs = «udp:10.130.0.23:5070»;
if (!t_relay()) {
sl_reply_error();
}
route[REGISTRAR] {
...
if ($rd == "[mydomain.ru](http://mydomain.ru/)" || $rd == "[mydomain2.ru](http://mydomain2.ru/)") {
set_send_socket("udp:[10.130.0.23:5070](http://10.130.0.23:5070/)");
add_path();
route(DISPATCH);
}
...
}
It works for requests (INVITE and REGISTER) from UserAgent to PBX thought kamailio. But INVITE from my pbx to UserAgent go out only through udp:10.130.0.23:5070, Kamailio realy it to internet from udp:10.130.0.23:5070
I get error in syslog: (pv [pv_branch.c:62]: pv_get_branchx_helper(): error accessing branch [0])
I tried set_send_socket(«udp:10.130.0.23:5070»); and $fs = «udp:10.130.0.23:5070»;
Why I can`t relay outgoing requests to internet through another socket?
Thank you.
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3173
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3173(a)github.com>
[View Less]
### Description
This issue has already been reported in the past both on GitHub ( Issue #2659 ) and on the [mailing list](https://lists.kamailio.org/pipermail/sr-users/2022-April/114620.html).
We are experiencing some issues with UPDATE messages being sent by the PSTN after an early media announcement.
To reproduce the issue we can call a specific number that has an early media announcement, since it's a paid phone number it has to announce how much it would cost before picking up the call. In …
[View More]this initial part the call is being negotiated in g711a.
As soon as the announcement ends, the PSTN sends an UPDATE message containing the new desired codec (g729) for the actual call.
Kamailio doesn't route the UPDATE message to the destination and it instead replies with a 404 message.
If topos is disabled the update message gets routed correctly.
#### SIP Traffic
I've attached a pcap with anonymized IPs to make it harder for bots.
Here is a legend for the IPs:
- 12.34.123.123 is Kamailio
- 62.23.19.74 is the PSTN
- 1.2.130.40 is the client making the call
[errorupdate_anon.zip](https://github.com/kamailio/kamailio/files/8522365/er…
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
version: kamailio 5.5.4 (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_BLOCKLIST, 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 10.2.1
```
* **Operating System**:
```
Linux 5.10.0-13-amd64 #1 SMP Debian 5.10.106-1 (2022-03-17) x86_64 GNU/Linux
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3090
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3090(a)github.com>
[View Less]
<!--
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…
[View More]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 setting **tos** core parameter to set TOS for sent IP messages but when they leave kamailio i dont the see IP TOS updated via wireshark.
(caller) 192.168.214.125:3030 <-----> (kamailio) 192.168.214.125:7070 <-----> (kamailio) 192.168.214.205:8080
<!--
Explain what you did, what you expected to happen, and what actually happened.
-->
### Troubleshooting
#### Reproduction
```
children=3
listen=udp:192.168.214.125:7070
debug=0
tos=184
```
<!--
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`
```
5.5.4
```
* **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`)
-->
```
(paste your output here)
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3167
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3167(a)github.com>
[View Less]
Hi Team,
We have SSL in mySQL DB.So I need to add configuration in kamailio also.I
am adding the configuration I tried. Please help me to achieve this.Its
little urgent.
My /etc/mysql/my.cnf
[client]
socket = /run/mysqld/mysqld.sock
ssl_key=/var/lib/mysql/Quant-certs/client-key.pem
ssl_cert=/var/lib/mysql/Quant-certs/client_ca_cert.pem
ssl_ca=/var/lib/mysql/Quant-certs/server-ca.pem
#require_secure_transport = ON
[kamailio]
socket = /run/mysqld//mysqld.sock
#require_secure_transport = ON
…
[View More]user = kamailio
password = kamailiorw
host=xxx.xxx.xxx.xxx
default-character-set = utf8
ssl_key=/var/lib/mysql/Quant-certs/client-key.pem
ssl_cert=/var/lib/mysql/Quant-certs/client_ca_cert.pem
ssl_ca=/var/lib/mysql/Quant-certs/server-ca.pem
ssl_verify=1
/etc/kamailio/kamailio.cfg
#!ifndef DBURL
#!define DBURL "mysql://kamailio:kamailiorw@xx.xx.xxx.xxx/kamailio"
#!endif
gateqeeper-kam-dev kamailio[7879]: 0(7879) DEBUG: db_mysql
[km_my_con.c:107]: db_mysql_new_connection(): opening connection:
mysql://xxxx:xxxx@xx.xxx.xx.xxx/kamailio
Jun 27 06:53:12 gateqeeper-kam-dev kamailio[7879]: 0(7879) ERROR: db_mysql
[km_my_con.c:139]: db_mysql_new_connection(): driver error: Access denied
for user 'kamailio'@'xx.xxx.xx.xx' (using password: YES)
Please help me to get it solved.
Thanks & Regards
Jeetha P J
--
_This message contains information that may be privileged or confidential
and is the property of the Quantiphi Inc and/or its affiliates_. It is
intended only for the person to whom it is addressed. _If you are not the
intended recipient, any review, dissemination, distribution, copying,
storage or other use of all or any portion of this message is strictly
prohibited. If you received this message in error, please immediately
notify the sender by reply e-mail and delete this message in its
*entirety*___
[View Less]
<!--
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…
[View More]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.
-->
with the following args
```
--substdefs=/S_KAM_IP_PUBLIC/$KAM_IP_PUBLIC/ \
--substdefs=/S_KAM_SIP_PORT/$KAM_SIP_PORT/
```
error logs when start
```
0(24400) ERROR: <core> [core/ppcfg.c:57]: pp_def_qvalue(): defined value is too large 0 < 15
0(24400) ERROR: <core> [core/ppcfg.c:192]: pp_substdef_add(): failed to enclose in quotes the value
0(24400) ERROR: <core> [main.c:2371]: main(): failed to add substdefs expression: /S_KAM_IP_PUBLIC/192.168.7.8/
```
### Troubleshooting
the first log was reported with this pr
https://github.com/kamailio/kamailio/pull/3151
so looks like `pv_get_buffer_size()` returns `0`, and there looks like nowhere called `pv_set_buffer_size()`.
I can confirm the same args works with the docker image: `kamailio/kamailio-ci:5.4.4-alpine`.
the following config works in `kamailio.cfg`, so only the command line arg has problem.
```
#!substdef "!HOMER_DB_USER!homer_user!g"
#!substdefs "/ID/subst/"
```
#### Reproduction
<!--
If the issue can be reproduced, describe how it can be done.
-->
add the following arg to command line when kamailio start
```
--substdefs=/ID/VALUE/
```
#### 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`
```
(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 `lsb_release -a` and `uname -a`)
-->
```
(paste your output here)
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3152
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3152(a)github.com>
[View Less]