[SR-Users] Question regarding parser error for REGISTER request

Henning Westerholt hw at skalatan.de
Mon Sep 20 21:28:09 CEST 2021


the parser error could be also generated from some unrelated operation in the cfg file, like accessing the Contact parameters. You should be able to get from the context of the error log more information.
Regarding debugging, for an obvious suggestion - have you already tried to just dump the complete SIP message in the main route for debugging, e.g., with INFO log level?



Henning Westerholt – https://skalatan.de/blog/
Kamailio services – https://gilawa.com<https://gilawa.com/>

From: sr-users <sr-users-bounces at lists.kamailio.org> On Behalf Of Floimair Florian
Sent: Monday, September 20, 2021 2:19 PM
To: Kamailio (SER) - Users Mailing List <sr-users at lists.kamailio.org>
Subject: [SR-Users] Question regarding parser error for REGISTER request

Hello List!

We have a certain user agent that somehow triggers a parser error log entry, everytime this type of user agent registers.
Sep 20 12:03:49 kamailio-dev-1 /usr/sbin/kamailio[1803]: ERROR: <core> [core/parser/parse_param.c:517]: parse_param2(): Invalid character, ; expected

The odd thing now is that this register still succeeds. And we do not see that error for other methods like e.g. INVITE.
The user agent in question is an Android app based on linphone which we develop inhouse. We also use the same for iOS where the error does not occur.

The REGISTER request contains a push-token in the Contact header and I think this is where the parser somehow generates this error. Since this is the only line apart from the User-Agent header where the content of the two is different.
We did have a look and diffed the differences between our iOS and Android app variants and didn’t see any obvious problem or invalid character (compared even with hex editor).

So my questions regarding this I hope that someone of you can help me with:

-          Is there any way to make the parser error more verbose (e.g. which character in which header it is complaining about)? Right now it only says that there was an error and that it expected ‘;’ but not where and what character was found instead.

-          Why does the parser throw the error but the registration still succeeds? It does not quite make sense to me.

Best Regards

Commend International GmbH
Saalachstrasse 51
5020 Salzburg, Austria
Phone: +43 662 85 62 25
Mail: f.floimair at commend.com<mailto:f.floimair at commend.com>
LG Salzburg / FN 178618z

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20210920/74c92ae2/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 171 bytes
Desc: image001.png
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20210920/74c92ae2/attachment.png>

More information about the sr-users mailing list