MrDjToto MrDjToto - 1 year ago 176
Java Question

Sip Servlet get SDP content

I need to extrapolate the SDP from a SIP message in a SIP application.
I've tried to do something like:

protected void doInvite(SipServletRequest req) throws ServletException, IOException {
String = req.getContent().toString();

But it doesn't return me the SDP.
Some advices to solve the problem? Thank you!

Answer Source

This usually depends on the Content-Type header but given this is an INVITE I'm assuming the Content-Type is application/sdp. If that's the case, did you try the following ?

String sdp = new String(req.getContent())

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download