Created
November 22, 2013 15:24
-
-
Save tonijz/7601659 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
header('content-type:text/plain'); | |
$curl = curl_init(); | |
curl_setopt($curl, CURLOPT_URL, 'http://10.10.10.2/Web/Common/Login.do'); | |
curl_setopt($curl, CURLOPT_POST, 1); | |
curl_setopt($curl, CURLOPT_POSTFIELDS, 'username=mvfadmin&password=mvfadmin&submitType=LOGIN'); | |
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, 1); | |
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); | |
curl_setopt($curl, CURLOPT_COOKIEJAR, '/tmp/cisco_cookie.txt'); | |
curl_exec($curl); | |
curl_setopt($curl, CURLOPT_URL, 'http://10.10.10.2/Web/cme/LayoutAction.do?submitType=INIT&page=displayCallHistory'); | |
curl_exec($curl); | |
curl_setopt($curl, CURLOPT_URL, 'http://10.10.10.2/Web/ITS/ipkeyswitch.do'); | |
echo curl_exec($curl); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment