AAA, NAC, Guest Access & BYOD

How to configure ClearPass Guest with Link Mobility SMS Gateway

by ‎09-01-2016 09:42 AM - edited ‎09-01-2016 09:42 AM
Requirement:

How to configure ClearPass Guest with Link Mobility SMS Gateway for Sending SMS.



Solution:

Link Mobility is a SMS provider that we can integrate ClearPass Guest for delivering SMS receipts. It operates using custom HTTP handler of the SMS receipt in JSON format. As SMS gateways are very particular with encoding/decoding options, posting the JSON data in an incorrect format, may not be processed properly and may not be able to deliver the SMS receipts to the end users.



Configuration:

In this article, we will go through the appropriate steps to integrate ClearPass Guest with Link Mobility as an SMS provider.

 

1. Login to ClearPass Guest as a Super Administrator. 

2. Navigate to Home » Configuration » SMS Services » Gateways.

3. Create a new SMS Gateway for  Link Mobility using Custom HTTP handler as shown in the screenshot below:

Link Mobility SMS Gateway Configuration:

 

As shown above:

 1. Input the Service URL as given by Link Mobility and set the HTTP method as POST(of SMS receipt in JSON format).

2. Include the Content type as application/JSON and input the Authorization information.

3. In the HTTP Post, following is the HTTP post in JSON format. Below is an example:

{
"source":"@FROM@", 
"destination":"@TO@", 
"userData":"@MESSAGE@", 
"platformId":"COMMON_API", 
"platformPartnerId":"xxxxx", 
"useDeliveryReport":false
}

4. Select the HTTP basic authentication and input service username/password given by the provider.

5. Enter the country code details, prefix as applicable.



Verification

Couple of things to note here:

1. Specify the content type as JSON data in HTTP header.

2. Note that the Member-key userdata only takes a string value Object-value pair from the contents of the SMS receipt in the HTTP post. i.e "userData":"@MESSAGE@" . 

The default SMS receipt Header HTML will look as below:

Username: {$u.username|escape}
Password: {$u.password|escape}
{if $u.expire_time > 0}Expires: {$u.expire_time|nwadateformat:"iso-8601t"|escape}{/if}

As this HTTP post is in JSON format, if we post userdata with default SMS receipt content(as above), the HTTP post might become invalid for the SMS provider and they will not be able to deliver the message. 

With the default SMS receipt, the post is invalid i.e SMS provider returns HTTP error 400 - bad request and unable to deliver the message as shown in the below packet capture screenshot.

To make the HTTP post successful, we need to include line breaks in the SMS receipt header HTML as shown below. By including line breaks in User account HTML, we will be able to complete the HTTP post successful.

Username : {$u.username|escape} \r\n Password: {$u.password|escape} \r\n Expires:{$u.expire_time|nwadateformat:"%a %d %b %H:%M"|escape} \r\n

With the above change to the SMS receipt along with no header/footer in SMS receipt will result in a successful HTTP post of JSON data.  Including header/Footer would result in incorrect data.

 

Search Airheads
Showing results for 
Search instead for 
Did you mean: 
Is this a frequent problem?

Request an official Aruba knowledge base article to be written by our experts.