Fortinet black logo

Creating SIP peer for IP-PBX

Copy Link
Copy Doc ID 2c73732a-76a5-11eb-9995-00505692583a:256108
Download PDF

Creating SIP peer for IP-PBX

You can add one or more VoIP service providers to the FortiVoice Gateway trunk configuration. The VoIP service providers deliver your telephone services to customers equipped with SIP-based PBX (IP-PBX).

To view the list of VoIP service providers
  1. Go to Gateway > SIP > SIP.

GUI field

Description

Enabled

Select to activate this trunk.

Name

The name of the VoIP service provider.

Server

The VoIP provider’s domain name or IP address. For example, 172.20.120.11 or voip.example.com.

Port

The port for SIP sessions.

SIP Setting

The SIP profile applied to this trunk.

Status

The status of the SIP trunk.

  • Not registered: The trunk is not registered with the VoIP service provider and is not in service.
  • In service: The trunk is registered with the VoIP service provider and is in service.
  • Unavailable: The trunk is not reachable.
  • Alarm detected: There is a problem with the phone line.
  • Admin down: The trunk is disabled.
  • Unmonitored: The trunk is unknown.
To create a VoIP trunk
  1. Go to Gateway > SIP > SIP.
  2. Click New.
  3. Configure the following:

    GUI field

    Description

    Name

    Enter the name of the VoIP service provider.

    Status

    Select to activate the SIP trunk.

    Display name

    Enter your caller ID that will appear on the called phone, such as Example Company.

    Main number

    Enter the phone number that will appear on the called phone.

    SIP Setting

    SIP server

    Enter the VoIP provider’s IP address or domain name. For example, 172.20.120.11 or voip.example.com.

    SIP port

    Most SIP configurations use TCP or UDP port 5060 for SIP sessions. If your VoIP service provider uses a different port for SIP sessions, enter the port number.

    If you select the Using DNS record option, this field is greyed out.

    Using SRV record

    If you entered the VoIP provider’s domain name in the SIP server field, select this option to translate the domain name and obtain the SIP port.

    You can only select this option if your VoIP provider uses the same setting.

    User name

    Enter the user name provided by the VoIP service provider for the FortiVoice Gateway to register with the SIP server.

    Password

    Enter the password provided by the VoIP service provider for the FortiVoice Gateway to register with the SIP server.

    Auth. user name

    Some VoIP providers may provide you with an authentication user name that is different from your user name for the FortiVoice Gateway to register with the SIP server. If tat is the case, enter the authentication user name here.

    Realm/domain

    Some VoIP service providers’ SIP servers authenticate the PBXes that register with them by requesting the name of the host performing the authentication. If this is the case with your VoIP service provider, enter the name of the host performing the authentication provided by your VoIP service provider.

    SIP setting

    Select the SIP profile to apply the supported phone features and codecs for the trunk. To match the information of the VoIP service provider, you can edit the existing profile or click New to add a new one. For more information, see Configuring SIP profiles.

    Max channel

    Each trunk contains multiple channels. The number of channels you can have in a trunk is controlled by your VoIP service provider.

    Consult your VoIP service provider for the maximum of channels that you can set to limit the number of concurrent calls. For example, if you want to allow six calls at a time, enter 6.

    Overflow check

    If selected, the phone calls exceeding the Max channel limit will be handled according to the call handling actions set in the dialplan applied to this trunk.

    If unselected, the phone calls exceeding the Max channel limit will be disconnected.

    Max outgoing channel

    With known max channels, if you need to reserve incoming channels, you may enter the number of outgoing channels allowed and the remaining channels are for incoming calls.

    For example, the max channel number is 10 and you want to reserve 4 channels for incoming calls, you can enter 6 for Max outgoing channel.

    User=Phone in SIP URI

    Select if your service provider requires this option to make the FortiVoice Gateway to be compatible with the VoIP service provider’s configurations.

    Inband ringtone

    Select to enable the FortiVoice Gateway to send ring tone to the caller of an incoming call before the establishment of a call connection.

    Caller ID Option

    Select if you want the trunk main number to appear on the called phone. See Main number.

    Otherwise, the user name provided by the VoIP service provider for the FortiVoice Gateway to register with the SIP server will appear on the called phone. See User name.

    Registration

    Enter the SIP registration information from the VoIP service provider by selecting a registration method. You can receive calls after registering with the SIP server of the VoIP service provider.

    • Disable: Select to deactivate the registration with the VoIP service provider.
    • Standard: Select to use the standard registration method which automatically registers with the SIP server of the VoIP service provider.
    • Registrar: Select to enter the registration information from the VoIP service provider:
      • Registrar host/IP: Enter the VoIP service provider’s SIP registration server domain name or IP address. For example, 172.20.120.11 or voip.example.com.
      • Registrar port: Most SIP configurations use TCP or UDP port 5060 for SIP sessions. If your VoIP service provider uses a different port for SIP sessions, enter the port number.
      • Transport protocol: Select the transport protocol used for the registration.
    • Registration URI: Enter the registration string provided by the VoIP service provider in the Registration URI field.

      The string usually has the following formats:

      register => user[:secret[:authuser]]@host
      [:port][/extension]

      or

      register => fromuser@fromdomain:secret@host

      or

      register => fromuser@fromdomain:secret:
      authuser@host:port/extension

      For example, a string could be: register => 2345:password@mysipprovider.com/1234

    • Registration interval: Enter the time interval in minutes to register with the SIP server of the VoIP service provider.

    Outbound Proxy

    Some VoIP service providers use proxy servers to direct its traffic. If this is the case, your registration request will go to the proxy server first before reaching the registration server. Configure the following:

    • Select to activate the proxy server settings.
    • Proxy (Host/IP): Enter the proxy server’s domain name or IP address. For example, 172.20.120.11 or voip.example.com.
    • Proxy port: Enter the port number of the proxy server.
    • Transport protocol: Select the transport protocol used for the registration.

    Fax

    Configure fax signal automatic detection and fax handling.

    Automatic fax detection

    Select for the FortiVoice Gateway to detect incoming fax signal on this trunk automatically.

    Selecting this option may delay the call response time on this trunk.

    Forward fax to eFax account

    Some incoming faxes’ numbers do not match those of your eFax accounts. Selecting this option and a fax receiving account will send the faxes to the fax account.

    This option is only selectable if Automatic fax detection is selected.

    Phone Number

    Click New to add the phone number provided by your VoIP service provider. The VoIP service provider SIP server will direct calls from external callers directly to this number. You can add multiple numbers.

  4. Click Create.

Testing SIP trunks

After you create a SIP trunk, you can select the trunk and click Test to see if the trunk works.

For more information, see Creating SIP peer for IP-PBX .

To test a SIP trunk
  1. Go to Gateway > SIP > SIP.
  2. Select the trunk that you want to test and click Test.
  3. Select Test Call - Dry Run or Test Call.
  4. Configure the following fields, as applicable:

    GUI field

    Description

    Test Call - Dry Run

    Run a system SIP trunk test without making a real phone call.

    Destination number

    Enter a destination number to call.

    From number

    Enter the number from which you want to call the destination number. The FortiVoice Gateway will connect this number with the destination number for the test.

    Test

    Click to start the dry run test and check the Test result.

    Reset

    Click to remove the test result in order to start a new test.

    Test Call

    Test the SIP trunk by making a real phone call.

    Destination number

    Enter a destination number to call.

    After call is established

    Select the FortiVoice Gateway action once it calls the destination number:

    • Play welcome message: The FortiVoice Gateway will play a message to the destination number.
    • Connect test call to number: In the Number field, enter the number from which you want to call the destination number. The FortiVoice Gateway will connect this number with the destination number to test the trunk.

    Test

    Click to start the test and check the Test result.

    Reset

    Click to remove the test result in order to start a new test.

Creating a SIP trunk with FortiCall service

You can create one trunk with FortiCall and use it free for 30 days or 300 minutes, whichever comes first. Note that the trial account only allows outbound calling and no international calling is available.

If you sign up for the service during a trial use, the trial is closed and billing will start.

To create a SIP trunk with FortiCall service
  1. Go to Trunk > VoIP > SIP.
  2. Click FortiCall.

    The Create SIP Trunk dialog box displays.

  3. Note down the MAC Address and System ID for use if you decide to sign up for the service later.
  4. Keep Create dialplans for this trunk selected unless you want to create the dialplans by yourself.

    The auto-generated dialplans will replace the default inbound, outbound, and emergency call dialplans. You can delete them if you do not choose to use the FortiCall service.

  5. Click OK.
  6. Enter your name, email address, and reseller or partner code.
  7. Click Create.
  8. Click OK.

    The FortiCall trunk is created.

Creating SIP peer for IP-PBX

You can add one or more VoIP service providers to the FortiVoice Gateway trunk configuration. The VoIP service providers deliver your telephone services to customers equipped with SIP-based PBX (IP-PBX).

To view the list of VoIP service providers
  1. Go to Gateway > SIP > SIP.

GUI field

Description

Enabled

Select to activate this trunk.

Name

The name of the VoIP service provider.

Server

The VoIP provider’s domain name or IP address. For example, 172.20.120.11 or voip.example.com.

Port

The port for SIP sessions.

SIP Setting

The SIP profile applied to this trunk.

Status

The status of the SIP trunk.

  • Not registered: The trunk is not registered with the VoIP service provider and is not in service.
  • In service: The trunk is registered with the VoIP service provider and is in service.
  • Unavailable: The trunk is not reachable.
  • Alarm detected: There is a problem with the phone line.
  • Admin down: The trunk is disabled.
  • Unmonitored: The trunk is unknown.
To create a VoIP trunk
  1. Go to Gateway > SIP > SIP.
  2. Click New.
  3. Configure the following:

    GUI field

    Description

    Name

    Enter the name of the VoIP service provider.

    Status

    Select to activate the SIP trunk.

    Display name

    Enter your caller ID that will appear on the called phone, such as Example Company.

    Main number

    Enter the phone number that will appear on the called phone.

    SIP Setting

    SIP server

    Enter the VoIP provider’s IP address or domain name. For example, 172.20.120.11 or voip.example.com.

    SIP port

    Most SIP configurations use TCP or UDP port 5060 for SIP sessions. If your VoIP service provider uses a different port for SIP sessions, enter the port number.

    If you select the Using DNS record option, this field is greyed out.

    Using SRV record

    If you entered the VoIP provider’s domain name in the SIP server field, select this option to translate the domain name and obtain the SIP port.

    You can only select this option if your VoIP provider uses the same setting.

    User name

    Enter the user name provided by the VoIP service provider for the FortiVoice Gateway to register with the SIP server.

    Password

    Enter the password provided by the VoIP service provider for the FortiVoice Gateway to register with the SIP server.

    Auth. user name

    Some VoIP providers may provide you with an authentication user name that is different from your user name for the FortiVoice Gateway to register with the SIP server. If tat is the case, enter the authentication user name here.

    Realm/domain

    Some VoIP service providers’ SIP servers authenticate the PBXes that register with them by requesting the name of the host performing the authentication. If this is the case with your VoIP service provider, enter the name of the host performing the authentication provided by your VoIP service provider.

    SIP setting

    Select the SIP profile to apply the supported phone features and codecs for the trunk. To match the information of the VoIP service provider, you can edit the existing profile or click New to add a new one. For more information, see Configuring SIP profiles.

    Max channel

    Each trunk contains multiple channels. The number of channels you can have in a trunk is controlled by your VoIP service provider.

    Consult your VoIP service provider for the maximum of channels that you can set to limit the number of concurrent calls. For example, if you want to allow six calls at a time, enter 6.

    Overflow check

    If selected, the phone calls exceeding the Max channel limit will be handled according to the call handling actions set in the dialplan applied to this trunk.

    If unselected, the phone calls exceeding the Max channel limit will be disconnected.

    Max outgoing channel

    With known max channels, if you need to reserve incoming channels, you may enter the number of outgoing channels allowed and the remaining channels are for incoming calls.

    For example, the max channel number is 10 and you want to reserve 4 channels for incoming calls, you can enter 6 for Max outgoing channel.

    User=Phone in SIP URI

    Select if your service provider requires this option to make the FortiVoice Gateway to be compatible with the VoIP service provider’s configurations.

    Inband ringtone

    Select to enable the FortiVoice Gateway to send ring tone to the caller of an incoming call before the establishment of a call connection.

    Caller ID Option

    Select if you want the trunk main number to appear on the called phone. See Main number.

    Otherwise, the user name provided by the VoIP service provider for the FortiVoice Gateway to register with the SIP server will appear on the called phone. See User name.

    Registration

    Enter the SIP registration information from the VoIP service provider by selecting a registration method. You can receive calls after registering with the SIP server of the VoIP service provider.

    • Disable: Select to deactivate the registration with the VoIP service provider.
    • Standard: Select to use the standard registration method which automatically registers with the SIP server of the VoIP service provider.
    • Registrar: Select to enter the registration information from the VoIP service provider:
      • Registrar host/IP: Enter the VoIP service provider’s SIP registration server domain name or IP address. For example, 172.20.120.11 or voip.example.com.
      • Registrar port: Most SIP configurations use TCP or UDP port 5060 for SIP sessions. If your VoIP service provider uses a different port for SIP sessions, enter the port number.
      • Transport protocol: Select the transport protocol used for the registration.
    • Registration URI: Enter the registration string provided by the VoIP service provider in the Registration URI field.

      The string usually has the following formats:

      register => user[:secret[:authuser]]@host
      [:port][/extension]

      or

      register => fromuser@fromdomain:secret@host

      or

      register => fromuser@fromdomain:secret:
      authuser@host:port/extension

      For example, a string could be: register => 2345:password@mysipprovider.com/1234

    • Registration interval: Enter the time interval in minutes to register with the SIP server of the VoIP service provider.

    Outbound Proxy

    Some VoIP service providers use proxy servers to direct its traffic. If this is the case, your registration request will go to the proxy server first before reaching the registration server. Configure the following:

    • Select to activate the proxy server settings.
    • Proxy (Host/IP): Enter the proxy server’s domain name or IP address. For example, 172.20.120.11 or voip.example.com.
    • Proxy port: Enter the port number of the proxy server.
    • Transport protocol: Select the transport protocol used for the registration.

    Fax

    Configure fax signal automatic detection and fax handling.

    Automatic fax detection

    Select for the FortiVoice Gateway to detect incoming fax signal on this trunk automatically.

    Selecting this option may delay the call response time on this trunk.

    Forward fax to eFax account

    Some incoming faxes’ numbers do not match those of your eFax accounts. Selecting this option and a fax receiving account will send the faxes to the fax account.

    This option is only selectable if Automatic fax detection is selected.

    Phone Number

    Click New to add the phone number provided by your VoIP service provider. The VoIP service provider SIP server will direct calls from external callers directly to this number. You can add multiple numbers.

  4. Click Create.

Testing SIP trunks

After you create a SIP trunk, you can select the trunk and click Test to see if the trunk works.

For more information, see Creating SIP peer for IP-PBX .

To test a SIP trunk
  1. Go to Gateway > SIP > SIP.
  2. Select the trunk that you want to test and click Test.
  3. Select Test Call - Dry Run or Test Call.
  4. Configure the following fields, as applicable:

    GUI field

    Description

    Test Call - Dry Run

    Run a system SIP trunk test without making a real phone call.

    Destination number

    Enter a destination number to call.

    From number

    Enter the number from which you want to call the destination number. The FortiVoice Gateway will connect this number with the destination number for the test.

    Test

    Click to start the dry run test and check the Test result.

    Reset

    Click to remove the test result in order to start a new test.

    Test Call

    Test the SIP trunk by making a real phone call.

    Destination number

    Enter a destination number to call.

    After call is established

    Select the FortiVoice Gateway action once it calls the destination number:

    • Play welcome message: The FortiVoice Gateway will play a message to the destination number.
    • Connect test call to number: In the Number field, enter the number from which you want to call the destination number. The FortiVoice Gateway will connect this number with the destination number to test the trunk.

    Test

    Click to start the test and check the Test result.

    Reset

    Click to remove the test result in order to start a new test.

Creating a SIP trunk with FortiCall service

You can create one trunk with FortiCall and use it free for 30 days or 300 minutes, whichever comes first. Note that the trial account only allows outbound calling and no international calling is available.

If you sign up for the service during a trial use, the trial is closed and billing will start.

To create a SIP trunk with FortiCall service
  1. Go to Trunk > VoIP > SIP.
  2. Click FortiCall.

    The Create SIP Trunk dialog box displays.

  3. Note down the MAC Address and System ID for use if you decide to sign up for the service later.
  4. Keep Create dialplans for this trunk selected unless you want to create the dialplans by yourself.

    The auto-generated dialplans will replace the default inbound, outbound, and emergency call dialplans. You can delete them if you do not choose to use the FortiCall service.

  5. Click OK.
  6. Enter your name, email address, and reseller or partner code.
  7. Click Create.
  8. Click OK.

    The FortiCall trunk is created.