Cisco 11503 Administration Guide - Page 326
HTTP Authentication Keepalive, Parameters: HostName Web Username-Password
UPC - 746320664958
View all Cisco 11503 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 326 highlights
Script Keepalive Examples Chapter 8 Using the CSS Scripting Language ! Done no set EXIT_MSG socket disconnect ${SOCKET} exit script 0 HTTP Authentication Keepalive !no echo ! Filename: ap-kal-httpauth ! Parameters: HostName WebPage Username-Password ! ! Description: ! This will keepalive an authentication connection by building ! a get request with the Authentication field filled with the ! Username-Password string formatted like so: "bob:mypassword" ! This is critical to make the authentication base64 hash work ! correctly. ! ! Note: This script authentication is based on HTTP AUTHENTICATION ! RFC-2617. Currently only supported option is "Basic" ! authentication using base64 encoding. "Digest" Access is ! not supported at this time. ! ! Failure Upon: ! 1. Not establishing a connection with the host. ! 2. Not being able authenticated with the Username-Password ! (not being given a status code of "200 OK" if ${ARGS}[#] "NEQ" "3" echo "Usage: ap-kal-httpauth \'Hostname WebPage Username:Password\'" echo "(Ie. ap-kal-httpauth \'192.168.1.1 /index.html bob:mypassword\')" exit script 1 endbranch ! Defines: set HostName "${ARGS}[1]" set WebPage "${ARGS}[2]" set UserPass "${ARGS}[3]" ! Connect to the remote Host set EXIT_MSG "Connection Failure" socket connect host ${HostName} port 80 tcp 8-58 Cisco Content Services Switch Administration Guide OL-5647-02