Brekeke Forum Index » Brekeke SIP Server Forum

Post new topic   Reply to topic
Matching Multiple IP Addresses on Incoming Calls
Author Message
JRayfield
Brekeke Guru


Joined: 03 Dec 2012
Posts: 147
Location: Springfield, MO

PostPosted: Thu Apr 05, 2018 2:19 pm    Post subject: Matching Multiple IP Addresses on Incoming Calls Reply with quote

1. Brekeke Product Name and Version:
SIP Server

2. Java version:
1.8.0_161

3. OS type and the version:
Windows 7 Pro SP1

4. UA (phone), gateway or other hardware/software involved:
Not Sure

5. Your problem:

I'm connecting my Brekeke SIP Server (BSS) into a VoIP service providers system. They use IP address authentication and they use multiple IP addresses for multiple failover servers.

Everything works fine, except that I would like to limit the IP addresses in the Matching section of the Dial Plan, to just those of the service provider's servers. This would provide a bit more security.

I can use $addr for an IP address, but I need to have multiple ones for each possible incoming DID number. Is there a way to do something like this:

$addr = 1.1.1.1
or
$addr = 2.2.2.2
or
$addr = 3.3.3.3

where 1.1.1.1, etc, are the service providers public IP addresses?

John Rayfield, Jr.

_________________
John Rayfield, Jr. CETma
Rayfield Communications
Springfield, MO
www.rayfield.net
Back to top
View user's profile
Tata
Brekeke Master Guru


Joined: 27 Jan 2008
Posts: 223

PostPosted: Fri Apr 06, 2018 7:53 am    Post subject: Reply with quote

"or" is '|' in Regular expression (https://en.wikipedia.org/wiki/Regular_expression)
so it will be
Code:
$addr = ^1.1.1.1$|^2.2.2.2$|^3.3.3.3$



If these IP addresses are in the same range of IP address, you can use $addrRange
http://wiki.brekeke.com/wiki/DialPlan-Matching-addrRange

If these IP addresses have the same IP address prefix (eg: in the same subnet), you can use $addrPrefix
http://wiki.brekeke.com/wiki/DialPlan-Matching-addrPrefix
Back to top
View user's profile
JRayfield
Brekeke Guru


Joined: 03 Dec 2012
Posts: 147
Location: Springfield, MO

PostPosted: Wed Apr 18, 2018 3:29 pm    Post subject: Reply with quote

Excellent. Worked perfect. Thanks!

John

_________________
John Rayfield, Jr. CETma
Rayfield Communications
Springfield, MO
www.rayfield.net
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    Brekeke Forum Index » Brekeke SIP Server Forum All times are GMT - 7 Hours
Page 1 of 1