Guest User

Untitled

a guest
Jun 21st, 2012
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. $cookie = sys_get_temp_dir().'/m2fcookie.txt';
  2. $url = 'https://'.$this->wikid_host.'/WiKIDAdmin/j_security_check';
  3. $postfields = array(
  4. 'j_username' => $this->wikidadmin_user,
  5. 'j_password' => $this->wikidadmin_pass
  6. );
  7. curl_setopt($ch, CURLOPT_URL, $url);
  8. curl_setopt($ch, CURLOPT_POST, true);
  9. curl_setopt($ch, CURLOPT_TIMEOUT, 300);
  10. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  11. curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie);
  12. curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields);
  13. curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
  14. curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
  15. $data = curl_exec($ch);
Advertisement
Add Comment
Please, Sign In to add comment