Configuring a CloudBridge Connector tunnel between a datacenter and Azure cloud
The Citrix ADC appliance provides connectivity between your enterprise datacenters and the Microsoft cloud hosting provider, Azure, making Azure a seamless extension of the enterprise network. Citrix ADC encrypts the connection between the enterprise datacenter and Azure cloud so that all data transferred between the two is secure.
How CloudBridge Connector tunnel works
To connect a datacenter to Azure cloud, you set up a CloudBridge Connector tunnel between a Citrix ADC appliance that resides in the datacenter and a gateway that resides in the Azure cloud. The Citrix ADC appliance in the datacenter and the gateway in Azure cloud are the end points of the CloudBridge Connector tunnel and are called peers of the CloudBridge Connector tunnel.
A CloudBridge Connector tunnel between a datacenter and Azure cloud uses the open-standard Internet Protocol security (IPSec) protocol suite, in tunnel mode, to secure communications between peers in the CloudBridge Connector tunnel. In a CloudBridge Connector tunnel, IPSec ensures:
- Data integrity
- Data origin authentication
- Data confidentiality (encryption)
- Protection against replay attacks
IPSec uses the tunnel mode in which the complete IP packet is encrypted and then encapsulated. The encryption uses the Encapsulating Security Payload (ESP) protocol, which ensures the integrity of the packet by using a HMAC hash function and ensures confidentiality by using an encryption algorithm. The ESP protocol, after encrypting the payload and calculating the HMAC, generates an ESP header and inserts it before the encrypted IP packet. The ESP protocol also generates an ESP trailer and inserts it at the end of the packet.
The IPSec protocol then encapsulates the resulting packet by adding an IP header before the ESP header. In the IP header, the destination IP address is set to the IP address of the CloudBridge Connecter peer.
Peers in the CloudBridge Connector tunnel use the Internet Key Exchange version 1 (IKEv1) protocol (part of the IPSec protocol suite) to negotiate secure communication, as follows:
The two peers mutually authenticate with each other, using pre-shared key authentication, in which the peers exchange a text string called a pre-shared key (PSK). The pre-shared keys are matched against each other for authentication. Therefore, for the authentication to be successful, you must configure the same pre-shared key on each of the peers.
The peers then negotiate to reach agreement on:
- An encryption algorithm
- Cryptographic keys for encrypting data on one peer and decrypting it on the other.
This agreement upon the security protocol, encryption algorithm and cryptographic keys is called a Security Association (SA). SAs are one-way (simplex). For example, when a CloudBridge Connector tunnel is set up between a Citrix ADC appliance in a datacenter and a gateway in an Azure cloud, both the datacenter appliance and the Azure gateway have two SAs. One SA is used for processing out-bound packets, and the other SA is used for processing inbound packets. SAs expire after a specified interval of time, which is called the lifetime.
Example of CloudBridge Connector tunnel configuration and data flow
As an illustration of CloudBridge Connector Tunnel, consider an example in which a CloudBridge Connector tunnel is set up between Citrix ADC appliance CB_Appliance-1 in a datacenter and gateway Azure_Gateway-1 in Azure cloud.
CB_Appliance-1 also functions as an L3 router, which enables a private network in the datacenter to reach a private network in the Azure cloud through the CloudBridge Connector tunnel. As a router, CB_Appliance-1 enables communication between client CL1 in the datacenter and server S1 in the Azure cloud through the CloudBridge Connector tunnel. Client CL1 and server S1 are on different private networks.
On CB_Appliance-1, the CloudBridge Connector tunnel configuration includes an IPSec profile entity named CB_Azure_IPSec_Profile, a CloudBridge Connector tunnel entity named CB_Azure_Tunnel, and a policy based routing (PBR) entity named CB_Azure_Pbr.
The IPSec profile entity CB_Azure_IPSec_Profile specifies the IPSec protocol parameters, such as IKE version, encryption algorithm, and hash algorithm, to be used by the IPSec protocol in the CloudBridge Connector tunnel. CB_Azure_IPSec_Profile is bound to IP tunnel entity CB_Azure_Tunnel.
CloudBridge Connector tunnel entity CB_Azure_Tunnel specifies the local IP address (a public IP (SNIP) address configured on the Citrix ADC appliance), the remote IP address (the IP address of the Azure_Gateway-1), and the protocol (IPSec) used to set up the CloudBridge Connector tunnel. CB_Azure_Tunnel is bound to the PBR entity CB_Azure_Pbr.
The PBR entity CB_Azure_Pbr specifies a set of conditions and a CloudBridge Connector tunnel entity (CB_Azure_Tunnel). The source IP address range and the destination IP address range are the conditions for CB_Azure_Pbr. The source IP address range and the destination IP address range are specified as a subnet in the datacenter and a subnet in the Azure cloud, respectively. Any request packet originating from a client in the subnet in the datacenter and destined to a server in the subnet on the Azure cloud matches the conditions in CB_Azure_Pbr. This packet is then considered for CloudBridge processing and is sent across the CloudBridge Connector tunnel (CB_Azure_Tunnel) bound to the PBR entity.
On Microsoft Azure, the CloudBridge Connector tunnel configuration includes a local network entity named My-Datacenter-Network, a virtual network entity named Azure-Network-for-CloudBridge-Tunnel, and a gateway named Azure_Gateway-1.
The local (local to Azure) network entity My-Datacenter-Network specifies the IP address of the Citrix ADC appliance on the datacenter side, and the datacenter subnet whose traffic is to traverse the CloudBridge Connector tunnel. The virtual network entity Azure-Network-for-CloudBridge-Tunnel defines a private subnet named Azure-Subnet-1 in Azure. The traffic of the subnet traverses the CloudBridge Connector tunnel. The server S1 is provisioned in this subnet.
The local network entity My-Datacenter-Network is associated with the virtual network entity Azure-Network-for-CloudBridge-Tunnel. This association defines the remote and local network details of the CloudBridge Connector tunnel configuration in Azure. Gateway Azure_Gateway-1 was created for this association to become the CloudBridge end point at the Azure end of the CloudBridge Connector tunnel.
For more information about the settings, refer to theCloudBridge Connector Tunnel Settingspdf.
Points to consider for a CloudBridge Connector tunnel configuration
Before configuring a CloudBridge Connector tunnel between a Citrix ADC appliance in datacenter and Microsoft Azure, consider the following points:
- The Citrix ADC appliance must have a public facing IPv4 address (type SNIP) to use as a tunnel end-point address for the CloudBridge Connector tunnel. Also, the Citrix ADC appliance should not be behind a NAT device.
- Azure supports the following IPSec settings for a CloudBridge Connector tunnel. Therefore, you must specify the same IPSec settings while configuring the Citrix ADC for the CloudBridge Connector tunnel.
- IKE version = v1
- Encryption algorithm = AES
- Hash algorithm = HMAC SHA1
- You must configure the firewall in the datacenter edge to allow the following.
- Any UDP packets for port 500
- Any UDP packets for port 4500
- Any ESP (IP protocol number 50) packets
- IKE re-keying, which is renegotiation of new cryptographic keys between the CloudBridge Connector tunnel end points to establish new SAs, is not supported. When the Security Associations (SAs) expire, the tunnel goes into the DOWN state. Therefore, you must set a very large value for the lifetimes of SAs.
- You must configure Microsoft Azure before specifying the tunnel configuration on the Citrix ADC, because the public IP address of the Azure end (gateway) of the tunnel, and the PSK, are automatically generated when you set up the tunnel configuration in Azure. You need this information for specifying the tunnel configuration on the Citrix ADC.
Configuring the CloudBridge Connector tunnel
For setting up a CloudBridge Connector tunnel between your datacenter and Azure, you must install CloudBridge VPX/MPX in your datacenter, configure Microsoft Azure for the CloudBridge Connector tunnel, and then configure the Citrix ADC appliance in the data center for the CloudBridge Connector tunnel.
Configuring a CloudBridge Connector tunnel between a Citrix ADC appliance in datacenter and Microsoft Azure consists of the following tasks:
- Setting up the Citrix ADC appliance in the datacenter. This task involves deploying and configuring a Citrix ADC physical appliance (MPX), or provisioning and configuring a Citrix ADC virtual appliance (VPX) on a virtualization platform in the datacenter.
- Configuring Microsoft Azure for the CloudBridge Connector tunnel. This task involves creating local network, virtual network, and gateway entities in Azure. The local network entity specifies the IP address of the CloudBridge Connector tunnel end point (the Citrix ADC appliance) on the datacenter side, and the datacenter subnet whose traffic is to traverse the CloudBridge Connector tunnel. The virtual network defines a network on Azure. Creating the virtual network includes defining a subnet whose traffic is to traverse the CloudBridge Connector tunnel to be formed. You then associate the local network with the virtual network. Finally, you create a gateway that becomes the end point at the Azure end of the CloudBridge Connector tunnel.
- Configuring the Citrix ADC appliance in the datacenter for the CloudBridge Connector tunnel. This task involves creating an IPSec profile, an IP tunnel entity, and a PBR entity in the Citrix ADC appliance in datacenter. The IPSec profile entity specifies the IPSec protocol parameters, such as IKE version, encryption algorithm, hash algorithm, and PSK, to be used in the CloudBridge Connector tunnel. The IP tunnel specifies the IP address of both the CloudBridge Connector tunnel end points (the Citrix ADC appliance in datacenter and the gateway in Azure) and the protocol to be used in the CloudBridge Connector tunnel. You then associate the IPSec profile entity with the IP tunnel entity. The PBR entity specifies the two subnets, in the datacenter and in the Azure cloud, that are to communicate with each other through the CloudBridge Connector tunnel. You then associate the IP tunnel entity with the PBR entity.
Configuring Microsoft Azure for the CloudBridge Connector tunnel
To create a CloudBridge Connector tunnel configuration on Microsoft Azure, use the Microsoft Windows Azure Management Portal, which is a web based graphical interface for creating and managing resources on Microsoft Azure.
Before you begin the CloudBridge Connector tunnel configuration on Azure cloud, make sure that:
- You have a user account for Microsoft Azure.
- You have a conceptual understanding of Microsoft Azure.
- You are familiar with the Microsoft Windows Azure Management Portal.
To configure a CloudBridge Connector tunnel between a datacenter and an Azure cloud, perform the following tasks on Microsoft Azure by using the Microsoft Windows Azure Management Portal:
- Create a local network entity. Create a local network entity in Windows Azure for specifying the network details of the datacenter. A local network entity specifies the IP address of the CloudBridge Connector tunnel end point (the Citrix ADC) on the datacenter side and the datacenter subnet whose traffic is to traverse the CloudBridge Connector tunnel.
- Create a Virtual Network. Create virtual network entity that defines a network on Azure. This task includes defining a private address space, where you provide a range of private addresses and subnets belonging to the range specified in the address space. The traffic of the subnets will traverse the CloudBridge Connector tunnel. You then associate a local network entity with the virtual network entity. This association lets Azure create a configuration for a CloudBridge Connector tunnel between the virtual network and the data center network. A gateway (to be created) in Azure for this virtual network will be the CloudBridge end point at the Azure end of the CloudBridge Connector tunnel. You then define a private subnet for the gateway to be created. This subnet belongs to the range specified in the address space in the virtual network entity.
- Create a gateway in Windows Azure. Create a gateway that becomes the end point at the Azure end of the CloudBridge Connector tunnel. Azure, from its pool of public IP addresses, assigns an IP address to the gateway created.
- Gather the public IP address of the gateway and the pre-shared key.For a CloudBridge Connector tunnel configuration on Azure, the public IP address of the gateway and the pre-shared Key (PSK) are automatically generated by Azure. Make a note of this information. You will need it for configuring the CloudBridge Connector tunnel on the Citrix ADC in datacenter.
Note:
The procedures for configuring Microsoft Azure for a CloudBridge Connector tunnel might change over time, depending on the Microsoft Azure release cycle. For the latest procedures, see theMicrosoft Azure documentation.
Configuring the Citrix ADC Appliance in the datacenter for the CloudBridge Connector tunnel
To configure a CloudBridge Connector tunnel between a datacenter and an Azure cloud, perform the following tasks on the Citrix ADC in the datacenter. You can use either the Citrix ADC command line or the GUI:
- Create an IPSec profile. An IPSec profile entity specifies the IPSec protocol parameters, such as IKE version, encryption algorithm, hash algorithm, and PSK, to be used by the IPSec protocol in the CloudBridge Connector tunnel.
- Create an IP tunnel with IPSec protocol and associate the IPSec profile to it. An IP tunnel specifies the local IP address (a public SNIP address configured on the Citrix ADC appliance), remote IP address (the public IP address of the gateway in Azure), protocol (IPSec) used to set up the CloudBridge Connector tunnel, and an IPSec profile entity. The created IP tunnel entity is also called the CloudBridge Connector tunnel entity.
- Create a PBR rule and associate the IP tunnel to it. A PBR entity specifies a set of conditions and an IP tunnel (CloudBridge Connector tunnel) entity. The source IP address range and the destination IP range are the conditions for the PBR entity. You must set the source IP address range to specify the datacenter subnet whose traffic is to traverse the tunnel, and the destination IP address range to specify the Azure subnet whose traffic is to traverse the CloudBridge Connector tunnel. Any request packet originated from a client in the subnet on the datacenter and destined to a server in the subnet on the Azure cloud matches the source and destination IP range of the PBR entity. This packet is then considered for CloudBridge Connector tunnel processing and is sent across sent across the CloudBridge Connector tunnel associated with the PBR entity.
The GUI combines all these tasks in a single wizard called the CloudBridge Connector wizard. To create an IPSEC profile by using the Citrix ADC command line:
At the Command prompt, type:
add ipsec profile
To create an IPSEC tunnel and bind the IPSEC profile to it by using the Citrix ADC command line:
At the Command prompt, type:
add ipTunnel
To create a PBR rule and bind the IPSEC tunnel to it by using the Citrix ADC command line
add pbr
Sample Configuration
The following commands create all settings of Citrix ADC appliance CB_Appliance-1 used in “Example of CloudBridge Connector Configuration and Data Flow”.
> add ipsec profile CB_Azure_IPSec_Profile -psk DkiMgMdcbqvYREEuIvxsbKkW0FOyDiLM -ikeVersion v1 –lifetime 31536000 Done > add iptunnel CB_Azure_Tunnel 168.63.252.133 255.255.255.255 66.165.176.15 –protocol IPSEC –ipsecProfileName CB_Azure_IPSec_Profile Done > add pbr CB_Azure_Pbr -srcIP 10.102.147.0-10.102.147.255 –destIP 10.20.0.0-10.20.255.255 –ipTunnelCB_Azure_Tunnel Done > apply pbrs Done
To configure a CloudBridge Connector tunnel in a Citrix ADC appliance by using the GUI
Access the GUI by using a web browser to connect to the IP address of the Citrix ADC appliance in the datacenter.
Navigate toSystem>CloudBridge Connector.
In the right pane, underGetting Started, clickCreate/Monitor CloudBridge.
ClickGet Started.
Note: If you already have any CloudBridge Connector tunnel configured on the Citrix ADC appliance, this screen does not appear, and you are taken to the CloudBridge Connector Setup pane.
In the CloudBridge Setup pane, clickMicrosoft Windows Azure.
In the Azure Settings pane, in theGateway IP Addressfield, type the IP address of the Azure gateway. The CloudBridge Connector tunnel is then set up between the Citrix ADC appliance and the gateway. In theSubnet (IP Range)text boxes, specify a subnet range (in Azure cloud), the traffic of which is to traverse the CloudBridge Connector tunnel. ClickContinue.
In the Citrix ADC Settings pane, from theLocal Subnet IPdrop-down list, select a publicly accessible SNIP address configured on the Citrix ADC appliance. InSubnet (IP Range)text boxes, specify a local subnet range, the traffic of which is to traverse the CloudBridge Connector tunnel. ClickContinue.
In theCloudBridge Settingpane, in the CloudBridge Name text box, type a name for the CloudBridge that you want to create.
From the Encryption Algorithm and Hash Algorithm drop-down lists, select the AES and HMAC_SHA1 algorithms, respectively. In the Pre Shared Security Key text box, type the security key.
ClickDone.
Monitoring the CloudBridge Connector tunnel
You can view statistics for monitoring the performance of a CloudBridge Connector tunnel between the Citrix ADC appliance in the datacenter and Microsoft Azure. To view CloudBridge Connector tunnel statistics on the Citrix ADC appliance, use GUI or Citrix ADC command line. To view CloudBridge Connector tunnel statistics in Microsoft Azure, use the Microsoft Windows Azure Management Portal.
Displaying CloudBridge Connector tunnel Statistics in the Citrix ADC appliance
For information about displaying CloudBridge Connector tunnel statistics on a Citrix ADC appliance, seeMonitoring CloudBridge Connector Tunnels.
Displaying CloudBridge Connector tunnel Statistics in Microsoft Azure
The following table lists the statistical counters available for monitoring CloudBridge Connector tunnels in Microsoft Azure.
Statistical counter | Specifies |
---|---|
DATA IN | Azure收到的字节总数teway through the CloudBridge Connector tunnel since the gateway was created. |
DATA OUT | Total number of kilobytes sent by the Azure gateway through the CloudBridge Connector tunnel since the gateway was created. |
To display CloudBridge Connector tunnel statistics by using the Microsoft Windows Azure Management Portal
Log on to theWindows Azure Management Portalby using your Microsoft Azure account credentials.
In the left pane, clickNETWORKS.
On theVirtual Networktab, in the Name column, select the virtual network entity associated with a CloudBridge Connector tunnel whose statistics you want to display.
On theDASHBOARDpage of the virtual network, view the DATA IN and DATA OUT counters for the CloudBridge Connector tunnel.