Allocate a static IP address for a VPN client

By default, Yeastar VPN Server dynamically assigns an IP address from its IP address pool to the VPN clients. To take more control of the client activities, you can assign a static IP address for the VPN clients. This article shows how to assign a fixed IP address to the VPN clients.

Allocation for static IP addresses is supported on Yeastar S-Series VoIP PBX version 30.4.0.25 or later.

Allocate a static IP address for a client in TUN device mode

  1. Log in the PBX web interface, go to VPN Server > Static IP, click Add.
  2. Specify a client which you want to assign a static IP address to.
    • If you use CA Cert + Client Cert verification mode, enter the Common Name of this client in the CN filed.

      You can double click the client certificate client.crt, go to Details > Subject and find CN.

    • If you use username/password authentication, and you have created an account for the specified client, select a client account from Account Name field.
  3. Assign the IP address, subnet mask and TUN remote IP address to this client.
    Tip: The virtual client IP address and TUN remote IP address must be taken from successive /30 subnets in order to be compatible with Windows clients and the TAP-Windows driver. Specifically, the last octet in the IP address of the virtual client IP address and TUN remote IP address must be taken from the following:
    [ 5,  6] [  9, 10] [ 13, 14] [ 17, 18] [ 21, 22] [ 25, 26] [ 29, 30] [ 33, 34] [ 37, 38] 
    [ 41, 42] [ 45, 46] [ 49, 50] [ 53, 54] [ 57, 58] [ 61, 62] [ 65, 66] [ 69, 70] [ 73, 74]
    [ 77, 78] [ 81, 82] [ 85, 86] [ 89, 90] [ 93, 94] [ 97, 98] [101,102] [105,106] [109,110] 
    [113,114] [117,118] [121,122] [125,126] [129,130] [133,134] [137,138] [141,142] [145,146] 
    [149,150] [153,154] [157,158] [161,162] [165,166] [169,170] [173,174] [177,178] [181,182] 
    [185,186] [189,190] [193,194] [197,198] [201,202] [205,206] [209,210] [213,214] [217,218] 
    [221,222] [225,226] [229,230] [233,234] [237,238] [241,242] [245,246] [249,250] [253,254]

    In this example, the IP address is set to 10.8.0.5, then the TUN remote IP address must be 10.8.0.6.

  4. Click Save and Apply.

Allocate a static IP address for a client in TAP mode

  1. Log in the PBX web interface, go to VPN Server > Static IP, click Add.
  2. Specify a client which you want to assign a static IP address to.
    • If you use CA Cert + Client Cert verification mode, enter the Common Name of this client in the CN filed.

      You can double click the client certificate client.crt, go to Details > Subject and find CN.

    • If you use username/password authentication, and you have created an account for the specified client, select a client account from Account Name field.
  3. Assign the IP address to this client in the IP Address field.
    Note: The IP address should be in the address pool of the VPN server. The allowed IP range is from XXX.XXX.XXX.3 to XXX.XXX.XXX.253.
  4. Enter the subnet mask in the Subnet Mask field.

  5. Click Save and Apply.