Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $ch = curl_init();
- $url = "http://127.0.0.1/test/test.cgi?ip=127.0.0.1&user=USERNAME&password=PASSWORD&submit=Update";
- curl_setopt($ch, CURLOPT_URL, $url);
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt($ch, CURLOPT_USERPWD, "$LOGIN:$PASSWORD");
- curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_ANY);
- curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
- curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
- curl_setopt($ch, CURLOPT_UNRESTRICTED_AUTH, 1);
- $result=curl_exec($ch);
- var_dump($result);
Add Comment
Please, Sign In to add comment