[SR-Users] Add default ports to URIs

Alex Balashov abalashov at evaristesys.com
Tue Mar 12 21:30:38 CET 2019


Why would you want to do that? The spec is quite clear that an omission
of a port signifies 5060 for sip: and 5061 for SIP-TLS and sips:.

Although, interestingly, from RFC 3261 ยง 19.1.4 ("URI Comparison"):

    A URI omitting any component with a default value will not
    match a URI explicitly containing that component with its
    default value.  For instance, a URI omitting the optional port
    component will not match a URI explicitly declaring port 5060.
    The same is true for the transport-parameter, ttl-parameter,
    user-parameter, and method components.

On Tue, Mar 12, 2019 at 07:15:30PM +0000, Duarte Rocha wrote:

> Greetings,
> 
> When i receive a message in Kamailio i want to add "5060" to the URI's port
> info when it's value is not specified.
> 
> I can do it with pseudovariables but i was wondering if there's any config
> or setting that would do this automatically?
> 
> Best Regards,
> 
> Duarte Rocha

> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users


-- 
Alex Balashov | Principal | Evariste Systems LLC

Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free) 
Web: http://www.evaristesys.com/, http://www.csrpswitch.com/



More information about the sr-users mailing list