Hi,
On 03/14/2008 11:36 AM, Ladislav Andel wrote:
Hi Miklos,
Miklos Tirpak wrote:
Hi Lada,
if SER generates the response:
append_to_reply("Contact: sip:user@host;param=value\r\n");
if SER forwards the response:
(There might be a better way, the following example replaces the whole
header field. And I am not sure that it works correctly with multiple
contact headers.)
assign_hf_value("Contact", "%@contact;param=value");
Where is
the %@contact taken from? Let's say I will always use the same
SIP URI there.
@contact is the value of contact header field of the SIP msg being
processed. So if you put assign_hf_value into onreply_route, than it
returns the contact HF of the reply.
If you need a static value instead, than put there a static value :)
Will the param=value be included in following INVITE
sent from the
client somehow?
The UA parse the Contact in 302 and place it to Request-URI of new
INVITE but where the param=value will be?
Oh, I see. Than you have to make sure that the parameter you insert is a
URI parameter and not a header parameter, so it must be within <>. And
you have to get only the URI of the original contact header field, not
the whole HF value (if you do not use a static value), because the URI
may have been already enclosed in <>:
assign_hf_value("Contact", "<%(a)contact.uri;param=value>")value>");
But you loose the header parameters this way :(
Miklos
thanks,
Lada
>
> Miklos
>
> On 03/14/2008 10:35 AM, Ladislav Andel wrote:
>> Hi all,
>> can I with SER add following in 302 response?
>> 1) add a parameter in Contact header that a UA will read and copy it
>> to the new INVITE and how would I do it in ser config.
>> 2) or add a new header field with in 302 that a UA will read and copy
>> it to the new INVITE
>>
>> The first should be possible as RFC3261 in 20.10 shows in example but
>> I'm wondering if SER can do it too.
>>
>> Thank you,
>> Lada
>> _______________________________________________
>> Serusers mailing list
>> Serusers(a)lists.iptel.org
>>
http://lists.iptel.org/mailman/listinfo/serusers