--- /dev/null
+<?php
+@ob_start();
+if(!isset($_GET['act'])) { $_GET['act'] = "url"; }
+if($_GET['act']=="download") { $_GET['act'] = "get"; }
+if($_GET['act']=="view") { $_GET['act'] = "get"; }
+if($_GET['act']=="geturl") { $_GET['act'] = "url"; }
+if($_GET['act']=="viewurl") { $_GET['act'] = "url"; }
+if($_GET['act']=="redir") { $_GET['act'] = "goto"; }
+if($_GET['act']=="redirect") { $_GET['act'] = "goto"; }
+if($_GET['act']=="location") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gourl") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gotourl") { $_GET['act'] = "goto"; }
+$default_opts = array(
+ 'http'=>array(
+ 'method'=>"GET",
+ 'header'=>"User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20100101 Firefox/10.0\r\n".
+ "Referer: http://beeg.com/".$_GET['v']."\r\n"
+ )
+);
+$default = stream_context_set_default($default_opts);
+if($_GET['act']=="url") {
+ header("Content-type: text/plain; charset=utf-8");
+ $get_value = file_get_contents("http://beeg.com/".$_GET['v']);
+ $preg_grep_1 = preg_quote("'file': '");
+ $preg_grep_2 = preg_quote("',");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ echo $get_value; }
+if($_GET['act']=="goto") {
+ header("Content-type: text/plain; charset=utf-8");
+ $get_value = file_get_contents("http://beeg.com/".$_GET['v']);
+ $preg_grep_1 = preg_quote("'file': '");
+ $preg_grep_2 = preg_quote("',");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ header("Location: ".$get_value);
+ echo $get_value; }
+if($_GET['act']=="get") {
+ $get_value = file_get_contents("http://beeg.com/".$_GET['v']);
+ $preg_grep_1 = preg_quote("'file': '");
+ $preg_grep_2 = preg_quote("',");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ $getvidheaders = get_headers($get_value, 1);
+ header("Content-Type: ".$getvidheaders['Content-Type']);
+ echo file_get_contents($get_value); }
+?>
--- /dev/null
+#!/usr/bin/env python
+
+'''
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the Revised BSD License.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ Revised BSD License for more details.
+
+ Copyright 2013 Cool Dude 2k - http://idb.berlios.de/
+ Copyright 2013 Game Maker 2k - http://intdb.sourceforge.net/
+ Copyright 2013 Kazuki Przyborowski - https://github.com/KazukiPrzyborowski
+
+ $FileInfo: beeg-dl.py - Last Update: 05/11/2013 Ver. 1.0.5 RC 5 - Author: cooldude2k $
+'''
+
+import re, os, sys, httplib, urllib, urllib2, cookielib, StringIO, gzip, time, datetime, argparse;
+
+parser = argparse.ArgumentParser();
+parser.add_argument("url", help="beeg url");
+getargs = parser.parse_args();
+mlessvid = getargs.url;
+mregex_text = re.escape("http://beeg.com/")+"([a-zA-Z0-9\/]+)";
+if(re.findall(mregex_text, mlessvid)):
+ mlessvid = re.findall(mregex_text, mlessvid);
+ mlessvid = mlessvid[0];
+fakeua = "Mozilla/5.0 (Windows NT 5.1; rv:20.0) Gecko/20100101 Firefox/20.0";
+geturls_cj = cookielib.CookieJar();
+geturls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(geturls_cj));
+geturls_opener.addheaders = [("Referer", "http://beeg.com/section/long-videos/"), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+geturls_text = geturls_opener.open("http://beeg.com/"+mlessvid);
+if(geturls_text.info().get("Content-Encoding")=="gzip" or geturls_text.info().get("Content-Encoding")=="deflate"):
+ strbuf = StringIO.StringIO(geturls_text.read());
+ gzstrbuf = gzip.GzipFile(fileobj=strbuf);
+ out_text = gzstrbuf.read()[:];
+if(geturls_text.info().get("Content-Encoding")!="gzip" and geturls_text.info().get("Content-Encoding")!="deflate"):
+ out_text = geturls_text.read()[:];
+regex_text = re.escape("'file': '")+"(.*)"+re.escape("',");
+post_text = re.findall(regex_text, out_text);
+if(post_text>0):
+ mlesslink = post_text[0]+"?start=0";
+ print(mlesslink);
+ '''
+ getvidurls_cj = cookielib.CookieJar();
+ getvidurls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(getvidurls_cj));
+ getvidurls_opener.addheaders = [("Referer", "http://beeg.com/"+mlessvid), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+ getvidurls_text = getvidurls_opener.open(mlesslink);
+ def chunk_report(bytes_so_far, chunk_size, total_size):
+ percent = float(bytes_so_far) / total_size;
+ percent = round(percent*100, 2);
+ sys.stdout.write("Downloaded %d of %d bytes (%0.2f%%)\r" %
+ (bytes_so_far, total_size, percent));
+ if bytes_so_far >= total_size:
+ sys.stdout.write("\n");
+ def chunk_read(response, chunk_size=8192, report_hook=None):
+ total_size = response.info().getheader("Content-Length").strip();
+ total_size = int(total_size);
+ bytes_so_far = 0;
+ while 1:
+ chunk = response.read(chunk_size);
+ bytes_so_far += len(chunk);
+ if not chunk:
+ break;
+ if report_hook:
+ report_hook(bytes_so_far, chunk_size, total_size);
+ return bytes_so_far;
+ chunk_read(getvidurls_text, report_hook=chunk_report);
+ vidfile = open(os.getcwd()+os.sep+os.path.basename(urllib2.urlparse.urlsplit(mlesslink)[2]), "wb");
+ vidfile.write(getvidurls_text.read());
+ vidfile.close();
+ '''
--- /dev/null
+#!/usr/bin/env python
+
+'''
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the Revised BSD License.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ Revised BSD License for more details.
+
+ Copyright 2013 Cool Dude 2k - http://idb.berlios.de/
+ Copyright 2013 Game Maker 2k - http://intdb.sourceforge.net/
+ Copyright 2013 Kazuki Przyborowski - https://github.com/KazukiPrzyborowski
+
+ $FileInfo: get_ylp.py - Last Update: 05/11/2013 Ver. 1.0.5 RC 5 - Author: cooldude2k $
+'''
+
+import re, os, sys, httplib, urllib, urllib2, cookielib, StringIO, gzip, time, datetime;
+
+fakeua = "Mozilla/5.0 (Windows NT 5.1; rv:20.0) Gecko/20100101 Firefox/20.0";
+geturls_cj = cookielib.CookieJar();
+geturls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(geturls_cj));
+geturls_opener.addheaders = [("Referer", "http://www.google.com/search?q=younglegalporn"), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+print("0 Reading URL: http://photos.younglegalporn.com/");
+geturls_text = geturls_opener.open("http://photos.younglegalporn.com/");
+if(geturls_text.info().get("Content-Encoding")=="gzip" or geturls_text.info().get("Content-Encoding")=="deflate"):
+ strbuf = StringIO.StringIO(geturls_text.read());
+ gzstrbuf = gzip.GzipFile(fileobj=strbuf);
+ out_text = gzstrbuf.read()[:];
+if(geturls_text.info().get("Content-Encoding")!="gzip" and geturls_text.info().get("Content-Encoding")!="deflate"):
+ out_text = geturls_text.read()[:];
+regex_text = re.escape("<li><a href=\"http://photos.younglegalporn.com/")+"([a-fA-F0-9]{8})"+re.escape("/")+"([a-zA-Z0-9]{14})"+re.escape("/\"><img title=\"");
+post_text = re.findall(regex_text, out_text);
+wait_time1 = 4;
+wait_time2 = wait_time1 + 4;
+i = 0;
+il = len(post_text);
+print("0 Found "+str(il)+" Image Galleries.");
+if(not os.path.exists("./younglegalporn/")):
+ print("0 Making Directory: ./younglegalporn/");
+ os.mkdir("./younglegalporn/");
+while(i < il):
+ if(not os.path.exists("./younglegalporn/"+post_text[i][0]+"/")):
+ print(str(i+1)+" Making Directory: ./younglegalporn/"+post_text[i][0]+"/");
+ os.mkdir("./younglegalporn/"+post_text[i][0]+"/");
+ getsuburls_cj = geturls_cj;
+ getsuburls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(getsuburls_cj));
+ getsuburls_opener.addheaders = [("Referer", "http://photos.younglegalporn.com/"), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+ print(str(i+1)+" Start Downloading Image Gallery: "+str(i+1)+" of "+str(il));
+ print(str(i+1)+" Start Downloading Image Gallery: "+post_text[i][0]);
+ print(str(i+1)+" Reading Image Gallery: http://photos.younglegalporn.com/"+post_text[i][0]+"/"+post_text[i][1]+"/");
+ getsuburls_text = getsuburls_opener.open("http://photos.younglegalporn.com/"+post_text[i][0]+"/"+post_text[i][1]+"/");
+ if(getsuburls_text.info().get("Content-Encoding")=="gzip" or getsuburls_text.info().get("Content-Encoding")=="deflate"):
+ substrbuf = StringIO.StringIO(getsuburls_text.read());
+ gzsubstrbuf = gzip.GzipFile(fileobj=substrbuf);
+ subout_text = gzsubstrbuf.read()[:];
+ if(getsuburls_text.info().get("Content-Encoding")!="gzip" and getsuburls_text.info().get("Content-Encoding")!="deflate"):
+ subout_text = getsuburls_text.read()[:];
+ subout_text = subout_text.replace("://", ":///");
+ subout_text = subout_text.replace("//", "/");
+ subout_text = subout_text.replace("//pics/", "/pics/");
+ subout_text = subout_text.replace("/pics//", "/pics/");
+ subregex_text = re.escape("<a href=\"http://content1.sexforsure.com/")+"([0-9]+)"+re.escape("/")+"([0-9]+)"+re.escape("/")+"([0-9]+)"+re.escape("/")+"([0-9]+)"+re.escape("/pics/")+"([0-9]+)"+re.escape(".jpg\"><img src=\"");
+ subpost_text = re.findall(subregex_text, subout_text);
+ if(len(subpost_text)==0):
+ subregex_text = re.escape("<a href=\"http://content1.sexforsure.com/")+"([0-9]+)"+re.escape("/")+"([0-9]+)"+re.escape("/")+"([0-9]+)"+re.escape("/")+"([0-9]+)"+re.escape("//pics/")+"([0-9]+)"+re.escape(".jpg\"><img src=\"");
+ subpost_text = re.findall(subregex_text, subout_text);
+ subi = int(subpost_text[0][4]) - 1;
+ subil = int(subpost_text[-1][4]);
+ print(str(i+1)+" Found "+subpost_text[-1][4]+" JPEG Images.");
+ while(subi < subil):
+ getsub2xurls_cj = geturls_cj;
+ getsub2xurls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(getsub2xurls_cj));
+ getsub2xurls_opener.addheaders = [("Referer", "http://photos.younglegalporn.com/"+post_text[i][0]+"/"+post_text[i][1]+"/"), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+ print(str(i+1)+","+str(subi+1)+" Start Downloading Image File: "+str(subi+1)+" of "+str(subil));
+ print(str(i+1)+","+str(subi+1)+" Downloading Image: http://content1.sexforsure.com/"+subpost_text[subi][0]+"/"+subpost_text[subi][1]+"/"+subpost_text[subi][2]+"/"+subpost_text[subi][3]+"/pics/"+subpost_text[subi][4]+".jpg");
+ getsub2xurls_text = getsub2xurls_opener.open("http://content1.sexforsure.com/"+subpost_text[subi][0]+"/"+subpost_text[subi][1]+"/"+subpost_text[subi][2]+"/"+subpost_text[subi][3]+"/pics/"+subpost_text[subi][4]+".jpg");
+ print(str(i+1)+","+str(subi+1)+" Finished Downloading Image: http://content1.sexforsure.com/"+subpost_text[subi][0]+"/"+subpost_text[subi][1]+"/"+subpost_text[subi][2]+"/"+subpost_text[subi][3]+"/pics/"+subpost_text[subi][4]+".jpg");
+ print(str(i+1)+","+str(subi+1)+" Saving File: ./younglegalporn/"+post_text[i][0]+"/"+subpost_text[subi][4]+".jpg");
+ jpegf = open("./younglegalporn/"+post_text[i][0]+"/"+subpost_text[subi][4]+".jpg", "wb");
+ jpegf.write(getsub2xurls_text.read());
+ jpegf.close();
+ print(str(i+1)+","+str(subi+1)+" Finished Saving File: ./younglegalporn/"+post_text[i][0]+"/"+subpost_text[subi][4]+".jpg");
+ time.sleep(wait_time1);
+ subi = subi + 1;
+ print(str(i+1)+" Finished Downloading Image Gallery: "+post_text[i][0]);
+ time.sleep(wait_time2);
+ i = i + 1;
+ if(i < il):
+ print(str(i+1)+" Next Image Gallery Download: "+post_text[i][0]);
+print("Full Download Completed Successfully");
--- /dev/null
+<?php
+@ob_start();
+if(!isset($_GET['act'])) { $_GET['act'] = "url"; }
+if($_GET['act']=="download") { $_GET['act'] = "get"; }
+if($_GET['act']=="view") { $_GET['act'] = "get"; }
+if($_GET['act']=="geturl") { $_GET['act'] = "url"; }
+if($_GET['act']=="viewurl") { $_GET['act'] = "url"; }
+if($_GET['act']=="redir") { $_GET['act'] = "goto"; }
+if($_GET['act']=="redirect") { $_GET['act'] = "goto"; }
+if($_GET['act']=="location") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gourl") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gotourl") { $_GET['act'] = "goto"; }
+$default_opts = array(
+ 'http'=>array(
+ 'method'=>"GET",
+ 'header'=>"User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20100101 Firefox/10.0\r\n".
+ "Referer: http://motherless.com/".$_GET['v']."\r\n"
+ )
+);
+$default = stream_context_set_default($default_opts);
+if($_GET['act']=="url") {
+ header("Content-type: text/plain; charset=utf-8");
+ $get_value = file_get_contents("http://motherless.com/".$_GET['v']);
+ $preg_grep_1 = preg_quote("__fileurl = '");
+ $preg_grep_2 = preg_quote("';");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ echo $get_value; }
+if($_GET['act']=="goto") {
+ header("Content-type: text/plain; charset=utf-8");
+ $get_value = file_get_contents("http://motherless.com/".$_GET['v']);
+ $preg_grep_1 = preg_quote("__fileurl = '");
+ $preg_grep_2 = preg_quote("';");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ header("Location: ".$get_value);
+ echo $get_value; }
+if($_GET['act']=="get") {
+ $get_value = file_get_contents("http://motherless.com/".$_GET['v']);
+ $preg_grep_1 = preg_quote("__fileurl = '");
+ $preg_grep_2 = preg_quote("';");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ $getvidheaders = get_headers($get_value, 1);
+ header("Content-Type: ".$getvidheaders['Content-Type']);
+ echo file_get_contents($get_value); }
+?>
--- /dev/null
+#!/usr/bin/env python
+
+'''
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the Revised BSD License.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ Revised BSD License for more details.
+
+ Copyright 2013 Cool Dude 2k - http://idb.berlios.de/
+ Copyright 2013 Game Maker 2k - http://intdb.sourceforge.net/
+ Copyright 2013 Kazuki Przyborowski - https://github.com/KazukiPrzyborowski
+
+ $FileInfo: motherless-dl.py - Last Update: 05/11/2013 Ver. 1.0.5 RC 5 - Author: cooldude2k $
+'''
+
+import re, os, sys, httplib, urllib, urllib2, cookielib, StringIO, gzip, time, datetime, argparse;
+
+parser = argparse.ArgumentParser();
+parser.add_argument("url", help="motherless url");
+getargs = parser.parse_args();
+mlessvid = getargs.url;
+mregex_text = re.escape("http://motherless.com/")+"([a-zA-Z0-9\/]+)";
+if(re.findall(mregex_text, mlessvid)):
+ mlessvid = re.findall(mregex_text, mlessvid);
+ mlessvid = mlessvid[0];
+fakeua = "Mozilla/5.0 (Windows NT 5.1; rv:20.0) Gecko/20100101 Firefox/20.0";
+geturls_cj = cookielib.CookieJar();
+geturls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(geturls_cj));
+geturls_opener.addheaders = [("Referer", "http://motherless.com/videos"), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+geturls_text = geturls_opener.open("http://motherless.com/"+mlessvid);
+if(geturls_text.info().get("Content-Encoding")=="gzip" or geturls_text.info().get("Content-Encoding")=="deflate"):
+ strbuf = StringIO.StringIO(geturls_text.read());
+ gzstrbuf = gzip.GzipFile(fileobj=strbuf);
+ out_text = gzstrbuf.read()[:];
+if(geturls_text.info().get("Content-Encoding")!="gzip" and geturls_text.info().get("Content-Encoding")!="deflate"):
+ out_text = geturls_text.read()[:];
+regex_text = re.escape("__fileurl = '")+"(.*)"+re.escape("';");
+post_text = re.findall(regex_text, out_text);
+if(post_text>0):
+ mlesslink = post_text[0]+"?start=0";
+ print(mlesslink);
+ '''
+ getvidurls_cj = cookielib.CookieJar();
+ getvidurls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(getvidurls_cj));
+ getvidurls_opener.addheaders = [("Referer", "http://motherless.com/"+mlessvid), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+ getvidurls_text = getvidurls_opener.open(mlesslink);
+ def chunk_report(bytes_so_far, chunk_size, total_size):
+ percent = float(bytes_so_far) / total_size;
+ percent = round(percent*100, 2);
+ sys.stdout.write("Downloaded %d of %d bytes (%0.2f%%)\r" %
+ (bytes_so_far, total_size, percent));
+ if bytes_so_far >= total_size:
+ sys.stdout.write("\n");
+ def chunk_read(response, chunk_size=8192, report_hook=None):
+ total_size = response.info().getheader("Content-Length").strip();
+ total_size = int(total_size);
+ bytes_so_far = 0;
+ while 1:
+ chunk = response.read(chunk_size);
+ bytes_so_far += len(chunk);
+ if not chunk:
+ break;
+ if report_hook:
+ report_hook(bytes_so_far, chunk_size, total_size);
+ return bytes_so_far;
+ chunk_read(getvidurls_text, report_hook=chunk_report);
+ vidfile = open(os.getcwd()+os.sep+os.path.basename(urllib2.urlparse.urlsplit(mlesslink)[2]), "wb");
+ vidfile.write(getvidurls_text.read());
+ vidfile.close();
+ '''
--- /dev/null
+<?php
+@ob_start();
+if(!isset($_GET['act'])) { $_GET['act'] = "url"; }
+if($_GET['act']=="download") { $_GET['act'] = "get"; }
+if($_GET['act']=="view") { $_GET['act'] = "get"; }
+if($_GET['act']=="geturl") { $_GET['act'] = "url"; }
+if($_GET['act']=="viewurl") { $_GET['act'] = "url"; }
+if($_GET['act']=="redir") { $_GET['act'] = "goto"; }
+if($_GET['act']=="redirect") { $_GET['act'] = "goto"; }
+if($_GET['act']=="location") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gourl") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gotourl") { $_GET['act'] = "goto"; }
+$default_opts = array(
+ 'http'=>array(
+ 'method'=>"GET",
+ 'header'=>"User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20100101 Firefox/10.0\r\n".
+ "Referer: http://videarn.com/video.php?id=".$_GET['v']."\r\n"
+ )
+);
+$default = stream_context_set_default($default_opts);
+if($_GET['act']=="url") {
+ header("Content-type: text/plain; charset=utf-8");
+ $get_value = file_get_contents("http://videarn.com/video.php?id=".$_GET['v']);
+ $preg_grep_1 = preg_quote("file: \"");
+ $preg_grep_2 = preg_quote("\",");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ echo $get_value; }
+if($_GET['act']=="goto") {
+ header("Content-type: text/plain; charset=utf-8");
+ $get_value = file_get_contents("http://videarn.com/video.php?id=".$_GET['v']);
+ $preg_grep_1 = preg_quote("file: \"");
+ $preg_grep_2 = preg_quote("\",");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ header("Location: ".$get_value);
+ echo $get_value; }
+if($_GET['act']=="get") {
+ $get_value = file_get_contents("http://videarn.com/video.php?id=".$_GET['v']);
+ $preg_grep_1 = preg_quote("file: \"");
+ $preg_grep_2 = preg_quote("\",");
+ preg_match("/".$preg_grep_1."(.*)".$preg_grep_2."/", $get_value, $get_value_matches);
+ $get_value = $get_value_matches[1]."?start=0";
+ $get_value = trim($get_value);
+ $getvidheaders = get_headers($get_value, 1);
+ header("Content-Type: ".$getvidheaders['Content-Type']);
+ echo file_get_contents($get_value); }
+?>
--- /dev/null
+#!/usr/bin/env python
+
+'''
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the Revised BSD License.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ Revised BSD License for more details.
+
+ Copyright 2013 Cool Dude 2k - http://idb.berlios.de/
+ Copyright 2013 Game Maker 2k - http://intdb.sourceforge.net/
+ Copyright 2013 Kazuki Przyborowski - https://github.com/KazukiPrzyborowski
+
+ $FileInfo: videarn-dl.py - Last Update: 05/11/2013 Ver. 1.0.5 RC 5 - Author: cooldude2k $
+'''
+
+import re, os, sys, httplib, urllib, urllib2, cookielib, StringIO, gzip, time, datetime, argparse;
+
+parser = argparse.ArgumentParser();
+parser.add_argument("url", help="videarn url");
+getargs = parser.parse_args();
+mlessvid = getargs.url;
+mregex_text = re.escape("http://videarn.com/video.php?id=")+"([a-zA-Z0-9\/]+)";
+if(re.findall(mregex_text, mlessvid)):
+ mlessvid = re.findall(mregex_text, mlessvid);
+ mlessvid = mlessvid[0];
+fakeua = "Mozilla/5.0 (Windows NT 5.1; rv:20.0) Gecko/20100101 Firefox/20.0";
+geturls_cj = cookielib.CookieJar();
+geturls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(geturls_cj));
+geturls_opener.addheaders = [("Referer", "http://videarn.com/browse.php"), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+geturls_text = geturls_opener.open("http://videarn.com/video.php?id="+mlessvid);
+if(geturls_text.info().get("Content-Encoding")=="gzip" or geturls_text.info().get("Content-Encoding")=="deflate"):
+ strbuf = StringIO.StringIO(geturls_text.read());
+ gzstrbuf = gzip.GzipFile(fileobj=strbuf);
+ out_text = gzstrbuf.read()[:];
+if(geturls_text.info().get("Content-Encoding")!="gzip" and geturls_text.info().get("Content-Encoding")!="deflate"):
+ out_text = geturls_text.read()[:];
+regex_text = re.escape("file: \"")+"(.*)"+re.escape("\",");
+post_text = re.findall(regex_text, out_text);
+if(post_text>0):
+ mlesslink = post_text[0]+"?start=0";
+ print(mlesslink);
+ '''
+ getvidurls_cj = cookielib.CookieJar();
+ getvidurls_opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(getvidurls_cj));
+ getvidurls_opener.addheaders = [("Referer", "http://videarn.com/video.php?id="+mlessvid), ("User-Agent", fakeua), ("Accept-Encoding", "gzip, deflate"), ("Accept-Language", "en-US,en-CA,en-GB,en-UK,en-AU,en-NZ,en-ZA,en;q=0.5"), ("Accept-Charset", "ISO-8859-1,ISO-8859-15,utf-8;q=0.7,*;q=0.7"), ("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"), ("Connection", "close")];
+ getvidurls_text = getvidurls_opener.open(mlesslink);
+ def chunk_report(bytes_so_far, chunk_size, total_size):
+ percent = float(bytes_so_far) / total_size;
+ percent = round(percent*100, 2);
+ sys.stdout.write("Downloaded %d of %d bytes (%0.2f%%)\r" %
+ (bytes_so_far, total_size, percent));
+ if bytes_so_far >= total_size:
+ sys.stdout.write("\n");
+ def chunk_read(response, chunk_size=8192, report_hook=None):
+ total_size = response.info().getheader("Content-Length").strip();
+ total_size = int(total_size);
+ bytes_so_far = 0;
+ while 1:
+ chunk = response.read(chunk_size);
+ bytes_so_far += len(chunk);
+ if not chunk:
+ break;
+ if report_hook:
+ report_hook(bytes_so_far, chunk_size, total_size);
+ return bytes_so_far;
+ chunk_read(getvidurls_text, report_hook=chunk_report);
+ vidfile = open(os.getcwd()+os.sep+os.path.basename(urllib2.urlparse.urlsplit(mlesslink)[2]), "wb");
+ vidfile.write(getvidurls_text.read());
+ vidfile.close();
+ '''
--- /dev/null
+<?php
+@ob_start();
+if(!isset($_GET['act'])) { $_GET['act'] = "url"; }
+if($_GET['act']=="download") { $_GET['act'] = "get"; }
+if($_GET['act']=="view") { $_GET['act'] = "get"; }
+if($_GET['act']=="geturl") { $_GET['act'] = "url"; }
+if($_GET['act']=="viewurl") { $_GET['act'] = "url"; }
+if($_GET['act']=="redir") { $_GET['act'] = "goto"; }
+if($_GET['act']=="redirect") { $_GET['act'] = "goto"; }
+if($_GET['act']=="location") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gourl") { $_GET['act'] = "goto"; }
+if($_GET['act']=="gotourl") { $_GET['act'] = "goto"; }
+if($_GET['act']=="url") {
+ if(isset($_GET['fmt'])) { $_GET['fmt'] = 18; }
+ header("Content-type: text/plain; charset=utf-8");
+ exec("/usr/bin/youtube-dl --get-url --format ".$_GET['fmt']." https://www.youtube.com/watch?v=".$_GET['v'], $get_value);
+ $get_value = implode($get_value);
+ $get_value = trim($get_value);
+ echo $get_value; }
+if($_GET['act']=="goto") {
+ if(isset($_GET['fmt'])) { $_GET['fmt'] = 18; }
+ header("Content-type: text/plain; charset=utf-8");
+ exec("/usr/bin/youtube-dl --get-url --format ".$_GET['fmt']." https://www.youtube.com/watch?v=".$_GET['v'], $get_value);
+ $get_value = implode($get_value);
+ $get_value = trim($get_value);
+ header("Location: ".$get_value);
+ echo $get_value; }
+if($_GET['act']=="get") {
+ exec("/usr/bin/youtube-dl --dump-user-agent", $get_ua_value);
+ $get_ua_value = implode($get_ua_value);
+ $get_ua_value = trim($get_ua_value);
+ $default_opts = array(
+ 'http'=>array(
+ 'method'=>"GET",
+ 'header'=>"User-Agent: ".$get_ua_value."\r\n".
+ "Referer: https://www.youtube.com/watch?fmt=".$_GET['fmt']."v=".$_GET['v']."\r\n"
+ )
+ );
+ $default = stream_context_set_default($default_opts);
+ if(isset($_GET['fmt'])) { $_GET['fmt'] = 18; }
+ exec("/usr/bin/youtube-dl --get-filename -f ".$_GET['fmt']." https://www.youtube.com/watch?v=".$_GET['v'], $get_fname);
+ $get_fname = implode($get_fname);
+ $get_fname = trim($get_fname);
+ header('Content-Disposition: attachment; filename="'.$get_fname.'"');
+ exec("/usr/bin/youtube-dl --get-url --format ".$_GET['fmt']." https://www.youtube.com/watch?v=".$_GET['v'], $get_value);
+ $get_value = implode($get_value);
+ $get_value = trim($get_value);
+ $getvidheaders = get_headers($get_value, 1);
+ header("Content-Type: ".$getvidheaders['Content-Type']);
+ echo file_get_contents($get_value); }
+?>