Brekeke Forum Index » Brekeke SIP Server Forum

Post new topic   Reply to topic
Set target to use source IP address of Contact URI
Author Message
jasongreb
Brekeke Newbie


Joined: 25 Aug 2022
Posts: 4
Location: North Carolina

PostPosted: Wed Aug 09, 2023 4:24 am    Post subject: Set target to use source IP address of Contact URI Reply with quote

1. Brekeke Product Name and Version: 3.14.5

2. Java version: AdoptOpenJDK (latest)

3. OS type and the version: Windows Server 2019

4. UA (phone), gateway or other hardware/software involved: CUCM/Rauland Enterprise

5. Your problem: I am setting up a dial plan to take incoming calls from CUCM and send them to the appropriate node in an app cluster. The RE app node registers a user as an endpoint in Brekeke. There is a different contact address however, which is where I need to send it. As an example, the Contact URI could be sip:12345@sipcontact.domain.org:5060 (1.1.1.1:5060) or sip:12345@sipcontact.domain.org:5060 (1.1.1.2:5060) depending on which node registered it. I need to get either the 1.1.1.1 or the 1.1.1.2 into the $target on a deploy pattern. Any thoughts on how to get this information so I can ensure it is going to the right node without manually changing each time it switches nodes?
Back to top
View user's profile
Harold
Brekeke Master Guru


Joined: 21 Sep 2008
Posts: 286
Location: Japan

PostPosted: Sat Aug 12, 2023 2:20 pm    Post subject: Reply with quote

> As an example, the Contact URI could be sip:12345@sipcontact.domain.org:5060 (1.1.1.1:5060) or sip:12345@sipcontact.domain.org:5060 (1.1.1.2:5060)


Is 1.1.1.1:5060 or 1.1.1.2:5060 a source IP address/port of a SIP-REGISTER?
If so you can get it with $addrPort in DialPlan.

Here is the example in Deploy Patterns.
$target = %{$addrPort}
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