[Kamailio-Users] Multipart SDP problem...

Iñaki Baz Castillo ibc at aliax.net
Thu Jun 11 13:04:53 CEST 2009


El Jueves, 11 de Junio de 2009, Juha Heinanen escribió:
> Edson - Lists writes:
>  > Maybe, then, someone could point me to how to disable multipart SDP on
>  > Cisco AS5300 GWs.... I already dig it on Cisco and Google sites, but so
>  > far nothing founded...
>
> instead of disabling multipart in cisco, may be you could use this
> textops function hack that i wrote for the purpose:
>
> 1.3.16.  filter_body(content_type)
>
>    Filters multipart body by leaving out all other body parts
>    except the first body part of given type.
>
>    Meaning of the parameters is as follows:
>      * content_type - Content type to be left in the body.
>
>    This function can be used from REQUEST_ROUTE, ONREPLY_ROUTE,
>    FAILURE_ROUTE, BRANCH_ROUTE.
>
>    Example 1.16. filter_body usage
> ...
> if (has_body("multipart/mixed")) {
>     if (filter_body("application/sdp") {
>         remove_hf("Content-Type");
>         append_hf("Content-Type: application/sdp\r\n");
>     } else {
>         xlog("Body part application/sdp not found\n");
>     }
> }

This is really great!
But, could it create issues? For example, when Cisco device sends a request 
with multipart body, which kinds of body does it include?


-- 
Iñaki Baz Castillo <ibc at aliax.net>




More information about the sr-users mailing list