Wireless Controller
Dedicated Wi-Fi control and management for high density and mobility
nsamuel
Staff
Staff
Article Id 197465
Description

How to Redirect Captive portal user to a specific URL after the successful webauth authentication?


Scope

KB ARTICLE TYPE: configuration, Troubleshooting

RELATED PRODUCTS: controller,

RELATED SOFTWARE VERSIONS: 5.x,6.x,7.x

KEYWORDS: controller, captive portal, post-auth redirection


Solution

You can customize the captive portal by editing the default HTML pages that you can download from the controller. Once after the Web authentication is successful, the web page can be redirected to a specific URL by editing one of the HTML page downloaded from the controller by following the below instructions.


To know the basic information on how to Customize the default captive portal page on changing the picture or to embed the password in the HTML page, please take a look at the related KB article "Customizing the Splash Screen (Captive Portal screen)".

CONFIGURATION STEPS:

STEP 1: To redirect a captive portal user to a specific URL, perform the following changes to the "auth_web_ok.html" page that you have downloaded from the controller. You can download the HTML files from the GUI of the controller following the below steps.
            a. Click "Maintenance" >> "Captive Portal" >> "Customization".
            b. Click the "Get Files" button to download a .tar file of the .html files that can be customized.

STEP 2: Open the "auth_web_ok.html" page's source code. Replace "^url^" in the source code of the page to the URL to which the user has to be redirected. (E.g: URL of the School, university, hospital,.)

STEP 3: For reference, the HTML code from the default "auth_web_ok.html" page and the edited "auth_web_ok.html" page are given below.

1.       Default Page Code:

<HTML>

<HEAD>

<TITLE>Meru Networks, Inc</TITLE>

<LINK href="Styles.vpn/css.css" type=text/css rel=stylesheet>

<SCRIPT language=JavaScript type=text/javascript>

function onLoad() {

setTimeout("location.href='^url^'", 1*1000)


Replace the ^url^ part in the source code to desired URL

 

2.       Edited Page Code

For example: Redirect to- http://www.fortinet.com

<HTML>

      <HEAD>

      <TITLE>Meru Networks, Inc</TITLE>

      <LINK href="Styles.vpn/css.css" type=text/css rel=stylesheet>

      <SCRIPT language=JavaScript type=text/javascript>

       function onLoad() {

setTimeout("location.href='http://www.fortinet.com'", 1*1000)

TEST RESULTS: 
When the ^url^ in the auth_web_ok.html page is replaced with a URL, once the user gets the authenticated either by entering the credentials manually or by hitting the submit/accept button in the customized webauth page, the user will be redirected to the URL specified in the "auth_web_ok.html" page.


Related Articles

Meru Technical Note - Customizing the Splash Screen (Captive Portal screen)

Contributors