[SR-Users] regular expression in kamailio

Alex Balashov abalashov at evaristesys.com
Sun Aug 26 01:21:45 CEST 2018


On Sat, Aug 25, 2018 at 11:16:29PM +0000, Wilkins, Steve wrote:

> Oh, but I want the 10 digit number. If from is like
> sip://10000@2223334444, I want 2223334444, not 10000

The (abridged) grammar of a SIP URI is:

  sip:user at domain[:port]

The calling party number would be in the user part, ordinarily.

If you really want the domain, you're going to get a host/IP address of
the calling UAC most likely. That can be accessed via @fd.

Perhaps you can provide an example of the exact From header you see and
the portion of it you would like to extract? Because your example makes
no sense. :-)

-- Alex

-- 
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