I work at an SIP Provider and we have added and SBC in front of our Voice Switch to protect it.
This requires all our SIP Trunk customers to register via a ‘proxy’.
I struggle with Asterisk to work over a proxy.
This is what I have done so far.
register => firstname.lastname@example.org:email@example.com
This works fine, asterisk is sending registrations via the SBC to the voice switch defined by URI.
type=peer secret=password host=sip.example.com outboundproxy=sbc.example.com context=from-ISP-X
From the Dialplan that string is dialed:
This works fine, asterisk sends the call to the outboundproxy defined in the sip.conf section of [username].
Before adding outboundproxy setting, incomming calls were matched because they originated from the host and passed to the correct context.
I have set allowguest=no to challenge all those sip attackers in
[default] who occasionaly managed to call internal extensions defined there.
Now incomming calls do not originate from the ip of sip.example.com anymore, but from the ip of sbc.example.com and are not set to the context [from-ISP-X] but probably to [default] and challenged.
Of course, I could allow guests, but that would bring back the problem of having unwanted calls from sip scanners.
So how do I tell the asterisk to also match calls from the ip of the outbound proxy?
I m p r o W a r e A G – Leiter Commerce Kunden