Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

This document will attempt to provide working OpenSBC configurations for a few commonly used sipxecs calling scenarios. It is a work in progress, so please check back often. For any questions or comments, contact the author (raymund.nones [at] gmail.com) or post to the OpenSBC forum at http://www.opensourcesip.org.NOTE: I'm currently updating this document to give

Note

This page is work in progress. It will have more screenshots for Linux, OSBC and SipXecs

...

and a more clearer guide.

Scenario

...

#1: Using OSBC for Far End NAT Traversal(FENT) - Public .

Info

This enables remote workers on the WAN to access a

...

sipXecs instance, where

...

sipXecs has a public IP address, from behind NAT routers.

Setup:

  • OS: Fedora 8
  • No.of NIC: two, both with Public IP Address
    SipXecs and OSBC are installed on the same box, each using a separate IP address
  • UA's: Behind NAT
Note

...

Dues to a limitation where the gateway configured in sipxecs always uses port 5060, OSBC can not be used for FENT and SIP Trunking simultaneously.

...

1.a Registering a NAT'd UA to sipxecs through OSBC with UpperReg(without and with domain rewriting)

In OSBC:
Setting OSBC with UpperReg Mode:1.)

  1. Go to OSBC General Parameters

...

  1. Select B2BUpperReg Mode

...

  1. Press Update (Note: After Update you need to restart OSBC)

Setting OSBC to listen to a specific interface:1.)

  1. Go to OSBC General Parameters

...

  1. Input the interface address at the Interface Address Field and Click Add

...

  1. Press Update (Note: After Update you need to restart OSBC)

Setting OSBC Upper Registration1.)

  1. Go to Upper Registration

...

  1. Input the Route at the Route-List Field and select Add
    for the given example route: [sip:*] sip:sipx.example.com
    this will route all traffic from OSBC to SipX instance at sipx.example.com

    ...

    Note

    For domain rewriting, click the check box for Domain Rewriting (i'll be giving examples regarding the Rewrite Feature on my next update)

    If Rewrite-TO-Domain is check, domain of the To-URI will be rewritten and use the domain parameter of the route-uri.
    If Rewrite-FROM-Domain is check, domain of the From-URI will be rewritten and use the domain parameter of the route-uri

...

  1. Press Update

In SipXecs:1.)

  1. Create a user / extension ex. Uid: 200 Pw: 200

In UA:1.)

  1. Setup your phone
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- this domain should resolve to the IP address of your SipXecs instance
    Proxy: osbc.example.com <-- tjis domain should resolve to the IP address of your OSBC instance

1.b Calls between UAs behind NAT

Callflow: UA1 ? OSBC ? SIPX ? OSBC ? UA2

In OSBC:1.)

  1. Using the settings for OSBC from Scenario #1, Go to B2BUA Routes

...

  1. Add Routes to Route-List
    Ex. [sip:*] sip:sipx.example.com
    for the given example route: [sip:*] sip:sipx.example.com this will route all calls from OSBC to SipX instance at sipx.example.com

...

  1. Press Update

In SipXecs:1.)

  1. Create two users / extensions ex.
    Uid: 200 Pw: 200
    Uid: 201 Pw: 201

In UA:1.)

  1. Setup your phones
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- this domain should resolve to the IP address of your SipXecs instance
    Proxy: osbc.example.com <-- this domain should resolve to the IP address of your OSBC instance
    Uid: 201 Pw: 201
    Domain: sipx.example.com <-- this domain should resolve to the IP address of your SipXecs instance
    Proxy: osbc.example.com <-- this domain should resolve to the IP address of your OSBC instance

1.c Calls to PSTN, UAs behind NAT

Callflow: UA1 ? OSBC ? SIPX ? OSBC _-> PSTN Gateway

In OSBC:1.)

  1. Using the settings for OSBC from Scenario #1, Go to B2BUA Routes

...

  1. Add Routes to Route-List
    Ex.
    [sip:*] sip:sipx.example.com
    for the given example route: [sip:*] sip:sipx.example.com this will route all calls from OSBC to SipX instance at sipx.example.com
    [sip:12*] sip:mypstngateway
    for the given example route: [sip:12*] sip:mypstngateway this will route all calls starting with 12(Prefix 9 was drop by SipXecs for outgoing call) from OSBC to PSTN Gateway

...

  1. Press Update

In SipXecs:1.)

  1. Create users / extensions ex.
    Uid: 200 Pw: 200

...

  1. Setup your Gateway at SipXecs (Point your Gateway to OSBC Instance)

In UA:1.)

  1. Setup your phones
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- your SipXecs instance
    Proxy: osbc.example.com <-- your OSBC instance

1.d Calls From PSTN, UAs behind NAT

Callflow: PSTN Caller ? OSBC ? SIPX ? OSBC ? UA1

In OSBC:1.)

  1. Using the settings for OSBC from Scenario #1, Go to B2BUA Routes

...

  1. Add Routes to Route-List
    Ex. [sip:12345678] sip:100@sipx.example.com
    Note

...

  1. replace 12345678 with your correct DID number

    for the given example route: [sip:12345678] sip:100@sipx.example.com this will route calls from OSBC(12345678) to SipX AutoAttendant(indicated by ext 100 or replace with 200 to go directly to extension) at sipx.example.com

...

  1. Press Update

In SipXecs:1.)

  1. Create users / extensions ex.
    Uid: 200 Pw: 200

In UA:1.)

  1. Setup your phones
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- your SipXecs instance
    Proxy: osbc.example.com <-- your OSBC instance

Scenario

...

#2: Using OSBC for Far End NAT Traversal (FENT) - Private.

Info

This enables remote workers on the WAN to access a sipxecs instance, where SIPX has a private IP address, from behind NAT routers.

Setup:

  • OS: Fedora 8
  • No.of NIC: two, One with Public IP Address and the other with a Private IP Address
  • SipXecs and OSBC are installed on the same box, each using a separate IP address
  • UA's: registered to sipxecs on a local network using private IP addresses, there is no NAT traversal involved.

...

Note

Dues to a limitation where the gateway configured in sipxecs always uses port 5060, OSBC can not be used for FENT and SIP Trunking simultaneously.

...

2.a Calls to PSTN, UAs and SipXecs on a Local Network

Callflow: UA1 ? SIPX ? OSBC _-> PSTN Gateway

In OSBC:1.)

  1. Go to B2BUA Routes

...

  1. Add Routes to Route-List
    Ex.
    [sip:12*] sip:mypstngateway
    for the given example route: [sip:12*] sip:mypstngateway this will route all calls starting with 12(Prefix 9 was drop by SipXecs for outgoing call) from OSBC to PSTN Gateway

...

  1. Press Update

In SipXecs:1.)

  1. Create two users / extensions ex.
    Uid: 200 Pw: 200

...

  1. Setup your Gateway at SipXecs (Point your Gateway to OSBC Instance)

In UA:1.)

  1. Setup your phones
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- your SipXecs instance

2.

...

b Calls from PSTN, UAs and SipXecs on a Local Network

Callflow: PSTN Caller ? OSBC ? SIPX ? UA1

In OSBC:1.)

  1. Go to B2BUA Routes

...

  1. Add Routes to Route-List
    Ex. [sip:12345678] sip:100@sipx.example.com

    ...

    Note

    replace 12345678 with your correct DID number

    for the given example route: [sip:12345678] sip:100@sipx.example.com this will route calls from OSBC(12345678) to SipX AutoAttendant(indicated by ext 100 or replace with 200 to go directly to extension) at sipx.example.com(local SipXecs Address)

...

  1. Press Update

In SipXecs:1.)

  1. Create users / extensions ex.
    Uid: 200 Pw: 200

In UA:1.)

  1. Setup your phones
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- your SipXecs instance

Scenario

...

#3: Using OSBC for SIP trunking (this example uses RingCentral).

Info

This enables sipxecs users on a local private network to connect to the PSTN using a SIP Trunk account on the public network.

Setup:

  • OS: Fedora 8
  • No.of NIC: two, One with Public IP Address and the other with a Private IP Address
  • SipXecs and OSBC are installed on the same box, each using a separate IP address
  • UA's: registered to sipxecs on a local network using private IP addresses, there is no NAT traversal involved.
  • SIP Trunk provider: This call flow was tested using a RingCentral account
Note

...

Dues to a limitation where the gateway configured in sipxecs always uses port 5060, OSBC can not be used for FENT and SIP Trunking simultaneously.

...

3.a Registering OSBC to the SIP Trunk*

In OSBC:

Setting OSBC to Register to a Sip Trunk Provider:1.)

  1. Go to OSBC Sip Trunk Config

...

  1. Paste the XML for the config (sample below)
    Code Block
    
    <root>

...

  1. 
    <siptrunk trunk-name="my.sipprovider.com"

...

  1. 
    route-set="sip:sip.sipprovider.com"

...

  1. 
    sip-domain="sip.sipprovider.com"

...

  1. 
    expires="10">

...

  1. 
    <trunk-accounts>

...

  1. 
    <account user-name="xxxxxxx"

...

  1. 
    auth-user-name="xxxxxx"

...

  1. 
    auth-password="xxxxxx"

...

  1. 
    inbound-route="sip:100@sipx.example.com"

...

  1. 
    expires="3600"/>

...

  1. 
    </trunk-accounts>

...

  1. 
    <transient-accounts>

...

  1. 
    <account user-name="xxxxx"

...

  1. 
    auth-user-name="xxxx"

...

  1. 
    auth-password="xxxx"

...

  1. 
    inbound-route="sip:100@sipx.example.com"

...

  1. 
    expires="3600"/>

...

  1. 
    </transient-accounts>

...

  1. 
    </siptrunk>

...

  1. 
    </root>
    

...

  1. Press Update

...

  1. To check if registration is successful, Go to Sip-Trunk Registration Status
    sip:xxxxxxx@sip.sipprovider.com sip:xxxxxx@xxx.xxx.xx.xx:5066 00773236-91be-dd11-8be9-e96beb558260@sip.sipprovider.com SIP/2.0 200 OK

3.b Routing of inbound calls from a trunk provider to the sipxecs autoattendant

Callflow: Caller ? SipTrunk Provider ? OSBC ? SipX

In OSBC:1.)

  1. After Registration to a Trunk Provider from Scenario 3.a

...

  1. Go to B2BUA Routes

...

  1. Add Routes to Route-List
    Ex. [sip:100*] sip:sipx.example.com
    for the given example route: [sip:100*] sip:sipx.example.com this will route all calls with prefix 100 from OSBC to SipXecs Auto Attendant at sipx.example.com

...

  1. Press Update

In SipXecs:1.)

  1. Create users / extensions ex.
    Uid: 200 Pw: 200

In UA:1.)

  1. Setup your phones
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- your SipXecs instance

3.c Routing of outbound calls from a trunk provider

Call Flow: UA1 ? SIPX ? OSBC _-> Sip Trunk Provider

In OSBC:1.)

  1. Go to B2BUA Routes

...

  1. Add Routes to Route-List
    Ex. [sip:12*] sip:sip.ringcentral.com;sip-trunk=true
    for the given example route: [sip:12*] sip:sip.ringcentral.com;sip-trunk=true, this will route all calls starting with 12(Prefix 9 was drop by SipXecs for outgoing call) from OSBC to Sip Trunk Provider (in this case, Ring Central)

...

  1. Press Update

In SipXecs:1.)

  1. Create users / extensions ex.
    Uid: 200 Pw: 200

...

  1. Setup your Gateway at SipXecs (Point your Gateway to OSBC Instance)

In UA:1.)

  1. Setup your phones
    Uid: 200 Pw: 200
    Domain: sipx.example.com <-- your SipXecs instance