### Description
If call has ended with BYE after 180/183 before 200 OK, kamailio tries to create new connection to destination, not to use existing.
With firewall enabled and TLS transport this is issue.
### Troubleshooting
#### Reproduction
Load topos module, register client (asterisk, it shows port 5061 in contact but real query comes from random tcp port) using TLS, make call to it, terminate call with BYE, before answering.
#### Log Messages
[kamailio-topos.gz](https://github.com/kamailio/kamailio/files/1505189/kamai…
#### SIP Traffic
[topos-by-befor-ack.tar.gz](https://github.com/kamailio/kamailio/files/15051…
### Additional Information
version: kamailio 5.2.0-dev1 (x86_64/linux)
flags: STATS: Off, USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, 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_LISTEN 16, 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 09:24:06 Nov 27 2017 with gcc 4.8.5
* **Operating System**:
Red Hat Enterprise Linux Server 7.3
3.10.0-514.el7.x86_64 #1 SMP Wed Oct 19 11:24:13 EDT 2016 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/1339
- avoid crash when local-request event route is triggered inside another one
Nested calls to tm:local-routes generate a crash.
I've been recently experiencing this with the following scenario:
- event_route[tm:local-request] defined
- dialog module's send_bye param set to 1
- htable module's enable_dmq param set to 1
When a dialog reaches the timeout, the BYE generated by dialog module triggers the tm:local-request event route. One of the operations done in my scenario is an htable decrement on a table for which dmq replication is enabled. This trigger again the tm event route (because dmq is using tm uac). When the execution of the 2nd route ends the first one is continued, but the sip_msg structure is at this point corrupted because is declared static in t_run_local_req.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/1348
-- Commit Summary --
* tm: make t_run_local_req reentrant
-- File Changes --
M src/modules/tm/uac.c (2)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/1348.patchhttps://github.com/kamailio/kamailio/pull/1348.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/1348
Hello,
I've just installed kamailio 5.1 nightly from the debian repo for stretch.
I didn't change anything in the configuration compared to 5.0.4 (which I
was testing previously), apart from the database structure as found in the
wiki for upgrading from 5.0.x.
Now kamailio crashes after a while, with the following output in the logs:
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 3(2502) ERROR: <core>
[core/udp_server.c:481]: udp_rcv_loop(): print buffer building failed
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 121(2620) CRITICAL: <core>
[core/pass_fd.c:277]: receive_fd(): EOF on 26
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 121(2620) DEBUG: <core>
[core/tcp_main.c:3512]: handle_ser_child(): dead child 3, pid 2502
(shutting down?)
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 121(2620) DEBUG: <core>
[core/io_wait.h:602]: io_watch_del(): DBG: io_watch_del (0x55ae7132ffc0,
26, -1, 0x0) fd_no=126 called
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 0(2499) ALERT: <core>
[main.c:741]: handle_sigs(): child process 2502 exited normally, status=255
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 0(2499) INFO: <core>
[main.c:771]: handle_sigs(): terminating due to SIGCHLD
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 0(2499) DEBUG: <core>
[main.c:773]: handle_sigs(): terminating due to SIGCHLD
Nov 29 15:47:05 modcom-sbc-dev1 kamailio[2497]: 118(2617) INFO: <core>
[main.c:826]: sig_usr(): signal 15 received
Let me know if I can somehow help dissect this issue, I don't really know
where to start. Thanks.
BR,
George
### Description
When kamailio need to pass call from carrier to customer VoIP PBX in docker container on swarm cluster then it not possible.
Network interconnection.
In docker environment eth1 NIC of kamailio and VoIP PBX connected to internet via iptables masquerading. eth1 NIC of kamailio and VoIP PBX have random IP address and generally no way to pass message between kamailio and VoIP PBX via eth1 NIC.
Also both containers have eth0 NIC in same network with static IP. But network on eth0 NIC not connected to Internet.
SIP signaling is passed like
eth1-Kamailio-eth0 <-> eth0-VoIP PBX
In this network kamailio add/removes two Record-Route. For ACK message with two `Route` headers this rule does not work. Each `Route` headers for same kamailio instance and must be translated by one loose_route call
```
The proxy will inspect the URI in the topmost Route header
field value. If it indicates this proxy, the proxy removes it
from the Route header field (this route node has been
reached).
```
Really `Route` headers translated separately and second `loose_route` cannot be completed. Details in `details.txt`
[details.txt](https://github.com/kamailio/kamailio/files/1220872/details.txt)
Wireshark pcap file and kamailio log with enabled debug attached of similar calls is attached.
[full-call.zip](https://github.com/kamailio/kamailio/files/1220875/full-call…
#### Reproduction
Create config when kamailio add two `Record-Route` headers and send ACK with two `Route` headers
--
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/1215
#### 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:
- [X ] PR should be backported to stable branches
- [ ] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
This fixes mtree to be able to contain strings with character
values larger than 0x80. Previously this would not work because
the str.s[i] is 'char' and when cast to 'unsigned int' it would
be first sign extended for maximum range (on systems where 'char'
defaults to signed). E.g. on x86_64 system:
(unsigned int)(char)0x80 = 4294967168
The >=MT_CHAR_TABLE_SIZE test would filter any string containing
these characters out as invalid.
Code is fixed to cast _mt_char_table index to 'unsigned char'
always so index is within range always. The new redundant checks
against MT_CHAR_TABLE_SIZE are removed, and the result is stored
to local variable (and used from it) to improve code readability.
The error message in mt_add_to_tree() is harmonized with the other
messages to show the full string with a problem.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/1343
-- Commit Summary --
* mtree: fix handling of character values >= 0x80
-- File Changes --
M src/modules/mtree/mtree.c (132)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/1343.patchhttps://github.com/kamailio/kamailio/pull/1343.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/1343