I agree with Brett.
I will add that you can be over zealous in your checking.
You didn't mention *which* Via header was bothering you.
Its important to you that the *topmost* Via header be well formed enough
for you to use it to construct a response.
It is *not your problem* of some other Via header appears malformed to
you. Presumably it wasn't malformed enough to bother the server that
will need to use it. So in this case you would be well advised to ignore
this.
Thanks,
Paul
On 3/12/12 8:34 AM, Brett Tate wrote:
>> UAS receives an INVITE request withh invalid Via Header,
>> while parsing we found that syntax of Via is wrong so
>> UAS decided to send 4xx response& not concentrated on
>> rest of header values.
>
> Sometimes a request is too malformed to bother sending a 400 response. The
> following are some of the mandatory headers which would cause a 400 if they
> were missing: Via, To, From, Call-ID, and CSeq. However if you sent the 400
> response, it would also be malformed and might not be able to match the
> malformed request anyway.
>
> Thus you can act "Ideally" per RFC 4475 section 3.3.1 and send a 400
> response; or you can act non "Ideally" and ignore it.
>
> The same applies when the mentioned headers are too malformed to adequately
> build a 400 response.
>
>
>> Is that mandatory to have Via header in 4xx response ?
>
> Yes.
>
>
>> if yes what should be the value of the address and
>> branch parameter in Via header?
>
> The values received with parameters such as received added if needed.
>
>
>> can i use the value of UAS in place of Via header's address
>> and branch parameter?
>
> No.
>
>
> _______________________________________________
> Sip-implementors mailing list
> [email protected]
> https://lists.cs.columbia.edu/cucslists/listinfo/sip-implementors
>
_______________________________________________
Sip-implementors mailing list
[email protected]
https://lists.cs.columbia.edu/cucslists/listinfo/sip-implementors