Hello,
What leads you to the conclusion that the
Content-Length: 0
header is "extra", and in need of a "workaround"?
-- Alex
On Tue, Apr 25, 2017 at 12:21:32PM +0000, Pranathi Venkatayogi wrote:
Hi,
How do I eliminate Content-Length:0 from sip reply when using sl_send_reply?
I wanted to generate 200 ok, with SDP payload. I appended headers like below. The
packet seems ok except there is extra "Content-Length:0", which is causing
problems. Any workarounds?
The packet being generated is: Note the extra content-length: 0 at the end.
SIP/2.0 200 OK
Via: SIP/2.0/UDP
10.0.0.12:59404;rport=59404;branch=z9hG4bKPjb7d0391f8f7f479b812f6e5feadfa3c5;received=10.11.200.46
From: "cust1"
<sip:cust1@devtranslation.sms-test.cyracom.com>;tag=afcffa277e2a43dc88fafc612f538864
To:
<sip:spanish@devtranslation.sms-test.cyracom.com>;tag=37b119f34ca40c158c5b7306e1aa8d72.b73a
Call-ID: 7f73e5d03e15425395fac930eae423bd
CSeq: 31419 INVITE
Content-Type: application/sdp
Content-Length: 350
v=0
o=- 3688213899 3688213900 IN IP4 10.99.52.17
s=Blink 1.4.2 (Windows)
t=0 0
m=message 2855 TCP/MSRP *
c=IN IP4 10.99.52.17
a=path:msrps://10.99.52.17:2855/116701522521345;tcp
a=accept-types:message/cpim text/* image/* application/im-iscomposing+xml
a=accept-wrapped-types:text/* image/* application/im-iscomposing+xml
a=setup:active
Content-Length: 0
Code in config is:
append_to_reply("Content-Type: application/sdp\r\n");
append_to_reply("Content-Length: 350\r\n");
append_to_reply("\r\n");
append_to_reply("v=0\r\n");
append_to_reply("o=- 3688213899 3688213900 IN IP4 MY_IP_ADDR\r\n");
append_to_reply("s=Blink 1.4.2 (Windows)\r\n");
append_to_reply("t=0 0\r\n");
append_to_reply("m=message 2855 TCP/MSRP *\r\n");
append_to_reply("c=IN IP4 MY_IP_ADDR\r\n");
append_to_reply("a=path:msrps://MY_IP_ADDR:2855/$var(ssessid);tcp\r\n");
append_to_reply("a=accept-types:message/cpim text/* image/*
application/im-iscomposing+xml\r\n");
append_to_reply("a=accept-wrapped-types:text/* image/*
application/im-iscomposing+xml\r\n");
append_to_reply("a=setup:active\r\n");
sl_send_reply("200", "OK");
Thanks,
Pranathi Venkatayogi
System Developer II
(520) 745-9447 x4466
www.cyracom.com<http://www.cyracom.com/>
Join us: [cid:image001.gif@01D1C9C9.C4E8B6D0]
<https://www.facebook.com/pages/CyraCom-LLC/134704783312720>
[cid:image002.gif@01D1C9C9.C4E8B6D0] <https://twitter.com/cyracom>
[cid:image003.gif@01D1C9C9.C4E8B6D0] <http://www.linkedin.com/company/cyracom>
[cid:image004.gif@01D1C9C9.C4E8B6D0] <http://www.cyracom.com/blog/>
[cid:image005.png@01D1C9C9.C4E8B6D0]
DISCLAIMER: This e-mail and any attached content may contain confidential or privileged
material delivered for the sole use of the intended recipient(s). Any review, use,
distribution or disclosure by others is strictly prohibited. If you are not the intended
recipient (or authorized to receive for the recipient), please contact the sender
immediately by reply e-mail and delete all copies of this message. It is the
recipient's responsibility to scan this e-mail and any attachments for viruses. The
content of this e-mail message, including any attachments, does not comprise a contract or
a portion of a contract, and so does not bind CyraCom International, Inc. or any of its
agents or subsidiaries. CyraCom, LLC and Voiance Language Services, LLC are wholly owned
subsidiaries of CyraCom International, Inc.
_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users(a)lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
--
Alex Balashov | Principal | Evariste Systems LLC
Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free)
Web: