Skip to content

[CRASH] Using TCP traffic  #2458

@adigeo

Description

@adigeo

OpenSIPS version you are running

version: opensips 3.1.1 (x86_64/linux)
flags: STATS: On, DISABLE_NAGLE, USE_MCAST, SHM_MMAP, Q_MALLOC, F_MALLOC, HP_MALLOC, DBG_MALLOC, FAST_LOCK-ADAPTIVE_WAIT
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535
poll method support: poll, epoll, sigio_rt, select.
git revision: 7ce3a4688
main.c compiled on  with gcc 8

Crash Core Dump
agp@live01:~$ sudo gdb /usr/sbin/opensips /cores/core.8812.opensips.1617699922
GNU gdb (Debian 8.2.1-2+b3) 8.2.1

Reading symbols from /usr/sbin/opensips...Reading symbols from /usr/lib/debug/.build-id/82/e390634b674192db657b546b1bf9603d7f7f74.debug...done.
done.
[New LWP 8812]
[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/sbin/opensips -w /run/opensips -P opensips.pid -a F_MALLOC_DBG -m 2048'.
Program terminated with signal SIGABRT, Aborted.
#0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
50 ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) bt
#0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#1 0x00007fefe06ba535 in __GI_abort () at abort.c:79
#2 0x000055b4f9fc2c9e in build_res_buf_from_sip_res (msg=msg@entry=0x55b4faaa3850, returned_len=returned_len@entry=0x7ffe921e8f04,
sock=, flags=flags@entry=0) at msg_translator.c:2419
#3 0x00007fef5f5e0a2d in relay_reply (t=0x7fef6244ff38, p_msg=, branch=0, msg_status=200, cancel_bitmap=0x7ffe921e8ff4)
at t_reply.c:1282
#4 0x00007fef5f5e2fad in reply_received (p_msg=0x55b4faaa3850) at t_reply.c:1647
#5 0x000055b4f9ff4438 in forward_reply (msg=msg@entry=0x55b4faaa3850) at forward.c:499
#6 0x000055b4f9fdd027 in receive_msg (
buf=0x55b4fab0db70 "SIP/2.0 200 Answering\r\nRecord-Route: sip:81.23.228.180;transport=tcp;lr;ftag=qpgpaa4f;did=58.e1a04a36\r\nVia: SIP/2.0/TCP 81.23.228.180:5060;branch=z9hG4bK9b09.9fe768.0;i=0228483\r\nVia: SIP/2.0/TCP 194"..., len=, len@entry=1541,
rcv_info=rcv_info@entry=0x7ffe921e9260, existing_context=existing_context@entry=0x0, msg_flags=msg_flags@entry=0) at receive.c:266
#7 0x000055b4fa141785 in tcp_handle_req (_max_msg_chunks=, con=0x7fef61e200f8, req=0x55b4fab0db70)
at net/proto_tcp/tcp_common.h:411
#8 tcp_read_req (con=, bytes_read=0x7ffe921e9320) at net/proto_tcp/proto_tcp.c:1197
#9 0x000055b4fa12185a in handle_io (fm=, idx=idx@entry=25, event_type=event_type@entry=1) at net/net_tcp_proc.c:312
#10 0x000055b4fa123b91 in io_wait_loop_epoll (h=, t=, repeat=) at net/../io_wait_loop.h:305
#11 tcp_worker_proc_loop () at net/net_tcp_proc.c:422
#12 0x000055b4fa133eab in tcp_start_processes (chd_rank=chd_rank@entry=0x55b4fa3135a8 <chd_rank>, startup_done=startup_done@entry=0x7fef61b686c8)
at net/net_tcp.c:2088
#13 0x000055b4f9fb2813 in main_loop () at main.c:810
#14 main (argc=, argv=) at main.c:1491

Describe the traffic that generated the bug

To Reproduce

Relevant System Logs

OS/environment information

  • Operating System: `Debian Buster
  • OpenSIPS installation:
  • other relevant information:

Additional context

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions