[OpenSIPS-Users] add_path_received and TLS - received address problem

Liviu Chircu liviu at opensips.org
Wed Jul 21 09:56:32 EST 2021


On 20.07.2021 13:26, Mark Allen wrote:
> On registration add_path_received() works but the received address is 
> not formatted correctly. I am seeing '%%3b' instead of a semicolon, 
> and '%%3d' instead of an equals sign.
>
Hi Mark,

How exactly is this peculiar formatting breaking your logic?  Because 
the '%'-escaping logic is by design, with a similar un-escaping logic 
being included in the code that parses those Path headers, so the UDP 
<-> TLS translation using Path headers should work just fine.

See this commit for full details on how the escaping logic solves 
multiple problems with the original approach: [1].

PS: with 3 years having passed since I wrote that commit, nowadays I 
would look at a different way of solving the same problem, as I vaguely 
recall that URI param values can be enclosed in double-quotes ("), 
allowing us to put anything in there, without affecting the semantics of 
the original URI.  Just an idea that we could research/confirm/infirm 
should we find any non-fixable issues with the current escaping approach.

[1]: https://github.com/OpenSIPS/opensips/commit/b3bf15646affe981d4b26

Best Regards,

-- 
Liviu Chircu
www.twitter.com/liviuchircu | www.opensips-solutions.com
OpenSIPS Summit 2021 Distributed | www.opensips.org/events




More information about the Users mailing list