[Serusers] SER and SIP headers

Jan Janak jan at iptel.org
Mon Mar 8 18:55:46 CET 2004


I know how IMS Path header field works. If you want to do something like
this then you will need to write a new module. A lot of code from rr
module could be reused, the tricky part would be storing this
information in usrloc (it is possible but requires more coding).

 Jan.

On 08-03 18:25, Curro wrote:
> Thanks Andrei and Jan for your answers.
> 
> I see that it is not easy to do this with SER. I wanted to do this with
> headers to construct a header which indicates the user agent which Route
> it should follow. I'll try to explain it better. The idea is based on
> IMS standard. Proxies on the way add theirselves to a Path header. When
> the response to a request come back to the UA, it takes the Path header
> and creates a Route header dynamic(used at SIP Proxies which act as
> loose router).
> 
> What I really want is use Route header in my UA to test loose router
> function. Do you know any other way to do this?
> 
> Thanks.
> Regards, 
> Curro
> 
> On Mon, 2004-03-08 at 13:23, Andrei Pelinescu-Onciul wrote:
> > On Mar 08, 2004 at 11:51, Curro <curro_dominguez at terra.es> wrote:
> > > 
> > > Hello
> > > 
> > > I would like to ask the list some questions about headers. I've been
> > > reading the list and textops module, but I haven't found how to do this.
> > > 
> > > Imagine a scenario with 2 SER proxies. The first proxy adds a header
> > > like: 
> > > Path: <....>
> > > 
> > > 1 )How can the second proxy add a parameter to this header (and not a
> > > new header)? The result that I'm looking for is something like:
> > > 
> > > Path: <....>,<....>
> > > 
> > > 
> > > 2 ) I know that SER can check whether a header is
> > > present(is_present_hf()), but is it possible to extract the information
> > > of a header and use it? I can't use search() function, because I don't
> > > know the information, just the header name. I need to read some
> > > parameters from a header of a SIP message to construct a new header. 
> > > 
> > 
> > You could try subst() from textops (it might be documented only in the
> > sgml in textops/doc). You have a special escape: \u which will expand to
> > the message uri, but if you want something else than the uri, you are
> > out of luck :-)
> > E.g.:
> > subst('/^(Path:.*)$/\1,uri=\u'); 
> > will add  uri=<msg_uri> to your Path header.
> > 
> > Andrei
> 
> 
> _______________________________________________
> Serusers mailing list
> serusers at lists.iptel.org
> http://lists.iptel.org/mailman/listinfo/serusers




More information about the sr-users mailing list