Hey there,
I'm currently trying to connect to a SIP server using IPv6, which fails.
Linphone fails to decode the IPv6 address sent back in the Via header of the 401 Unauthorized reply (after first REGISTER request). The IPv6 is in the "URL encoded" format with squared brackets: [2000:abc::1]:5060.
There seems to be an issue in the
protocol definition where an IPv6 address isn't allowed to contain squared brackets.
Which is used here:
The following error is shown in the log when this parsing error occurrs:
2020-04-06 17:02:35:725 MESSAGE [org.antlr.runtime.MismatchedTokenException] reason [1342:1: via_params : ( via_received[$header_via::current] | generic_param[BELLE_SIP_PARAMETERS($header_via::current)] );]
2020-04-06 17:02:35:725 ERROR header_via parser error for [Via:SIP/2.0/UDP [2001:470:xxx:xxx::b56b]:5060;branch=z9hG4bK.XtPlwI23x;rport=5060;received=[2001:470:xxx:xxx::b56b]]
2020-04-06 17:02:35:726 MESSAGE channel [0x1b7a4f0] [563] bytes parsed
2020-04-06 17:02:35:727 ERROR channel [0x1b7a4f0]: no via in response.
2020-04-06 17:02:35:727 WARNING Response has no via.
2020-04-06 17:02:35:727 WARNING Discarding stateless response [401]
I'm using the latest flatpak version of Linphone on Ubuntu 19.10:
Desktop 4.1.1 - Qt5.9.0
Core 3.12.0
This bug is very annoying, because multiple SIP providers do support IPv6 and we would like to use the advantages of IPv6 SIP, so disabling IPv6 isn't an option :)
Thank you very much in advance.