Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // Myandrive / Gdrive Downloader Plugin
- //[8-07-2018] Written by l33tb0mb3r(MHU | MDY_l33ts)
- // Change "yourmail@gmail.com" & "password" to your crediential that used to signup in myandrive.net
- if (!defined('RAPIDLEECH')) {
- require_once('index.html');
- exit;
- }
- class myandrive_net extends DownloadClass {
- public $link;
- private $cookie, $fid, $dlink;
- public function Download($link) {
- $cookie = 'PHPSESSID='.md5(microtime(true));
- // Signin
- $this->Signin($cookie);
- if(!preg_match('/\/file\/(\w+)/', $link, $fid)) html_error('URL not valid!');
- $ch = curl_init();
- curl_setopt($ch, CURLOPT_URL,"https://myandrive.net/post");
- curl_setopt($ch, CURLOPT_COOKIE, $cookie);
- curl_setopt($ch, CURLOPT_POST, 1);
- curl_setopt($ch, CURLOPT_POSTFIELDS,
- http_build_query(array('fileid' => $fid[1], 'key' => 'download')));
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- $result = curl_exec ($ch);
- curl_close ($ch);
- if($result === false) html_error('Curl error: '.curl_error($ch));
- $result=json_decode($result,true);
- $dlink = $result['redirect'];
- $fname = urldecode(basename(parse_url($dlink, PHP_URL_PATH)));
- if(empty($result['redirect'])) html_error(json_encode($result));
- return $this->RedirectDownload($dlink,$fname);
- }
- private function Signin($cookie) {
- $ch = curl_init();
- curl_setopt($ch, CURLOPT_URL,"https://myandrive.net/post");
- curl_setopt($ch, CURLOPT_COOKIE, $cookie);
- curl_setopt($ch, CURLOPT_POST, 1);
- curl_setopt($ch, CURLOPT_POSTFIELDS,
- http_build_query(array('email' => 'yourmail@gmail.com', 'password' => 'password', 'key' => 'signin')));
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- $result = curl_exec ($ch);
- curl_close ($ch);
- if($result === false) html_error('Signin Error'.curl_error($ch));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement