[SR-Users] append new a= in SDP (without rtpengine)
Lewis Hutchinson
lewis.hutchinson at missionlabs.co.uk
Thu Apr 14 11:31:43 CEST 2022
After a lot of playing around and fixing a silly mistake I had made I have managed to get it to work however the issue I have is, using:
KSR.textops.replace_body_all("a=record:off", "a=record:on")
KSR.textops.replace_body_str("a=record:off", "a=record:on", "a")
The SDP entry is not replaced but a new one added
v=0
o=ml-live-A 1649898066 1649898067 IN IP4 1.1.1.1
s=ml-live-A
c=IN IP4 1.1.1.1
t=0 0
m=audio 35238 RTP/AVP 8 0 102 9 101 103
a=record:off < ------------------------------------------------------------- Not replaced but left in situ
a=rtpmap:8 PCMA/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:102 opus/48000/2
a=fmtp:102 useinbandfec=1; usedtx=1; maxaveragebitrate=30000; maxplaybackrate=48000; sprop-maxcapturerate=48000; ptime=20; minptime=10; maxptime=40
a=rtpmap:9 G722/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=rtpmap:103 telephone-event/48000
a=fmtp:103 0-15
a=sendrecv
a=rtcp:35239
a=ptime:20
a=record:on < --------------------------------------------------------------- added here
This is still present in the debug log
DEBUG: <core> [core/parser/sdp/sdp.c:599]: parse_sdp_session(): ignoring unknown type in a= line: `a=record:off#015#012a=ptime:20...'
I know I can load SDPOPD and remove the, a=record:off but I am under the impression that it should not be required if TEXTOPS was doing its job properly
Any help is appreciated
Lewis
From: Lewis Hutchinson
Sent: 13 April 2022 16:56
To: sr-users at lists.kamailio.org
Subject: append new a= in SDP (without rtpengine)
version: kamailio 5.5.3
Using KEMI Python
I have read several posts on this and tried several approaches but can not seem to get it to work. As it stands I am trying to add a=record:on | a=record:off | a=record:pause In the SDP because FreeSWITCH creating the INVITE isn't able to do this in the way required. When it is sent from FreeSWITCH a=record:on is send a=record
I have looked at SDPOPS, TEXTOPS and a few others but non of the offer the option to just inject and a= into the SDP body.
So as a result I tried a couple of options where the INVITE is created with a=record (unsure why FreeSWITCH wont let us just add :off etc to the end but that's another point that if anyone know would be helpful) and then using replace_body or search_append_body but the result is TEXTOPS is unable to action the request because of a SDP parse error
DEBUG: <core> [core/parser/sdp/sdp.c:599]: parse_sdp_session(): ignoring unknown type in a= line: `a=record#015#012a=ptime:20...'
Does anyone have any thoughts or tricks on this to give me a few options at ways to handle this?
Lewis
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20220414/3338da61/attachment.htm>
More information about the sr-users
mailing list