Hello,
On 27.04.21 20:10, Duarte Rocha wrote:
Hello all,
I'm using Kamailio as a registrar and i have an endpoint that sometimes sends a REGISTER method with a To-Tag when refreshing its regist. My code on this proxy shares many similarities with the default kamailio.cfg configuration file.
On that occasion Kamailio answers with a 404 - Not Here since it treats it as a in-dialog request which fails the loose_route check.
Why would a CPE send a REGISTER with a To-Tag? Why is a REGISTER with a To-Tag rejected by Kamailio when it could otherwise be a successful REGISTER? Is this behaviour noncompliant with the SIP protocol?
I thought about making an exception in the code and having this register following the same path as a register without to-tag, but i don't know if that is unsafe and/or noncompliant with the protocol.
To-tag presence indicates a request part of an existing dialog and according to RFC3261 section "10.2 Constructing the REGISTER Request":
"A REGISTER request does not establish a dialog."
Now, if you have CPEs re-using the To-tag, you can change kamailio.cfg to handle them via registrar module, I do not see any real problem doing this. The default kamailio.cfg tries to follow closely the specs, but the flexibility of Kamailio enables you in most of the case to handle traffic even for really broken CPEs.
Cheers, Daniel