Hello
I am using SER in a test environment as a proxy server. I would like it to add additional fields in the SDP of an INVITE message for some test needs. (e.g. add 'a=sendonly').
Is it possible ?
If not possible, do you think it would be difficult to add a function addSdp(<string>) that would append a given string to the SDP of the current message and alter the 'content_length' header field ?
I do not see in the 'sip_msg' structure any pointer to the body part of the message ; only pointers to header fields.
Thanks for you help
ser has been designed for use as a proxy server, i.e. a device which is ignorant of payloads. That's a feature, not a bug. Adding a support to change SDP should be easy, though.
You would need to find the body (I think the SMS gateway uses some function to distill the body -- Bogdan would give you a hint) and modify it. actions in textops module are best examples how to change message. 'replace' changes parts of a message matching a regular expression, append_hf appends a header field. Remember that when you change SDP, you need to change Content-length too.
-Jiri
At 04:06 PM 1/10/2003, David.Rio@alcatel.fr wrote:
Hello
I am using SER in a test environment as a proxy server. I would like it to add additional fields in the SDP of an INVITE message for some test needs. (e.g. add 'a=sendonly').
Is it possible ?
If not possible, do you think it would be difficult to add a function addSdp(<string>) that would append a given string to the SDP of the current message and alter the 'content_length' header field ?
I do not see in the 'sip_msg' structure any pointer to the body part of the message ; only pointers to header fields.
Thanks for you help
-- David Rio Alcatel CIT - Rennes ASD France 33 2 99 87 47 18
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
-- Jiri Kuthan http://iptel.org/~jiri/