WiFi Password-free login authentication process

Source: Internet
Author: User

Your query keywords are: weixin:,qrgex_zm-The following is the webpage in Beijing time March 27, 2016 02:46:42 snapshot;

If you open slowly, you can try the quick version, if you want to save the snapshot, you can add to the search, if you want to update or delete the snapshot, you can complain about the snapshot.

Baidu has nothing to do with the authors of Web http://c.anywifi.com/wiki/user/auth.html, and is not responsible for its content. Baidu snapshot for the network failure index, does not represent the search site's immediate page.
    • Help documentation
    • Landing
    • Quick Start
    • System User Manual
    • Template Production Manual
    • User Login Interface
    • RESTful API
    • Contact Us
User login interface [Access Authorization]

During our device firmware production , we used the same portal authentication technology as most telecom operators , where the system architecture was primarily accessed by APS wirelessly access the access point (Wireless access Point),AC Access controller (Wireless accesspoint Controller), Authentication page Server (captive Portal server) , Certified Billing Server (Cloud Radius server) , and in the cloud , we completed the cloud storage of the portal page ,Captive Portal page Online editing ,Portal static file CDN Acceleration , and Internet User Data analysis and display , The RADIUS server is also connected to the third-party account system through the OAUTH2.0 protocol.

Portal certification:

What do you need to do?

You only need to complete the portal page with the AC Access Controller (Router) LAN communication , and in the router firmware we configure the RADIUS client The authentication request is sent to the authentication billing server instead of the network access requestor , and The authentication result is returned.

The communication between the portal page and the AC Access Controller (Router) is done through the JSON Api , and to facilitate your rapid development , We provide the JavaScript Library , you only need to introduce a JS file to customize your account certification by simply writing JavaScript code, all of which can be done online by editing the code .

What should you do?

First, edit the authentication page template , introduce JS file

<script src= "Http://s.anywifi.com/resources/anywifiLibrary.js" ></script>

Note: Please do not download and save the file , we will update the library regularly.

Second, several common authentication methods

1. Anonymous Login (Guest mode)

Anonymous Login interface function:anonymousLogin();

Before the Internet users can not pass the authentication , may be in the Guest mode to obtain a short network access rights , or you just need to click on a link to the Internet , Here you can use the anonymous login implementation (anonymous login access to the network access from time to time, bandwidth can be set in the management platform online user-user group).

Example

<!doctype html>to free internet access. </p></body>

Of course , you can also use the JS timer to display the open page (click the button) n seconds after the automatic landing , the effect is as follows:

The code is as follows:

 <!doctype html>,  1000);} </script>

2. Login

Login Interface Address: http://c.anywifi.com/api/weixinlogin?uid=<平台账户UID> ("< platform account uid>" need <a "http:=" "c.anywifi.com=" "user=" "login.html" = "target=" _blank "> Landing platform after display)

The above login interface address , applicable to the Internet Authentication page prompts the user to follow an account , then the account in the user's attention after the automatic reply to the address link , the user use Click this link , will automatically invoke the JS login interface function , complete a key focus on the Internet , if not in the access to this API address , will appear please open the client prompt .

One click on the Internet :

Login interface Function:webchatLogin();

Get page Promotion account: http://c.anywifi.com/api/weixinname?nasid=[NASID] (the NASID parameter can be obtained from the URL's get query string)

Login interface function is different from the anonymous login interface , mainly because the management platform can be set up for the two user groups of different constant , bandwidth Group Properties , login interface , We usually use the browser's UA ( browser user-agent ) to determine whether to click on this link in the browser, view this page , decide whether to network access , the above-mentioned focus on one-click Internet interface is implemented by this idea.

Example

<!doctype html>,"Http://c.anywifi.com/api/weixinname?nasid=" +nasid+ "&t=" +math.random (),function () {if (xmlhttp.readystate==4 && xmlhttp.status==200) {Getel (' wx_name '). InnerHTML = (Xmlhttp.responsetext;});}); </script>,2000);    }else {getel (' Forpc '). style.display= ' block '; }}else{Getel (' Forpc '). style.display= ' block ';} </script></body>

3, mobile phone number login

Mobile phone Number Login interface function:userLogin(mobilephone,password);

Get Login Verification Code:http://c.anywifi.com/api/mobilephone?nasid=[NASID]&mobilephone=[MOBILEPHONE]&mac=[MAC]&ap=[AP]
(where Nasid, Mobilephone, MAC, AP parameters can be obtained from the form or query string)

Use mobile phone number as account login, Internet users need to fill in mobile phone number , by requesting to obtain a mobile phone number verification password , and then fill in the verification password to login (to obtain the verification password required downlink SMS , the registered account by default 50 , you can purchase SMS through the Platform account , Internet users mobile phone number information can be viewed from the background view)

Mobile Phone Number login :

Example code :

<!doctype html>,Getel ("code"). value);};/    /Get SMS Verification password function Getphonecode () {var nasid = getquerystring (' Nasid ');    var mac = getquerystring (' mac ');    var ap = getquerystring (' called ');    var mobilephone = Getel ("Phone"). Value; if (/^1\d{10}$/g.test (mobilephone)) {ajaxload ("GET","/http" +admindomain+ "/api/mobilephone?nasid=" +nasid+ "&mobilephone=" +mobilephone+ "&mac=" +mac+ "&ap = "+ap+" &t= "+math.random (),function () {if (xmlhttp.readystate==4 && xmlhttp.status==200) {if (xmlhttp.responsetext==                "SUCCESS") {alert (' SMS Verification Code sent '); }else if (xmlhttp.responsetext== "overload") {alert (' SMS Sent,Please wait a moment ... ');                }else{alert (xmlhttp.responsetext);    }            }        });        }else{alert (' cell phone number format is incorrect ');    Getel ("Phone"). Value = ';    }}</script>

WiFi Password-free login authentication process

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.