[HELP] Youtube An error occurred, please try again later

Diskusi tentang Ubuntu Server baik webserver, database server, samba server dan service lainnya serta jaringan menggunakan Sistem Operasi Ubuntu.
User avatar
NBC
Posts: 18
Joined: 14 Apr 2011, 16:37

[HELP] Youtube An error occurred, please try again later

Postby NBC » 31 Mar 2012, 09:05

para master tolongin dong milih2 video nih, mungkin dikarenakan cache yang masuk berupa potongan bytes yach????? apa yg perlu d tambahin d squid...????
User avatar
sekedang
Posts: 8
Joined: 31 Mar 2012, 21:03
Location: aceh
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sekedang » 31 Mar 2012, 23:05

- saya juga pernah mendapat kasus seperti itu.
- cari storeurl.pl terbaru di internet atau coba yg ini.

#!/usr/bin/perl
# $Rev$
# by chudy_fernandez@yahoo.com
# Youtube updates at http://wiki.squid-cache.org/ConfigExamp ... Discussion
$|=1;
while () {
@X = split;
# $X[1] =~ s/&sig=.*//;
$x = $X[0] . " ";
$_ = $X[1];
$u = $X[1];

#photos-X.ak.fbcdn.net where X a-z
if (m/^http:\/\/photos-[a-z]?(.ak.fbcdn.net.*)/) {
print $x . "http://photos" . $1 . "\n";

#http://hphotos-ash2.fbcdn.net/290503_1735121757952_1835833812_1146280_4168472_o.jpg
} elsif (m/^http:\/\/photos-ash[1-5]?(.fbcdn.net.*)/) {
print $x . "http://ash.photos" . $1 . "\n";

#http://a6.sphotos.ak.fbcdn.net/hphotos-ak-ash4/319568_206164829444513_152217858172544_542308_1727268_n.jpg
#a5.sphotos.ak.fbcdn.ne

} elsif (m/^http:\/\/[a-z][0-9]?(.sphotos.ak.fbcdn.net.*)/) {
print $x . "http://cdn.photos" . $1 . "\n";

#http://cityvillefb0.static.zgncdn.com/hashed/43897e86db37ffda95e0d015de72e2a4.png
} elsif (m/^http:\/\/cityvillefb[0-3]?(.static.zgncdn.com.*)/) {
print $x . "http://cityvillefb" . $1 . "\n";

#http://playerstatics1.poker.static.zynga.com/poker/image_proxy.php/aHR0cDovL3Byb2ZpbGUuYWsuZmJjZG4ubmV0L2hwcm9maWxlLWFrLXNuYzQvMjc0ODM2XzEwMDAwMjkwMTU1MTE3MV8xMDAwNTE0MjM3X24uanBn
} elsif (m/^http:\/\/playerstatics[1-9]?(.poker.static.zynga.com.*)/) {
print $x . "http://playerstatics.poker-zynga." . $1 . "\n";

#http://zynga4-a.akamaihd.net/zbar/game-icons/adventureworld-banner-Adventureadventuredame09162011-13161891413359.png
} elsif (m/^http:\/\/zynga[1-9]?-a(.akamaihd.net.*)/) {
print $x . "http://zynga-akamaihd.net." . $1 . "\n";

#http://s2.ninja.game321.com/source/bitmap/icon/debris/icon_debris134.s110.png
} elsif (m/^http:\/\/s[1-9]?(.ninja.game321.com.*)/) {
print $x . "http://ninja-game321." . $1 . "\n";

#http://i616.photobucket.com/albums/uu90/the_martian_cat/ATT00001-1.gif
} elsif (m/^http:\/\/i[1-9]{3}(.photobucket.com.*)/) {
print $x . "http://photobucket3." . $1 . "\n";

# http://i1221.photobucket.com/albums/dd4 ... 7bet-s.gif
} elsif (m/^http:\/\/i[1-9]{4}(.photobucket.com.*)/) {
print $x . "http://photobucket." . $1 . "\n";

#BLOGSPOT
} elsif (m/^http:\/\/[1-4]?(bp.blogspot.com.*)/) {
print $x . "http://blog-cdn." . $1 . "\n";

#http://lh6.ggpht.com/_pt7i0nbIOCY/SeBSfNbxQ_I/AAAAAAAABuA/lQToFnYZHKI/navhover_thumb%5B1%5D.png
} elsif (m/^http:\/\/lh[3-6]?(.ggpht.com.*)/) {
print $x . "http://ggpht." . $1 . "\n";

#http://a2.twimg.com/profile_images/1213095644/CBS-eye-white-bg_normal.jpg
} elsif (m/^http:\/\/a[0-5]?(.twimg.com.*)/) {
print $x . "http://cdn-twimg.com." . $1 . "\n";

#AVAST
} elsif (m/^http:\/\/download[0-9]{3}.(avast.com.*)/) {
print $x . "http://avast-cdn." . $1 . "\n";

#KAV
} elsif (m/^http:\/\/dnl-[0-9]{2}.(geo.kaspersky.com.*)/) {
print $x . "http://kav-cdn." . $1 . "\n";

#AVG
} elsif (m/^http:\/\/(update.avg.com.*)/) {
print $x . "http://avg-cdn." . $1 . "\n";

#static3.spilcdn.com/
} elsif (m/^http:\/\/static[1-9]?(.speelcdn.com.*)/) {
print $x . "http://speelcdn." . $1 . "\n";

#http://t1.gstatic.com
} elsif (m/^http:\/\/t[1-9]?(.gstatic.com.*)/) {
print $x . "http://cdn-gstatic.com." . $1 . "\n";

# http://0.gravatar.com
} elsif (m/^http:\/\/[0-3]?(.gravatar.com.*)/) {
print $x . "http://cdn-gravatar." . $1 . "\n";

#http://s5.scribdassets.com/images/attribution_noncommercial.png
} elsif (m/^http:\/\/s[1-8]?(.scribdassets.com.*)/) {
print $x . "http://cdn-scribdassets." . $1 . "\n";

# http://tc2.easythumbhost.com/
} elsif (m/^http:\/\/tc[0-9]?(.easythumbhost.com.*)/) {
print $x . "http://cdn-easythumbhost." . $1 . "\n";

#http://static7.spilcdn.com/tw/img/_/profile/dummy_small.png
} elsif (m/^http:\/\/static[1-7]?(.spilcdn.com.*)/) {
print $x . "http://spilcdn." . $1 . "\n";

#http://media5.picsearch.com/is
} elsif (m/^http:\/\/media[1-8]?(.picsearch.com.*)/) {
print $x . "http://cdn-picsearch." . $1 . "\n";

#http://lh3.googleusercontent.com/-z2ZV9VfLsc0/TmetBcUiRBI/AAAAAAAAC_k/-wvptlnDXuQ/03.png
} elsif (m/^http:\/\/lh[3-6]?(.googleusercontent.com.*)/) {
print $x . "http://googleusercontent." . $1 . "\n";

#http://i54.tinypic.com/2crkryu.jpg
} elsif (m/^http:\/\/i[0-9]{2}(.tinypic.com.*)/) {
print $x . "http://tinypic." . $1 . "\n";

#maps.google.com
} elsif (m/^http:\/\/(cbk|mt|khm|mlt|tbn)[0-9]?(.google\.co(m|\.uk|\.id).*)/) {
print $x . "http://" . $1 . $2 . "\n";

#gstatic and/or wikimapia
} elsif (m/^http:\/\/([a-z])[0-9]?(\.gstatic\.com.*|\.wikimapia\.org.*)/) {
print $x . "http://" . $1 . $2 . "\n";

#ini untuk cache partial
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(id=[a-zA-Z0-9]*).*?\&(range=[0-9]*).*/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . $3 . "\n";

# compatibility for old cached get_video?video_id
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(videoplayback\?id=.*?|video_id=.*?)\&(.*?)/) {
$z = $2; $z =~ s/video_id=/get_video?video_id=/;
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $z . "\n";

# youtube All itag (semua resolusi)
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(itag=[0-9]*).*?\&(id=[a-zA-Z0-9]*).*/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . "&" . $3 . "\n";

# youtube All itag (semua resolusi) posisi kebalikan
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(id=[a-zA-Z0-9]*).*?\&(itag=[0-9]*).*/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $3 . "&" . $2 . "\n";

} elsif (m/^http:\/\/www\.google-analytics\.com\/__utm\.gif\?.*/) {
print $x . "http://www.google-analytics.com/__utm.gif\n";

#Cache High Latency Ads
} elsif (m/^http:\/\/([a-z0-9.]*)(\.doubleclick\.net|\.quantserve\.com|\.googlesyndication\.com|yieldmanager|cpxinteractive)(.*)/) {
$y = $3;$z = $2;
for ($y) {
s/pixel;.*/pixel/;
s/activity;.*/activity/;
s/(imgad[^&]*).*/\1/;
s/;ord=[?0-9]*//;
s/;&timestamp=[0-9]*//;
s/[&?]correlator=[0-9]*//;
s/&cookie=[^&]*//;
s/&ga_hid=[^&]*//;
s/&ga_vid=[^&]*//;
s/&ga_sid=[^&]*//;
# s/&prev_slotnames=[^&]*//
# s/&u_his=[^&]*//;
s/&dt=[^&]*//;
s/&dtd=[^&]*//;
s/&lmt=[^&]*//;
s/(&alternate_ad_url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&ref=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&cookie=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/[;&?]ord=[?0-9]*//;
s/[;&]mpvid=[^&;]*//;
s/&xpc=[^&]*//;
# yieldmanager
s/\?clickTag=[^&]*//;
s/&u=[^&]*//;
s/&slotname=[^&]*//;
s/&page_slots=[^&]*//;
}
print $x . "http://" . $1 . $2 . $y . "\n";

#cache high latency ads
} elsif (m/^http:\/\/(.*?)\/(ads)\?(.*?)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

#cdn, varialble 1st path
} elsif (($u =~ /filehippo|mediafire/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(.*)\.([a-zA-Z0-9]{2,3})(\?.*)?/)) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn./;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

} elsif (($u =~ /maxporn/) && (m/^http:\/\/([^\/]*?)\/(.*?)\/([^\/]*?)(\?.*)?$/)) {
print $x . "http://" . $1 . "/SQUIDINTERNAL/" . $3 . "\n";

#domain/path/.*/path/filename
} elsif (($u =~ /fucktube/) && (m/^http:\/\/(.*?)(\.[^\.\-]*?[^\/]*\/[^\/]*)\/(.*)\/([^\/]*)\/([^\/\?\&]*)\.([^\/\?\&]{3,4})(\?.*?)$/)) {
@y = ($1,$2,$4,$5,$6);
$y[0] =~ s/(([a-zA-Z]+[0-9]+(-[a-zA-Z])?$)|([^\.]*cdn[^\.]*)|([^\.]*cache[^\.]*))/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "/" . $y[3] . "." . $y[4] . "\n";

# #4shared audio/video preview
} elsif (($u =~ /4shared/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(dlink__2Fdownload_2F([^\/-]+))([a-zA-Z0-9-]+)\/([^\/\?\&]*\.[^\/\?\&]{2,3})(\?.*)?$/)) {
@y = ($1,$2,$3,$4,$7);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn./;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "/" . $y[3] . "/" . $y[4] . "\n";

#indowebster
} elsif (m/^http:\/\/(.*?)(\.jkt\.3d\.x\.indowebster.com)\/(.*?)\/([^\/\?\&]*)\.([^\/\?\&]{2,4})(\?.*?)$/) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/([a-z][0-9][a-z]dlod[\d]{3})|((cache|cdn)[-\d]*)|([a-zA-Z]+-?[0-9]+(-[a-zA-Z]*)?)/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

#like porn hub variables url and center part of the path, filename etention 3 or 4 with or without ? at the end
} elsif (($u =~ /tube8|pornhub|xvideos/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?(\.[a-z]*)?)\.([a-z]*[0-9]?\.[^\/]{3}\/[a-z]*)(.*?)((\/[a-z]*)?(\/[^\/]*){4}\.[^\/\?]{3,4})(\?.*)?$/)) {
print $x . "http://cdn." . $4 . $6 . "\n";

#for yimg.com video
} elsif (m/^http:\/\/(.*yimg.com)\/\/(.*)\/([^\/\?\&]*\/[^\/\?\&]*\.[^\/\?\&]{3,4})(\?.*)?$/) {
print $x . "http://cdn.yimg.com//" . $3 . "\n";

#for yimg.com doubled
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*?)\.yimg\.com\/(.*?)\?(.*)/) {
print $x . "http://cdn.yimg.com/" . $3 . "\n";

#for yimg.com with &sig=
} elsif (m/^http:\/\/([^\.]*)\.yimg\.com\/(.*)/) {
@y = ($1,$2);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn/;
$y[1] =~ s/&sig=.*//;
print $x . "http://" . $y[0] . ".yimg.com/" . $y[1] . "\n";

#youjizz. We use only domain and filename
} elsif (($u =~ /media[0-9]{1,5}\.youjizz/) && (m/^http:\/\/(.*?)(\.[^\.\-]*?\.[^\/]*)\/(.*)\/([^\/\?\&]*)\.([^\/\?\&]{3,4})(\?.*?)$/)) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/(([a-zA-Z]+[0-9]+(-[a-zA-Z])?$)|([^\.]*cdn[^\.]*)|([^\.]*cache[^\.]*))/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

#general purpose for cdn servers. add above your specific servers.
} elsif (m/^http:\/\/([0-9.]*?)\/\/(.*?)\.(.*)\?(.*?)/) {
print $x . "http://squid-cdn-url//" . $2 . "." . $3 . "\n";

#generic http://variable.domain.com/path/filename. "ext" or "exte"
} elsif (m/^http:\/\/(.*?)(\.[^\.\-]*?\..*?)\/([^\?\&\=]*)\.([\w\d]{2,4})\??.*$/) {
@y = ($1,$2,$3,$4);
$y[0] =~ s/([a-z][0-9][a-z]dlod[\d]{3})|((cache|cdn)[-\d]*)|([a-zA-Z]+-?[0-9]+(-[a-zA-Z]*)?)/cdn/;
print $x . "storeurl://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

# all that ends with ;
} elsif (m/^http:\/\/(.*?)\/(.*?)\;(.*)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

} else {
print $x . $_ . "\n";
}
}


Ket .
saya pakek proxy lusca
smoga membantu.
User avatar
fikanet
Posts: 5
Joined: 26 Mar 2012, 16:00
Location: Curup-Bengkulu
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby fikanet » 05 Apr 2012, 01:31

izin Nyimak yach ,.,
User avatar
antoniusgenta
Posts: 103
Joined: 29 Dec 2011, 14:40
Location: jakarta

Re: [HELP] Youtube An error occurred, please try again later

Postby antoniusgenta » 05 Apr 2012, 19:03

NBC wrote:para master tolongin dong milih2 video nih, mungkin dikarenakan cache yang masuk berupa potongan bytes yach????? apa yg perlu d tambahin d squid...????


cache partial sebelumya sudah pernah dibahas..dan sekarang format youtube sudah berbeda..format yang sekarang RTMPT,,pasti ngesrot/error pas buka youtubenya..jadi harus merubah storeurl-nya!!

thanks
User avatar
antoniusgenta
Posts: 103
Joined: 29 Dec 2011, 14:40
Location: jakarta

Re: [HELP] Youtube An error occurred, please try again later

Postby antoniusgenta » 05 Apr 2012, 19:07

sekedang wrote:- saya juga pernah mendapat kasus seperti itu.
- cari storeurl.pl terbaru di internet atau coba yg ini.

#!/usr/bin/perl
# $Rev$
# by chudy_fernandez@yahoo.com
# Youtube updates at http://wiki.squid-cache.org/ConfigExamp ... Discussion
$|=1;
while () {
@X = split;
# $X[1] =~ s/&sig=.*//;
$x = $X[0] . " ";
$_ = $X[1];
$u = $X[1];

#photos-X.ak.fbcdn.net where X a-z
if (m/^http:\/\/photos-[a-z]?(.ak.fbcdn.net.*)/) {
print $x . "http://photos" . $1 . "\n";

#http://hphotos-ash2.fbcdn.net/290503_1735121757952_1835833812_1146280_4168472_o.jpg
} elsif (m/^http:\/\/photos-ash[1-5]?(.fbcdn.net.*)/) {
print $x . "http://ash.photos" . $1 . "\n";

#http://a6.sphotos.ak.fbcdn.net/hphotos-ak-ash4/319568_206164829444513_152217858172544_542308_1727268_n.jpg
#a5.sphotos.ak.fbcdn.ne

} elsif (m/^http:\/\/[a-z][0-9]?(.sphotos.ak.fbcdn.net.*)/) {
print $x . "http://cdn.photos" . $1 . "\n";

#http://cityvillefb0.static.zgncdn.com/hashed/43897e86db37ffda95e0d015de72e2a4.png
} elsif (m/^http:\/\/cityvillefb[0-3]?(.static.zgncdn.com.*)/) {
print $x . "http://cityvillefb" . $1 . "\n";

#http://playerstatics1.poker.static.zynga.com/poker/image_proxy.php/aHR0cDovL3Byb2ZpbGUuYWsuZmJjZG4ubmV0L2hwcm9maWxlLWFrLXNuYzQvMjc0ODM2XzEwMDAwMjkwMTU1MTE3MV8xMDAwNTE0MjM3X24uanBn
} elsif (m/^http:\/\/playerstatics[1-9]?(.poker.static.zynga.com.*)/) {
print $x . "http://playerstatics.poker-zynga." . $1 . "\n";

#http://zynga4-a.akamaihd.net/zbar/game-icons/adventureworld-banner-Adventureadventuredame09162011-13161891413359.png
} elsif (m/^http:\/\/zynga[1-9]?-a(.akamaihd.net.*)/) {
print $x . "http://zynga-akamaihd.net." . $1 . "\n";

#http://s2.ninja.game321.com/source/bitmap/icon/debris/icon_debris134.s110.png
} elsif (m/^http:\/\/s[1-9]?(.ninja.game321.com.*)/) {
print $x . "http://ninja-game321." . $1 . "\n";

#http://i616.photobucket.com/albums/uu90/the_martian_cat/ATT00001-1.gif
} elsif (m/^http:\/\/i[1-9]{3}(.photobucket.com.*)/) {
print $x . "http://photobucket3." . $1 . "\n";

# http://i1221.photobucket.com/albums/dd4 ... 7bet-s.gif
} elsif (m/^http:\/\/i[1-9]{4}(.photobucket.com.*)/) {
print $x . "http://photobucket." . $1 . "\n";

#BLOGSPOT
} elsif (m/^http:\/\/[1-4]?(bp.blogspot.com.*)/) {
print $x . "http://blog-cdn." . $1 . "\n";

#http://lh6.ggpht.com/_pt7i0nbIOCY/SeBSfNbxQ_I/AAAAAAAABuA/lQToFnYZHKI/navhover_thumb%5B1%5D.png
} elsif (m/^http:\/\/lh[3-6]?(.ggpht.com.*)/) {
print $x . "http://ggpht." . $1 . "\n";

#http://a2.twimg.com/profile_images/1213095644/CBS-eye-white-bg_normal.jpg
} elsif (m/^http:\/\/a[0-5]?(.twimg.com.*)/) {
print $x . "http://cdn-twimg.com." . $1 . "\n";

#AVAST
} elsif (m/^http:\/\/download[0-9]{3}.(avast.com.*)/) {
print $x . "http://avast-cdn." . $1 . "\n";

#KAV
} elsif (m/^http:\/\/dnl-[0-9]{2}.(geo.kaspersky.com.*)/) {
print $x . "http://kav-cdn." . $1 . "\n";

#AVG
} elsif (m/^http:\/\/(update.avg.com.*)/) {
print $x . "http://avg-cdn." . $1 . "\n";

#static3.spilcdn.com/
} elsif (m/^http:\/\/static[1-9]?(.speelcdn.com.*)/) {
print $x . "http://speelcdn." . $1 . "\n";

#http://t1.gstatic.com
} elsif (m/^http:\/\/t[1-9]?(.gstatic.com.*)/) {
print $x . "http://cdn-gstatic.com." . $1 . "\n";

# http://0.gravatar.com
} elsif (m/^http:\/\/[0-3]?(.gravatar.com.*)/) {
print $x . "http://cdn-gravatar." . $1 . "\n";

#http://s5.scribdassets.com/images/attribution_noncommercial.png
} elsif (m/^http:\/\/s[1-8]?(.scribdassets.com.*)/) {
print $x . "http://cdn-scribdassets." . $1 . "\n";

# http://tc2.easythumbhost.com/
} elsif (m/^http:\/\/tc[0-9]?(.easythumbhost.com.*)/) {
print $x . "http://cdn-easythumbhost." . $1 . "\n";

#http://static7.spilcdn.com/tw/img/_/profile/dummy_small.png
} elsif (m/^http:\/\/static[1-7]?(.spilcdn.com.*)/) {
print $x . "http://spilcdn." . $1 . "\n";

#http://media5.picsearch.com/is
} elsif (m/^http:\/\/media[1-8]?(.picsearch.com.*)/) {
print $x . "http://cdn-picsearch." . $1 . "\n";

#http://lh3.googleusercontent.com/-z2ZV9VfLsc0/TmetBcUiRBI/AAAAAAAAC_k/-wvptlnDXuQ/03.png
} elsif (m/^http:\/\/lh[3-6]?(.googleusercontent.com.*)/) {
print $x . "http://googleusercontent." . $1 . "\n";

#http://i54.tinypic.com/2crkryu.jpg
} elsif (m/^http:\/\/i[0-9]{2}(.tinypic.com.*)/) {
print $x . "http://tinypic." . $1 . "\n";

#maps.google.com
} elsif (m/^http:\/\/(cbk|mt|khm|mlt|tbn)[0-9]?(.google\.co(m|\.uk|\.id).*)/) {
print $x . "http://" . $1 . $2 . "\n";

#gstatic and/or wikimapia
} elsif (m/^http:\/\/([a-z])[0-9]?(\.gstatic\.com.*|\.wikimapia\.org.*)/) {
print $x . "http://" . $1 . $2 . "\n";

#ini untuk cache partial
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(id=[a-zA-Z0-9]*).*?\&(range=[0-9]*).*/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . $3 . "\n";

# compatibility for old cached get_video?video_id
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(videoplayback\?id=.*?|video_id=.*?)\&(.*?)/) {
$z = $2; $z =~ s/video_id=/get_video?video_id=/;
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $z . "\n";

# youtube All itag (semua resolusi)
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(itag=[0-9]*).*?\&(id=[a-zA-Z0-9]*).*/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . "&" . $3 . "\n";

# youtube All itag (semua resolusi) posisi kebalikan
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(id=[a-zA-Z0-9]*).*?\&(itag=[0-9]*).*/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $3 . "&" . $2 . "\n";

} elsif (m/^http:\/\/www\.google-analytics\.com\/__utm\.gif\?.*/) {
print $x . "http://www.google-analytics.com/__utm.gif\n";

#Cache High Latency Ads
} elsif (m/^http:\/\/([a-z0-9.]*)(\.doubleclick\.net|\.quantserve\.com|\.googlesyndication\.com|yieldmanager|cpxinteractive)(.*)/) {
$y = $3;$z = $2;
for ($y) {
s/pixel;.*/pixel/;
s/activity;.*/activity/;
s/(imgad[^&]*).*/\1/;
s/;ord=[?0-9]*//;
s/;&timestamp=[0-9]*//;
s/[&?]correlator=[0-9]*//;
s/&cookie=[^&]*//;
s/&ga_hid=[^&]*//;
s/&ga_vid=[^&]*//;
s/&ga_sid=[^&]*//;
# s/&prev_slotnames=[^&]*//
# s/&u_his=[^&]*//;
s/&dt=[^&]*//;
s/&dtd=[^&]*//;
s/&lmt=[^&]*//;
s/(&alternate_ad_url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&ref=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&cookie=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/[;&?]ord=[?0-9]*//;
s/[;&]mpvid=[^&;]*//;
s/&xpc=[^&]*//;
# yieldmanager
s/\?clickTag=[^&]*//;
s/&u=[^&]*//;
s/&slotname=[^&]*//;
s/&page_slots=[^&]*//;
}
print $x . "http://" . $1 . $2 . $y . "\n";

#cache high latency ads
} elsif (m/^http:\/\/(.*?)\/(ads)\?(.*?)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

#cdn, varialble 1st path
} elsif (($u =~ /filehippo|mediafire/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(.*)\.([a-zA-Z0-9]{2,3})(\?.*)?/)) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn./;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

} elsif (($u =~ /maxporn/) && (m/^http:\/\/([^\/]*?)\/(.*?)\/([^\/]*?)(\?.*)?$/)) {
print $x . "http://" . $1 . "/SQUIDINTERNAL/" . $3 . "\n";

#domain/path/.*/path/filename
} elsif (($u =~ /fucktube/) && (m/^http:\/\/(.*?)(\.[^\.\-]*?[^\/]*\/[^\/]*)\/(.*)\/([^\/]*)\/([^\/\?\&]*)\.([^\/\?\&]{3,4})(\?.*?)$/)) {
@y = ($1,$2,$4,$5,$6);
$y[0] =~ s/(([a-zA-Z]+[0-9]+(-[a-zA-Z])?$)|([^\.]*cdn[^\.]*)|([^\.]*cache[^\.]*))/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "/" . $y[3] . "." . $y[4] . "\n";

# #4shared audio/video preview
} elsif (($u =~ /4shared/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(dlink__2Fdownload_2F([^\/-]+))([a-zA-Z0-9-]+)\/([^\/\?\&]*\.[^\/\?\&]{2,3})(\?.*)?$/)) {
@y = ($1,$2,$3,$4,$7);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn./;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "/" . $y[3] . "/" . $y[4] . "\n";

#indowebster
} elsif (m/^http:\/\/(.*?)(\.jkt\.3d\.x\.indowebster.com)\/(.*?)\/([^\/\?\&]*)\.([^\/\?\&]{2,4})(\?.*?)$/) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/([a-z][0-9][a-z]dlod[\d]{3})|((cache|cdn)[-\d]*)|([a-zA-Z]+-?[0-9]+(-[a-zA-Z]*)?)/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

#like porn hub variables url and center part of the path, filename etention 3 or 4 with or without ? at the end
} elsif (($u =~ /tube8|pornhub|xvideos/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?(\.[a-z]*)?)\.([a-z]*[0-9]?\.[^\/]{3}\/[a-z]*)(.*?)((\/[a-z]*)?(\/[^\/]*){4}\.[^\/\?]{3,4})(\?.*)?$/)) {
print $x . "http://cdn." . $4 . $6 . "\n";

#for yimg.com video
} elsif (m/^http:\/\/(.*yimg.com)\/\/(.*)\/([^\/\?\&]*\/[^\/\?\&]*\.[^\/\?\&]{3,4})(\?.*)?$/) {
print $x . "http://cdn.yimg.com//" . $3 . "\n";

#for yimg.com doubled
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*?)\.yimg\.com\/(.*?)\?(.*)/) {
print $x . "http://cdn.yimg.com/" . $3 . "\n";

#for yimg.com with &sig=
} elsif (m/^http:\/\/([^\.]*)\.yimg\.com\/(.*)/) {
@y = ($1,$2);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn/;
$y[1] =~ s/&sig=.*//;
print $x . "http://" . $y[0] . ".yimg.com/" . $y[1] . "\n";

#youjizz. We use only domain and filename
} elsif (($u =~ /media[0-9]{1,5}\.youjizz/) && (m/^http:\/\/(.*?)(\.[^\.\-]*?\.[^\/]*)\/(.*)\/([^\/\?\&]*)\.([^\/\?\&]{3,4})(\?.*?)$/)) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/(([a-zA-Z]+[0-9]+(-[a-zA-Z])?$)|([^\.]*cdn[^\.]*)|([^\.]*cache[^\.]*))/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

#general purpose for cdn servers. add above your specific servers.
} elsif (m/^http:\/\/([0-9.]*?)\/\/(.*?)\.(.*)\?(.*?)/) {
print $x . "http://squid-cdn-url//" . $2 . "." . $3 . "\n";

#generic http://variable.domain.com/path/filename. "ext" or "exte"
} elsif (m/^http:\/\/(.*?)(\.[^\.\-]*?\..*?)\/([^\?\&\=]*)\.([\w\d]{2,4})\??.*$/) {
@y = ($1,$2,$3,$4);
$y[0] =~ s/([a-z][0-9][a-z]dlod[\d]{3})|((cache|cdn)[-\d]*)|([a-zA-Z]+-?[0-9]+(-[a-zA-Z]*)?)/cdn/;
print $x . "storeurl://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

# all that ends with ;
} elsif (m/^http:\/\/(.*?)\/(.*?)\;(.*)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

} else {
print $x . $_ . "\n";
}
}


Ket .
saya pakek proxy lusca
smoga membantu.


storeurl yg diatas sudah pernah saya gunakan sebelumnya aman2 aja tapi sekarang sudah tidak bisa dipakai lagi karna formatnya berbeda, format youtube yg sekarang RTMPT..


thanks
User avatar
sipelaut
Posts: 1963
Joined: 03 Jan 2010, 17:25
Location: madura-sampang
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sipelaut » 06 Apr 2012, 10:05

ane nyimak ajalah
soalnya masalahnya sama kyak punya ane
User avatar
sekedang
Posts: 8
Joined: 31 Mar 2012, 21:03
Location: aceh
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sekedang » 09 Apr 2012, 02:42

Coba yang ini Update 27 maret 2012.


http://www.4shared.com/rar/xmKM_a17/storeurl.html


smoga membantu.
User avatar
antoniusgenta
Posts: 103
Joined: 29 Dec 2011, 14:40
Location: jakarta

Re: [HELP] Youtube An error occurred, please try again later

Postby antoniusgenta » 09 Apr 2012, 09:16

sekedang wrote:Coba yang ini Update 27 maret 2012.


http://www.4shared.com/rar/xmKM_a17/storeurl.html


smoga membantu.


Silakan Dicopas semoga memberi pencerahan

} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com)\/videoplayback\?(.*)/) {
$p_str = $2;
$tag = "";
$alg = "";
$id = "";
$range = "";
if ($p_str =~ m/(itag=[0-9]*)/){$tag = "&".$1}
if ($p_str =~ m/(algorithm=[a-z]*\-[a-z]*)/){$alg = "&".$1}
if ($p_str =~ m/(id=[a-zA-Z0-9]*)/){$id = "&".$1}
if ($p_str =~ m/(range=[0-9\-]*)/){$range = "&".$1; $range =~ s/-//; $range =~ s/range=//; }
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $tag . "&" . $alg . "&" . $id . "&" . $range . "\n";



regards
Genta
User avatar
sipelaut
Posts: 1963
Joined: 03 Jan 2010, 17:25
Location: madura-sampang
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sipelaut » 09 Apr 2012, 14:57

ane coba dulu masbroo....
nice share...


BOOKMARKKKKKKKKKKKKKKKKKKK dulu ahhh....
User avatar
sipelaut
Posts: 1963
Joined: 03 Jan 2010, 17:25
Location: madura-sampang
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sipelaut » 09 Apr 2012, 15:04

sekedang wrote:Coba yang ini Update 27 maret 2012.


http://www.4shared.com/rar/xmKM_a17/storeurl.html


smoga membantu.

maaf masbroo... kok harus Sign Up or Login
btw...
bisa gak dicopas disini filenya hee...

soalnya ane nyoba copas script dari bro @antoniusgenta, gak tau musti copas disebelah mana???, malah gak jalan nichhhh
User avatar
antoniusgenta
Posts: 103
Joined: 29 Dec 2011, 14:40
Location: jakarta

Re: [HELP] Youtube An error occurred, please try again later

Postby antoniusgenta » 09 Apr 2012, 15:10

sipelaut wrote:
sekedang wrote:Coba yang ini Update 27 maret 2012.


http://www.4shared.com/rar/xmKM_a17/storeurl.html


smoga membantu.

maaf masbroo... kok harus Sign Up or Login
btw...
bisa gak dicopas disini filenya hee...

soalnya ane nyoba copas script dari bro @antoniusgenta, gak tau musti copas disebelah mana???, malah gak jalan nichhhh


Copykan storeurl agan disini,,,biar di bahas disini...

thx
genta
User avatar
sipelaut
Posts: 1963
Joined: 03 Jan 2010, 17:25
Location: madura-sampang
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sipelaut » 09 Apr 2012, 15:20

oke
ini masbroo..
Tampilkan

Code: Select all

#!/usr/bin/perl
# $Rev$
# by chudy_fernandez@yahoo.com
# Updates at http://wiki.squid-cache.org/ConfigExamples/DynamicContent/YouTube/Discussion
$|=1;
while (<>) {
    @X = split;
#   $X[1] =~ s/&sig=.*//;
   $x = $X[0] . " ";
   $_ = $X[1];
   $u = $X[1];


         # compatibility for old cached get_video?video_id
if (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(videoplayback\?id=.*?|video_id=.*?)\&(.*?)/) {
   $z = $2; $z =~ s/video_id=/get_video?video_id=/;
   print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $z . "\n";

         # youtube HD itag=22
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=22).*?\&(id=[a-zA-Z0-9]*)/) {
   print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . "&" . $3 . "\n";

         # youtube Normal screen always HD itag 35, Normal screen never HD itag 34, itag=18 <--normal?
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=[0-9]*).*?\&(id=[a-zA-Z0-9]*)/) {
   print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $3 . "\n";

} elsif (m/^http:\/\/www\.google-analytics\.com\/__utm\.gif\?.*/) {
   print $x . "http://www.google-analytics.com/__utm.gif\n";

         #Cache High Latency Ads
} elsif (m/^http:\/\/([a-z0-9.]*)(\.doubleclick\.net|\.quantserve\.com|\.googlesyndication\.com|yieldmanager|cpxinteractive)(.*)/) {
   $y = $3;$z = $2;
   for ($y) {
   s/pixel;.*/pixel/;
   s/activity;.*/activity/;
   s/(imgad[^&]*).*/\1/;
   s/;ord=[?0-9]*//;
   s/;&timestamp=[0-9]*//;
   s/[&?]correlator=[0-9]*//;
   s/&cookie=[^&]*//;
   s/&ga_hid=[^&]*//;
   s/&ga_vid=[^&]*//;
   s/&ga_sid=[^&]*//;
   # s/&prev_slotnames=[^&]*//
   # s/&u_his=[^&]*//;
   s/&dt=[^&]*//;
   s/&dtd=[^&]*//;
   s/&lmt=[^&]*//;
   s/(&alternate_ad_url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/(&url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/(&ref=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/(&cookie=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/[;&?]ord=[?0-9]*//;
   s/[;&]mpvid=[^&;]*//;
   s/&xpc=[^&]*//;
   # yieldmanager
   s/\?clickTag=[^&]*//;
   s/&u=[^&]*//;
   s/&slotname=[^&]*//;
   s/&page_slots=[^&]*//;
   }
   print $x . "http://" . $1 . $2 . $y . "\n";

         #cache high latency ads
} elsif (m/^http:\/\/(.*?)\/(ads)\?(.*?)/) {
   print $x . "http://" . $1 . "/" . $2  . "\n";

         # spicific servers starts here....
} elsif (m/^http:\/\/(www\.ziddu\.com.*\.[^\/]{3,4})\/(.*?)/) {
   print $x . "http://" . $1 . "\n";

         #cdn, varialble 1st path
} elsif (($u =~ /filehippo/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(.*)\.([a-z0-9]{3,4})(\?.*)?/)) {
   @y = ($1,$2,$4,$5);
   $y[0] =~ s/[a-z0-9]{2,5}/cdn./;
   print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

         #rapidshare
} elsif (($u =~ /rapidshare/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?)([a-z]*\.[^\/]{3}\/[a-z]*\/[0-9]*)\/(.*?)\/([^\/\?\&]{4,})$/)) {
   print $x . "http://cdn." . $3 . "/SQUIDINTERNAL/" . $5 . "\n";

} elsif (($u =~ /maxporn/) && (m/^http:\/\/([^\/]*?)\/(.*?)\/([^\/]*?)(\?.*)?$/)) {
   print $x . "http://" . $1 . "/SQUIDINTERNAL/" . $3 . "\n";

         #like porn hub variables url and center part of the path, filename etention 3 or 4 with or without ? at the end
} elsif (($u =~ /tube8|pornhub|xvideos/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?)\.([a-z]*[0-9]?\.[^\/]{3}\/[a-z]*)(.*?)((\/[a-z]*)?(\/[^\/]*){4}\.[^\/\?]{3,4})(\?.*)?$/)) {
   print $x . "http://cdn." . $3 . $5 . "\n";
         #...spicific servers end here.

         #photos-X.ak.fbcdn.net where X a-z
} elsif (m/^http:\/\/photos-[a-z].ak.fbcdn.net\/(.*)/) {
   print $x . "http://photos.ak.fbcdn.net/" . $1  . "\n";

         #general purpose for cdn servers. add above your specific servers.
} elsif (m/^http:\/\/([0-9.]*?)\/\/(.*?)\.(.*)\?(.*?)/) {
   print $x . "http://squid-cdn-url//" . $2  . "." . $3 . "\n";

         #for yimg.com doubled
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*?)\.yimg\.com\/(.*?)\?(.*)/) {
   print $x . "http://cdn.yimg.com/"  . $3 . "\n";

         #for yimg.com with &sig=
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*)/) {
   @y = ($1,$2);
   $y[0] =~ s/[a-z]+[0-9]+/cdn/;
   $y[1] =~ s/&sig=.*//;
   print $x . "http://" . $y[0] . ".yimg.com/"  . $y[1] . "\n";

         #generic http://variable.domain.com/path/filename."ext" or "exte" with or withour "?"
} elsif (m/^http:\/\/(.*)([^\.\-]*?\..*?)\/(.*)\.([^\/\?\&]{3,4})(\?.*)?$/) {
   @y = ($1,$2,$3,$4);
   $y[0] =~ s/(([a-zA-A-]+[0-9-]+)|(.*cdn.*)|(.*cache.*))/cdn/;
   print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

         # generic http://variable.domain.com/...
} elsif (m/^http:\/\/(([A-Za-z]+[0-9-]+)*?|.*cdn.*|.*cache.*)\.(.*?)\.(.*?)\/(.*)$/) {
   print $x . "http://cdn." . $3 . "." . $4 . "/" . $5 .  "\n";

         # spicific extention that ends with ?
} elsif (m/^http:\/\/(.*?)\/(.*?)\.(jp(e?g|e|2)|gif|png|tiff?|bmp|ico|flv|on2)\?(.*)/) {
   print $x . "http://" . $1 . "/" . $2  . "." . $3 . "\n";

         # all that ends with ;
} elsif (m/^http:\/\/(.*?)\/(.*?)\;(.*)/) {
   print $x . "http://" . $1 . "/" . $2  . "\n";

} else {
   print $x . $_ . "\n";
}
}
User avatar
antoniusgenta
Posts: 103
Joined: 29 Dec 2011, 14:40
Location: jakarta

Re: [HELP] Youtube An error occurred, please try again later

Postby antoniusgenta » 09 Apr 2012, 15:54

sipelaut wrote:oke
ini masbroo..
Tampilkan

Code: Select all

#!/usr/bin/perl
# $Rev$
# by chudy_fernandez@yahoo.com
# Updates at http://wiki.squid-cache.org/ConfigExamples/DynamicContent/YouTube/Discussion
$|=1;
while (<>) {
    @X = split;
#   $X[1] =~ s/&sig=.*//;
   $x = $X[0] . " ";
   $_ = $X[1];
   $u = $X[1];


         # compatibility for old cached get_video?video_id
if (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(videoplayback\?id=.*?|video_id=.*?)\&(.*?)/) {
   $z = $2; $z =~ s/video_id=/get_video?video_id=/;
   print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $z . "\n";

         # youtube HD itag=22
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=22).*?\&(id=[a-zA-Z0-9]*)/) {
   print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . "&" . $3 . "\n";

         # youtube Normal screen always HD itag 35, Normal screen never HD itag 34, itag=18 <--normal?
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=[0-9]*).*?\&(id=[a-zA-Z0-9]*)/) {
   print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $3 . "\n";

} elsif (m/^http:\/\/www\.google-analytics\.com\/__utm\.gif\?.*/) {
   print $x . "http://www.google-analytics.com/__utm.gif\n";

         #Cache High Latency Ads
} elsif (m/^http:\/\/([a-z0-9.]*)(\.doubleclick\.net|\.quantserve\.com|\.googlesyndication\.com|yieldmanager|cpxinteractive)(.*)/) {
   $y = $3;$z = $2;
   for ($y) {
   s/pixel;.*/pixel/;
   s/activity;.*/activity/;
   s/(imgad[^&]*).*/\1/;
   s/;ord=[?0-9]*//;
   s/;&timestamp=[0-9]*//;
   s/[&?]correlator=[0-9]*//;
   s/&cookie=[^&]*//;
   s/&ga_hid=[^&]*//;
   s/&ga_vid=[^&]*//;
   s/&ga_sid=[^&]*//;
   # s/&prev_slotnames=[^&]*//
   # s/&u_his=[^&]*//;
   s/&dt=[^&]*//;
   s/&dtd=[^&]*//;
   s/&lmt=[^&]*//;
   s/(&alternate_ad_url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/(&url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/(&ref=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/(&cookie=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
   s/[;&?]ord=[?0-9]*//;
   s/[;&]mpvid=[^&;]*//;
   s/&xpc=[^&]*//;
   # yieldmanager
   s/\?clickTag=[^&]*//;
   s/&u=[^&]*//;
   s/&slotname=[^&]*//;
   s/&page_slots=[^&]*//;
   }
   print $x . "http://" . $1 . $2 . $y . "\n";

         #cache high latency ads
} elsif (m/^http:\/\/(.*?)\/(ads)\?(.*?)/) {
   print $x . "http://" . $1 . "/" . $2  . "\n";

         # spicific servers starts here....
} elsif (m/^http:\/\/(www\.ziddu\.com.*\.[^\/]{3,4})\/(.*?)/) {
   print $x . "http://" . $1 . "\n";

         #cdn, varialble 1st path
} elsif (($u =~ /filehippo/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(.*)\.([a-z0-9]{3,4})(\?.*)?/)) {
   @y = ($1,$2,$4,$5);
   $y[0] =~ s/[a-z0-9]{2,5}/cdn./;
   print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

         #rapidshare
} elsif (($u =~ /rapidshare/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?)([a-z]*\.[^\/]{3}\/[a-z]*\/[0-9]*)\/(.*?)\/([^\/\?\&]{4,})$/)) {
   print $x . "http://cdn." . $3 . "/SQUIDINTERNAL/" . $5 . "\n";

} elsif (($u =~ /maxporn/) && (m/^http:\/\/([^\/]*?)\/(.*?)\/([^\/]*?)(\?.*)?$/)) {
   print $x . "http://" . $1 . "/SQUIDINTERNAL/" . $3 . "\n";

         #like porn hub variables url and center part of the path, filename etention 3 or 4 with or without ? at the end
} elsif (($u =~ /tube8|pornhub|xvideos/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?)\.([a-z]*[0-9]?\.[^\/]{3}\/[a-z]*)(.*?)((\/[a-z]*)?(\/[^\/]*){4}\.[^\/\?]{3,4})(\?.*)?$/)) {
   print $x . "http://cdn." . $3 . $5 . "\n";
         #...spicific servers end here.

         #photos-X.ak.fbcdn.net where X a-z
} elsif (m/^http:\/\/photos-[a-z].ak.fbcdn.net\/(.*)/) {
   print $x . "http://photos.ak.fbcdn.net/" . $1  . "\n";

         #general purpose for cdn servers. add above your specific servers.
} elsif (m/^http:\/\/([0-9.]*?)\/\/(.*?)\.(.*)\?(.*?)/) {
   print $x . "http://squid-cdn-url//" . $2  . "." . $3 . "\n";

         #for yimg.com doubled
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*?)\.yimg\.com\/(.*?)\?(.*)/) {
   print $x . "http://cdn.yimg.com/"  . $3 . "\n";

         #for yimg.com with &sig=
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*)/) {
   @y = ($1,$2);
   $y[0] =~ s/[a-z]+[0-9]+/cdn/;
   $y[1] =~ s/&sig=.*//;
   print $x . "http://" . $y[0] . ".yimg.com/"  . $y[1] . "\n";

         #generic http://variable.domain.com/path/filename."ext" or "exte" with or withour "?"
} elsif (m/^http:\/\/(.*)([^\.\-]*?\..*?)\/(.*)\.([^\/\?\&]{3,4})(\?.*)?$/) {
   @y = ($1,$2,$3,$4);
   $y[0] =~ s/(([a-zA-A-]+[0-9-]+)|(.*cdn.*)|(.*cache.*))/cdn/;
   print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

         # generic http://variable.domain.com/...
} elsif (m/^http:\/\/(([A-Za-z]+[0-9-]+)*?|.*cdn.*|.*cache.*)\.(.*?)\.(.*?)\/(.*)$/) {
   print $x . "http://cdn." . $3 . "." . $4 . "/" . $5 .  "\n";

         # spicific extention that ends with ?
} elsif (m/^http:\/\/(.*?)\/(.*?)\.(jp(e?g|e|2)|gif|png|tiff?|bmp|ico|flv|on2)\?(.*)/) {
   print $x . "http://" . $1 . "/" . $2  . "." . $3 . "\n";

         # all that ends with ;
} elsif (m/^http:\/\/(.*?)\/(.*?)\;(.*)/) {
   print $x . "http://" . $1 . "/" . $2  . "\n";

} else {
   print $x . $_ . "\n";
}
}


Jadinya seperti ini mas ... coba ditangkap ya!!!

Tampilkan
#!/usr/bin/perl
# $Rev$
# by chudy_fernandez@yahoo.com
# Youtube updates at http://wiki.squid-cache.org/ConfigExamp ... Discussion
$|=1;
while () {
@X = split;
# $X[1] =~ s/&sig=.*//;
$x = $X[0] . " ";
$_ = $X[1];
$u = $X[1];

#photos-X.ak.fbcdn.net where X a-z
if (m/^http:\/\/photos-[a-z]?(.ak.fbcdn.net.*)/) {
print $x . "http://photos" . $1 . "\n";

#http://hphotos-ash2.fbcdn.net/290503_1735121757952_1835833812_1146280_4168472_o.jpg
} elsif (m/^http:\/\/photos-ash[1-5]?(.fbcdn.net.*)/) {
print $x . "http://ash.photos" . $1 . "\n";

#http://a6.sphotos.ak.fbcdn.net/hphotos-ak-ash4/319568_206164829444513_152217858172544_542308_1727268_n.jpg
#a5.sphotos.ak.fbcdn.ne

} elsif (m/^http:\/\/[a-z][0-9]?(.sphotos.ak.fbcdn.net.*)/) {
print $x . "http://cdn.photos" . $1 . "\n";

#http://cityvillefb0.static.zgncdn.com/hashed/43897e86db37ffda95e0d015de72e2a4.png
} elsif (m/^http:\/\/cityvillefb[0-3]?(.static.zgncdn.com.*)/) {
print $x . "http://cityvillefb" . $1 . "\n";

#http://playerstatics1.poker.static.zynga.com/poker/image_proxy.php/aHR0cDovL3Byb2ZpbGUuYWsuZmJjZG4ubmV0L2hwcm9maWxlLWFrLXNuYzQvMjc0ODM2XzEwMDAwMjkwMTU1MTE3MV8xMDAwNTE0MjM3X24uanBn
} elsif (m/^http:\/\/playerstatics[1-9]?(.poker.static.zynga.com.*)/) {
print $x . "http://playerstatics.poker-zynga." . $1 . "\n";

#http://zynga4-a.akamaihd.net/zbar/game-icons/adventureworld-banner-Adventureadventuredame09162011-13161891413359.png
} elsif (m/^http:\/\/zynga[1-9]?-a(.akamaihd.net.*)/) {
print $x . "http://zynga-akamaihd.net." . $1 . "\n";

#http://s2.ninja.game321.com/source/bitmap/icon/debris/icon_debris134.s110.png
} elsif (m/^http:\/\/s[1-9]?(.ninja.game321.com.*)/) {
print $x . "http://ninja-game321." . $1 . "\n";

#http://i616.photobucket.com/albums/uu90/the_martian_cat/ATT00001-1.gif
} elsif (m/^http:\/\/i[1-9]{3}(.photobucket.com.*)/) {
print $x . "http://photobucket3." . $1 . "\n";

# http://i1221.photobucket.com/albums/dd4 ... 7bet-s.gif
} elsif (m/^http:\/\/i[1-9]{4}(.photobucket.com.*)/) {
print $x . "http://photobucket." . $1 . "\n";

#BLOGSPOT
} elsif (m/^http:\/\/[1-4]?(bp.blogspot.com.*)/) {
print $x . "http://blog-cdn." . $1 . "\n";

#http://lh6.ggpht.com/_pt7i0nbIOCY/SeBSfNbxQ_I/AAAAAAAABuA/lQToFnYZHKI/navhover_thumb%5B1%5D.png
} elsif (m/^http:\/\/lh[3-6]?(.ggpht.com.*)/) {
print $x . "http://ggpht." . $1 . "\n";

#http://a2.twimg.com/profile_images/1213095644/CBS-eye-white-bg_normal.jpg
} elsif (m/^http:\/\/a[0-5]?(.twimg.com.*)/) {
print $x . "http://cdn-twimg.com." . $1 . "\n";

#AVAST
} elsif (m/^http:\/\/download[0-9]{3}.(avast.com.*)/) {
print $x . "http://avast-cdn." . $1 . "\n";

#KAV
} elsif (m/^http:\/\/dnl-[0-9]{2}.(geo.kaspersky.com.*)/) {
print $x . "http://kav-cdn." . $1 . "\n";

#AVG
} elsif (m/^http:\/\/(update.avg.com.*)/) {
print $x . "http://avg-cdn." . $1 . "\n";

#static3.spilcdn.com/
} elsif (m/^http:\/\/static[1-9]?(.speelcdn.com.*)/) {
print $x . "http://speelcdn." . $1 . "\n";

#http://t1.gstatic.com
} elsif (m/^http:\/\/t[1-9]?(.gstatic.com.*)/) {
print $x . "http://cdn-gstatic.com." . $1 . "\n";

# http://0.gravatar.com
} elsif (m/^http:\/\/[0-3]?(.gravatar.com.*)/) {
print $x . "http://cdn-gravatar." . $1 . "\n";

#http://s5.scribdassets.com/images/attribution_noncommercial.png
} elsif (m/^http:\/\/s[1-8]?(.scribdassets.com.*)/) {
print $x . "http://cdn-scribdassets." . $1 . "\n";

# http://tc2.easythumbhost.com/
} elsif (m/^http:\/\/tc[0-9]?(.easythumbhost.com.*)/) {
print $x . "http://cdn-easythumbhost." . $1 . "\n";

#http://static7.spilcdn.com/tw/img/_/profile/dummy_small.png
} elsif (m/^http:\/\/static[1-7]?(.spilcdn.com.*)/) {
print $x . "http://spilcdn." . $1 . "\n";

#http://media5.picsearch.com/is
} elsif (m/^http:\/\/media[1-8]?(.picsearch.com.*)/) {
print $x . "http://cdn-picsearch." . $1 . "\n";

#http://lh3.googleusercontent.com/-z2ZV9VfLsc0/TmetBcUiRBI/AAAAAAAAC_k/-wvptlnDXuQ/03.png
} elsif (m/^http:\/\/lh[3-6]?(.googleusercontent.com.*)/) {
print $x . "http://googleusercontent." . $1 . "\n";

#http://i54.tinypic.com/2crkryu.jpg
} elsif (m/^http:\/\/i[0-9]{2}(.tinypic.com.*)/) {
print $x . "http://tinypic." . $1 . "\n";

#maps.google.com
} elsif (m/^http:\/\/(cbk|mt|khm|mlt|tbn)[0-9]?(.google\.co(m|\.uk|\.id).*)/) {
print $x . "http://" . $1 . $2 . "\n";

#gstatic and/or wikimapia
} elsif (m/^http:\/\/([a-z])[0-9]?(\.gstatic\.com.*|\.wikimapia\.org.*)/) {
print $x . "http://" . $1 . $2 . "\n";

# youtube fix
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com)\/videoplayback\?(.*)/) {
$p_str = $2;
$tag = "";
$alg = "";
$id = "";
$range = "";
if ($p_str =~ m/(itag=[0-9]*)/){$tag = "&".$1}
if ($p_str =~ m/(algorithm=[a-z]*\-[a-z]*)/){$alg = "&".$1}
if ($p_str =~ m/(id=[a-zA-Z0-9]*)/){$id = "&".$1}
if ($p_str =~ m/(range=[0-9\-]*)/){$range = "&".$1; $range =~ s/-//; $range =~ s/range=//; }
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $tag . "&" . $alg . "&" . $id . "&" . $range . "\n";

} elsif (m/^http:\/\/www\.google-analytics\.com\/__utm\.gif\?.*/) {
print $x . "http://www.google-analytics.com/__utm.gif\n";

#Cache High Latency Ads
} elsif (m/^http:\/\/([a-z0-9.]*)(\.doubleclick\.net|\.quantserve\.com|\.googlesyndication\.com|yieldmanager|cpxinteractive)(.*)/) {
$y = $3;$z = $2;
for ($y) {
s/pixel;.*/pixel/;
s/activity;.*/activity/;
s/(imgad[^&]*).*/\1/;
s/;ord=[?0-9]*//;
s/;&timestamp=[0-9]*//;
s/[&?]correlator=[0-9]*//;
s/&cookie=[^&]*//;
s/&ga_hid=[^&]*//;
s/&ga_vid=[^&]*//;
s/&ga_sid=[^&]*//;
# s/&prev_slotnames=[^&]*//
# s/&u_his=[^&]*//;
s/&dt=[^&]*//;
s/&dtd=[^&]*//;
s/&lmt=[^&]*//;
s/(&alternate_ad_url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&ref=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&cookie=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/[;&?]ord=[?0-9]*//;
s/[;&]mpvid=[^&;]*//;
s/&xpc=[^&]*//;
# yieldmanager
s/\?clickTag=[^&]*//;
s/&u=[^&]*//;
s/&slotname=[^&]*//;
s/&page_slots=[^&]*//;
}
print $x . "http://" . $1 . $2 . $y . "\n";

#cache high latency ads
} elsif (m/^http:\/\/(.*?)\/(ads)\?(.*?)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

#cdn, varialble 1st path
} elsif (($u =~ /filehippo|mediafire/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(.*)\.([a-zA-Z0-9]{2,3})(\?.*)?/)) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn./;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

} elsif (($u =~ /maxporn/) && (m/^http:\/\/([^\/]*?)\/(.*?)\/([^\/]*?)(\?.*)?$/)) {
print $x . "http://" . $1 . "/SQUIDINTERNAL/" . $3 . "\n";

#domain/path/.*/path/filename
} elsif (($u =~ /fucktube/) && (m/^http:\/\/(.*?)(\.[^\.\-]*?[^\/]*\/[^\/]*)\/(.*)\/([^\/]*)\/([^\/\?\&]*)\.([^\/\?\&]{3,4})(\?.*?)$/)) {
@y = ($1,$2,$4,$5,$6);
$y[0] =~ s/(([a-zA-Z]+[0-9]+(-[a-zA-Z])?$)|([^\.]*cdn[^\.]*)|([^\.]*cache[^\.]*))/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "/" . $y[3] . "." . $y[4] . "\n";

# #4shared audio/video preview
} elsif (($u =~ /4shared/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(dlink__2Fdownload_2F([^\/-]+))([a-zA-Z0-9-]+)\/([^\/\?\&]*\.[^\/\?\&]{2,3})(\?.*)?$/)) {
@y = ($1,$2,$3,$4,$7);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn./;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "/" . $y[3] . "/" . $y[4] . "\n";

#indowebster
} elsif (m/^http:\/\/(.*?)(\.jkt\.3d\.x\.indowebster.com)\/(.*?)\/([^\/\?\&]*)\.([^\/\?\&]{2,4})(\?.*?)$/) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/([a-z][0-9][a-z]dlod[\d]{3})|((cache|cdn)[-\d]*)|([a-zA-Z]+-?[0-9]+(-[a-zA-Z]*)?)/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

#like porn hub variables url and center part of the path, filename etention 3 or 4 with or without ? at the end
} elsif (($u =~ /tube8|pornhub|xvideos/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?(\.[a-z]*)?)\.([a-z]*[0-9]?\.[^\/]{3}\/[a-z]*)(.*?)((\/[a-z]*)?(\/[^\/]*){4}\.[^\/\?]{3,4})(\?.*)?$/)) {
print $x . "http://cdn." . $4 . $6 . "\n";

#for yimg.com video
} elsif (m/^http:\/\/(.*yimg.com)\/\/(.*)\/([^\/\?\&]*\/[^\/\?\&]*\.[^\/\?\&]{3,4})(\?.*)?$/) {
print $x . "http://cdn.yimg.com//" . $3 . "\n";

#for yimg.com doubled
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*?)\.yimg\.com\/(.*?)\?(.*)/) {
print $x . "http://cdn.yimg.com/" . $3 . "\n";

#for yimg.com with &sig=
} elsif (m/^http:\/\/([^\.]*)\.yimg\.com\/(.*)/) {
@y = ($1,$2);
$y[0] =~ s/[a-z]+([0-9]+)?/cdn/;
$y[1] =~ s/&sig=.*//;
print $x . "http://" . $y[0] . ".yimg.com/" . $y[1] . "\n";

#youjizz. We use only domain and filename
} elsif (($u =~ /media[0-9]{1,5}\.youjizz/) && (m/^http:\/\/(.*?)(\.[^\.\-]*?\.[^\/]*)\/(.*)\/([^\/\?\&]*)\.([^\/\?\&]{3,4})(\?.*?)$/)) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/(([a-zA-Z]+[0-9]+(-[a-zA-Z])?$)|([^\.]*cdn[^\.]*)|([^\.]*cache[^\.]*))/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

#general purpose for cdn servers. add above your specific servers.
} elsif (m/^http:\/\/([0-9.]*?)\/\/(.*?)\.(.*)\?(.*?)/) {
print $x . "http://squid-cdn-url//" . $2 . "." . $3 . "\n";

#generic http://variable.domain.com/path/filename. "ext" or "exte"
} elsif (m/^http:\/\/(.*?)(\.[^\.\-]*?\..*?)\/([^\?\&\=]*)\.([\w\d]{2,4})\??.*$/) {
@y = ($1,$2,$3,$4);
$y[0] =~ s/([a-z][0-9][a-z]dlod[\d]{3})|((cache|cdn)[-\d]*)|([a-zA-Z]+-?[0-9]+(-[a-zA-Z]*)?)/cdn/;
print $x . "storeurl://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

# all that ends with ;
} elsif (m/^http:\/\/(.*?)\/(.*?)\;(.*)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

} else {
print $x . $_ . "\n";
}
}


jgn lupa squidnya di reload setelah mengganti storeurlnya..

Kl sukses beri info ya..


Regards
Genta
User avatar
sipelaut
Posts: 1963
Joined: 03 Jan 2010, 17:25
Location: madura-sampang
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sipelaut » 10 Apr 2012, 14:31

oke tengkyu masbro....
sori baru sempat posting jam segini....
it's work...
meskipun kadang ada galatnya tapi dengan di refresh masalah teratasi
User avatar
antoniusgenta
Posts: 103
Joined: 29 Dec 2011, 14:40
Location: jakarta

Re: [HELP] Youtube An error occurred, please try again later

Postby antoniusgenta » 10 Apr 2012, 15:41

sipelaut wrote:oke tengkyu masbro....
sori baru sempat posting jam segini....
it's work...
meskipun kadang ada galatnya tapi dengan di refresh masalah teratasi


clear dulu cache-nya biar lebih meyakinkan...!!
User avatar
sipelaut
Posts: 1963
Joined: 03 Jan 2010, 17:25
Location: madura-sampang
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sipelaut » 10 Apr 2012, 20:45

antoniusgenta wrote:
sipelaut wrote:oke tengkyu masbro....
sori baru sempat posting jam segini....
it's work...
meskipun kadang ada galatnya tapi dengan di refresh masalah teratasi


clear dulu cache-nya biar lebih meyakinkan...!!

waduhh.... klo yang ini ane gak berani masbro.....
terlalu extrim (buat saya)
tapi udah beres keknya dengan hanya di reboot total servernya
sekarang bisa streaming 5 yutub tanpa galat......
mudah2 kedepannya gak ada masalah
:)
User avatar
antoniusgenta
Posts: 103
Joined: 29 Dec 2011, 14:40
Location: jakarta

Re: [HELP] Youtube An error occurred, please try again later

Postby antoniusgenta » 11 Apr 2012, 14:46

sipelaut wrote:
antoniusgenta wrote:
sipelaut wrote:oke tengkyu masbro....
sori baru sempat posting jam segini....
it's work...
meskipun kadang ada galatnya tapi dengan di refresh masalah teratasi


clear dulu cache-nya biar lebih meyakinkan...!!

waduhh.... klo yang ini ane gak berani masbro.....
terlalu extrim (buat saya)
tapi udah beres keknya dengan hanya di reboot total servernya
sekarang bisa streaming 5 yutub tanpa galat......
mudah2 kedepannya gak ada masalah
:)


Yup mantap.... Sebaiknya jika ada masalah dengan squid proxy ada baiknya share diforum ini,,siapa tau mastah2 bisa berkenan membantu dan saling bertukar informasi..

-------------------------------------
Linux mencerdaskan anak bangsa
User avatar
Aira
Posts: 70
Joined: 22 Mar 2012, 21:20

Re: [HELP] Youtube An error occurred, please try again later

Postby Aira » 21 Apr 2012, 12:57

Om2 dan mas2 di forum ini mohon bantuannya dan koreksinya

Squid.Conf
Tampilkan
http_port 3128 transparent
icp_port 0
server_http11 on
retry_on_error on
access_log /var/log/squid/access.log
cache_log /var/log/squid/cache.log
pid_filename /var/run/squid.pid
cache_store_log none
cache_mem 8 MB
maximum_object_size_in_memory 128 KB
memory_replacement_policy heap GDSF
cache_replacement_policy heap LFUDA
cache_dir aufs /cache 200000 470 256
logfile_rotate 1
shutdown_lifetime 10 seconds
acl localnet src 192.168.1.0/24
uri_whitespace strip
minimum_object_size 0 bytes
maximum_object_size 5120 MB
offline_mode off
cache_swap_low 98
cache_swap_high 99
cache_effective_user proxy
cache_effective_group proxy
error_directory /usr/share/squid/errors/English
icon_directory /usr/share/squid/icons
visible_hostname none
cache_mgr none

# Setup some default acls
acl all src 0.0.0.0/0.0.0.0
acl localhost src 127.0.0.1/255.255.255.255
acl safeports port 21 70 80 210 280 443 488 563 591 631 777 901 81 3128 1025-65535
acl sslports port 443 563 81
acl manager proto cache_object
acl purge method PURGE
acl connect method CONNECT
acl dynamic urlpath_regex cgi-bin \?

http_access allow manager localhost
http_access deny manager
http_access allow purge localhost
http_access deny purge
http_access deny !safeports
http_access deny CONNECT !sslports

# Always allow localhost connections
http_access allow localhost
http_access allow localnet
http_access deny all

# DENY CACHE
acl QUERY urlpath_regex -i \.(ini|lst|inf|htc|php|htm|html|asp)$
acl QUERY urlpath_regex -i (captcha|reset.css|update.txt|gamenotice|PatchTimeCheck.dat|PatchPath.dat|vdf.info.gz|version)
cache deny QUERY

# VIDEO URL CACHE
acl videocache_allow_url urlpath_regex \/(get_video|videoplayback\?id|videoplayback.*id) \.(jp(e?g|e|2)|gif|png|tiff?|bmp|ico|flv|wmv|3gp|mp(4|3)|exe|msi|zip|on2|mar|swf)\?
acl videocache_allow_url urlpath_regex -i \.youtube\.com\/get_video\?
acl videocache_allow_url urlpath_regex -i \.youtube\.com\/videoplayback \.youtube\.com\/videoplay \.youtube\.com\/get_video\?
acl videocache_allow_url urlpath_regex -i \.youtube\.[a-z][a-z]\/videoplayback \.youtube\.[a-z][a-z]\/videoplay \.youtube\.[a-z][a-z]\/get_video\?
acl videocache_allow_url urlpath_regex -i \.googlevideo\.com\/videoplayback \.googlevideo\.com\/videoplay \.googlevideo\.com\/get_video\?
acl videocache_allow_url urlpath_regex -i \.google\.com\/videoplayback \.google\.com\/videoplay \.google\.com\/get_video\?
acl videocache_allow_url urlpath_regex -i \.google\.[a-z][a-z]\/videoplayback \.google\.[a-z][a-z]\/videoplay \.google\.[a-z][a-z]\/get_video\?
acl videocache_allow_url urlpath_regex -i proxy[a-z0-9\-][a-z0-9][a-z0-9][a-z0-9]?\.dailymotion\.com\/
acl videocache_allow_url urlpath_regex -i vid\.akm\.dailymotion\.com\/
acl videocache_allow_url urlpath_regex -i [a-z0-9][0-9a-z][0-9a-z]?[0-9a-z]?[0-9a-z]?\.xtube\.com\/(.*)flv
acl videocache_allow_url urlpath_regex -i \.vimeo\.com\/(.*)\.(flv|mp4)
acl videocache_allow_url urlpath_regex -i va\.wrzuta\.pl\/wa[0-9][0-9][0-9][0-9]?
acl videocache_allow_url urlpath_regex -i \.youporn\.com\/(.*)\.flv
acl videocache_allow_url urlpath_regex -i \.msn\.com\.edgesuite\.net\/(.*)\.flv
acl videocache_allow_url urlpath_regex -i \.tube8\.com\/(.*)\.(flv|3gp)
acl videocache_allow_url urlpath_regex -i \.mais\.uol\.com\.br\/(.*)\.flv
acl videocache_allow_url urlpath_regex -i \.blip\.tv\/(.*)\.(flv|avi|mov|mp3|m4v|mp4|wmv|rm|ram|m4v)
acl videocache_allow_url urlpath_regex -i \.break\.com\/(.*)\.(flv|mp4)
acl videocache_allow_url urlpath_regex -i redtube\.com\/(.*)\.flv
acl store_rewrite_list_domain_CDN url_regex \.rapidshare\.com.*\/[0-9]*\/.*\/[^\/]* ^http:\/\/(www\.ziddu\.com.*\.[^\/]{3,4})\/(.*) \.doubleclick\.net.*
acl store_rewrite_list_domain_CDN url_regex ^http:\/\/[.a-z0-9]*\.photobucket\.com.*\.[a-z]{3}$ quantserve\.com
acl store_rewrite_list_domain_CDN url_regex ^http:\/\/[a-z]+[0-9]\.google\.co(m|\.id)
acl store_rewrite_list_domain_CDN url_regex ^http:\/\/\.www[0-9][0-9]\.indowebster\.com\/(.*)(rar|zip|flv|wm(a|v)|3gp|mp(4|3)|exe|msi|avi|(mp(e?g|a|e|1|2|3|4))|cab|exe)
acl videocache_allow_dom dstdomain .mccont.com .metacafe.com .cdn.dailymotion.com
acl videocache_deny_dom dstdomain .download.youporn.com .static.blip.tv
acl speedtest_allow_url url_regex -i \.speedtest\.net\/ speedtest
acl speedtest_allow_url url_regex ^http:\/\/speedtest\.*
acl speedtest_allow_dom dstdomain .speedtest.net
acl dontrewrite url_regex redbot\.org \.php
acl getmethod method GET

storeurl_access deny dontrewrite
storeurl_access deny !getmethod
storeurl_access deny videocache_deny_dom
storeurl_access allow videocache_allow_url
storeurl_access allow videocache_allow_dom
storeurl_access allow store_rewrite_list_domain_CDN
storeurl_access allow speedtest_allow_url
storeurl_access allow speedtest_allow_dom
storeurl_access deny all

# REDIRECTOR
storeurl_rewrite_program /etc/squid/storeurl.pl
storeurl_rewrite_children 4
storeurl_rewrite_concurrency 99

# 1 year = 525600 mins, 1 month = 43800 mins
# refresh patterns
refresh_pattern -i \.(cab|3gp|swf|mp4|mp3|mkv|rm|rmvb|avi|mpeg|mpg)$ 43200 95% 262800 ignore-reload ignore-no-cache ignore-private override-expire

# web contents
refresh_pattern -i \.(class|css|js|xml)$ 1440 50% 10080 ignore-no-cache ignore-private reload-into-ims override-lastmod
refresh_pattern -i \.index\.(html|htm|php)$ 0 50% 1
refresh_pattern -i \.(cgi|asp|shtml|pl|html|htm)$ 0 20% 1

refresh_pattern imeem.*\.flv 0 0% 0 override-lastmod override-expire store-stale
refresh_pattern \.rapidshare.*\/[0-9]*\/.*\/[^\/]* 161280 90% 161280 ignore-reload store-stale
refresh_pattern (get_video\?|videoplayback\?|videodownload\?|\.flv?) 129600 999999% 129600 ignore-no-cache ignore-no-store ignore-private override-expire override-lastmod reload-into-ims store-stale
refresh_pattern (get_video\?|videoplayback\?id|videoplayback.*id|videodownload\?|\.flv?) 129600 999999% 129600 ignore-no-cache ignore-no-store ignore-private override-expire override-lastmod reload-into-ims store-stale
refresh_pattern -i (get_video\?|videoplayback\?id|videoplayback.*id) 10080 500% 43200 override-expire ignore-no-cache ignore-private ignore-reload
refresh_pattern \.(ico|video-stats) 129600 999999% 129600 override-expire ignore-reload ignore-no-cache ignore-no-store ignore-private ignore-auth override-lastmod ignore-must-revalidate negative-ttl=10080 store-stale
refresh_pattern \.etology\? 129600 999999% 129600 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern galleries\.video(\?|sz) 129600 999999% 129600 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern brazzers\? 129600 999999% 129600 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern \.adtology\? 129600 999999% 129600 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern ^.*(utm\.gif|ads\?|rmxads\.com|ad\.z5x\.net|bh\.contextweb\.com|bstats\.adbrite\.com|a1\.interclick\.com|ad\.trafficmp\.com|ads\.cubics\.com|ad\.xtendmedia\.com|\.googlesyndication\.com|advertising\.com|yieldmanager|game-advertising\.com|pixel\.quantserve\.com|adperium\.com|doubleclick\.net|adserving\.cpxinteractive\.com|syndication\.com|media.fastclick.net).* 129600 20% 129600 ignore-no-cache ignore-no-store ignore-private override-expire ignore-reload ignore-auth ignore-must-revalidate store-stale negative-ttl=40320 max-stale=10
refresh_pattern ^.*safebrowsing.*google 129600 999999% 129600 override-expire ignore-reload ignore-no-cache ignore-private ignore-auth ignore-must-revalidate negative-ttl=10080 store-stale
refresh_pattern ^http://((cbk|mt|khm|mlt)[0-9]?)\.google\.co(m|\.uk) 129600 999999% 129600 override-expire ignore-reload ignore-private store-stale negative-ttl=10080
refresh_pattern ytimg\.com.*\.jpg 129600 999999% 129600 override-expire ignore-reload store-stale
refresh_pattern images\.friendster\.com.*\.(png|gif) 129600 999999% 129600 override-expire ignore-reload store-stale
refresh_pattern garena\.com 129600 999999% 129600 override-expire reload-into-ims store-stale
refresh_pattern photobucket.*\.(jp(e?g|e|2)|tiff?|bmp|gif|png) 129600 999999% 129600 override-expire ignore-reload store-stale
refresh_pattern vid\.akm\.dailymotion\.com.*\.on2\? 129600 999999% 129600 ignore-no-cache override-expire override-lastmod store-stale
refresh_pattern mediafire.com\/images.*\.(jp(e?g|e|2)|tiff?|bmp|gif|png) 129600 999999% 129600 reload-into-ims override-expire ignore-private store-stale
refresh_pattern ^http:\/\/images|pics|thumbs[0-9]\. 129600 999999% 129600 reload-into-ims ignore-no-cache ignore-no-store ignore-reload override-expire store-stale
refresh_pattern ^http:\/\/www.onemanga.com.*\/ 129600 999999% 129600 reload-into-ims ignore-no-cache ignore-no-store ignore-reload override-expire store-stale

# DETIK
refresh_pattern -i ^http://.*\.detik\.com/ 0 50% 4320
refresh_pattern -i ^http://.*\.detiknews\.com/ 0 50% 4320
refresh_pattern -i ^http://.*\.detikhot\.com/ 0 50% 4320
refresh_pattern -i ^http://.*\.detikfinance\.com/ 0 50% 4320
refresh_pattern -i ^http://.*\.detiksport\.com/ 0 50% 4320

# GAMES IIX
refresh_pattern ^http://file.pb.gemscool.com/hackshield/.* 60 100% 120 override-expire override-lastmod reload-into-ims store-stale
refresh_pattern ^http://file\.pb\.gemscool\.com/gamepatch/.*\.(exe|dll|cab|zip) 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth store-stale
refresh_pattern ^http://file\.fs\.gemscool\.com/JCE/.*\.(exe|dll|cab|zip) 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth store-stale
refresh_pattern ^http://file\.atlantica\.gemscool\.com/.*\.* 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth store-stale
refresh_pattern ^http://122\.102\.49\.132/.*\.(zip|exe) 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth ignore-no-store store-stale
refresh_pattern ^http://122\.102\.49\.202/.*\.(kom|zip|exe|stg) 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth ignore-no-store store-stale
refresh_pattern ^http://.*\.cabalonline\.co\.id/.*\.(cab|zip|exe|rar|dat) 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth store-stale
refresh_pattern ^http://.*\.gemscool\.com/.*\.(cab|zip|exe|rar|dat) 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth store-stale
refresh_pattern ^http://patch\.crossfire\.web\.id/.*\.(cab|zip|exe|rar|dat) 1440 100% 4320 override-expire override-lastmod reload-into-ims ignore-auth store-stale

# FILE TYPE
refresh_pattern -i \.(flv|x-flv|mov|avi|qt|mpg|mpeg)$ 10080 50% 43200 override-expire override-lastmod reload-into-ims ignore-reload ignore-no-cache store-stale ignore-must-revalidate
refresh_pattern -i \.(swf|wav|mp3|mp4|au|mid)$ 10080 50% 43200 override-expire override-lastmod reload-into-ims ignore-reload ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern -i \.(iso|deb|rpm|zip|tar|tgz|ram|rar|bin|ppt|doc)$ 10080 90% 43200 ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern -i \.(zip|gz|arj|lha|lzh)$ 10080 100% 43200 override-expire ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern -i \.(rar|tgz|tar|exe|bin)$ 10080 100% 43200 override-expire ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern -i \.(hqx|pdf|rtf|doc)$ 10080 100% 43200 override-expire ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern -i \.(inc|cab|ad|txt|dll)$ 10080 100% 43200 override-expire ignore-no-cache ignore-auth store-stale ignore-must-revalidate

#SPESIFIC GAMES URL
refresh_pattern ^http://*.lytogame.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.megaxus.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.ayodance.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.gemscool.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.wavegame.net/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.playcircle.net/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.lineage2.co.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.roseonline.web.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.xshot.web.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.romonline.web.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.iahgames.co.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.vtconline.co.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.blackshotonline.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.speedsoft.co.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.ijji.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.mmosite.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate

# SPESIFIC URL
refresh_pattern ^http://*.jobstreet.com.*/.* 720 100% 10080 override-expire override-lastmod ignore-no-cache store-stale ignore-must-revalidate
refresh_pattern ^http://*.indowebster.com.*/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-reload ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.21cineplex.*/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-reload ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.kompas.*/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.blogspot.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.wordpress.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache store-stale ignore-must-revalidate
refresh_pattern ^http://*.photobucket.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.tinypic.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.imageshack.us/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.kaskus.*/.* 720 100% 28800 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.detik.*/.* 720 50% 2880 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.detiknews.*/*.* 720 50% 2880 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://video.liputan6.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://static.liputan6.com/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.friendster.com/.* 720 100% 10080 override-expire override-lastmod ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.forummikrotik.com/.* 720 80% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://*.linux.or.id/.* 720 100% 10080 override-expire override-lastmod reload-into-ims ignore-no-cache ignore-auth store-stale ignore-must-revalidate
refresh_pattern ^http://(.*?)/get_video\? 10080 90% 999999 override-expire ignore-no-cache ignore-private store-stale ignore-must-revalidate
refresh_pattern ^http://(.*?)/videodownload\? 10080 90% 999999 override-expire ignore-no-cache ignore-private store-stale ignore-must-revalidate

#ANTIVIRUS
refresh_pattern guru.avg.com/.*\.(bin) 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern avast.com.*\.vpx 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern (avgate|avira).*\.(idx|gz)$ 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern kaspersky.*\.avc$ 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern kaspersky 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern liveupdate.symantecliveupdate.com.*\.zip 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern .update.nai.com/.*\.(gem|zip|mcs) 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern .symantec.com.*\(exe|zip) 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern mbamupdates.com.*\.ref 43200 999999% 43200 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale

# WINDOWS UPDATE
refresh_pattern windowsupdate.com/.*\.(cab|exe) 43200 999999% 129600 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern update.microsoft.com/.*\.(cab|exe) 43200 999999% 129600 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale
refresh_pattern download.microsoft.com/.*\.(cab|exe) 43200 999999% 129600 ignore-no-cache ignore-no-store ignore-reload reload-into-ims store-stale

# FACEBOOK IMAGE
refresh_pattern ((facebook.com)|(85.131.151.39)).*\.(jpg|png|gif) 21600 999999% 129600 ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern -i \.fbcdn.net.*\.(jpg|gif|png|swf|mp3) 21600 999999% 129600 ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern -i ^http:\/\/*\.[a-z]\.fbcdn.net.*\.(jpg|gif|png|swf|mp3|flv|mp4) 43800 200% 10080 ignore-reload override-expire ignore-no-cache ignore-private reload-into-ims
refresh_pattern static\.[a-z]\.ak\.fbcdn\.net*\.(jpg|gif|png) 21600 999999% 129600 ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/profile\.[a-z]\.ak\.fbcdn.net*\.(jpg|gif|png) 21600 999999% 129600 ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern -i \.(jp(e?g|e|2)|gif|png|tiff?|bmp|ico|flv)(\?|$) 10080 300% 43200 override-expire override-lastmod reload-into-ims ignore-reload
refresh_pattern -i ^http:\/\/*\.akamaihd\.(net|com).*\.(jpg|gif|png) 43800 200% 10080 ignore-reload override-expire ignore-no-cache ignore-private reload-into-ims

# facebook games
refresh_pattern ^http:\/\/apps.facebook.com.*\/ 10080 999999% 43200 ignore-reload override-expire ignore-no-cache
refresh_pattern -i \.zynga.com.*\/ 10080 999999% 43200 ignore-reload override-expire ignore-no-cache
refresh_pattern -i \.farmville.com.*\/ 10080 999999% 43200 ignore-reload override-expire ignore-no-cache
refresh_pattern -i \.ninjasaga.com.*\/ 10080 999999% 43200 ignore-reload override-expire ignore-no-cache
refresh_pattern -i \.mafiawars.com.*\/ 10080 999999% 43200 ignore-reload override-expire ignore-no-cache
refresh_pattern -i \.crowdstar.com.*\/ 10080 999999% 43200 ignore-reload override-expire ignore-no-cache

# BANNER IIX
refresh_pattern ^http:\/\/openx.*\.(jp(e?g|e|2)|gif|pn[pg]|swf|ico|css|tiff?) 129600 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/ads(1|2|3).kompas.com.*\/ 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/img.ads.kompas.com.*\/ 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern .kompasimages.com.*\.(jpg|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/openx.kompas.com.*\/ 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern kaskus.\us.*\.(jp(e?g|e|2)|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern -i cdn-[a-z]\.kaskus.\us.*\.(jp(e?g|e|2)|gif|png) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache
refresh_pattern ^.*(utm\.gif|ads\?|rmxads\.com|ad\.z5x\.net|bh\.contextweb\.com|bstats\.adbrite\.com|a1\.interclick\.com|ad\.trafficmp\.com|ads\.cubics\.com|ad\.xtendmedia\.com|\.googlesyndication\.com|advertising\.com|yieldmanager|game-advertising\.com|pixel\.quantserve\.com|adperium\.com|doubleclick\.net|adserving\.cpxinteractive\.com|syndication\.com|media.fastclick.net).* 43200 20% 43200 ignore-no-cache ignore-private override-expire ignore-reload
refresh_pattern ^http:\/\/img.kaskus.us.*\.(jpg|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/img.gemscool.com.*\.(jpg|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/img.pb.gemscool.com.*\.(jpg|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/img.atlantica.gemscool.com.*\.(jpg|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/img.fs.gemscool.com.*\.(jpg|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale
refresh_pattern ^http:\/\/img.vivanews.com.*\.(jpg|gif|png|swf) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale

# IIX DOWNLOAD
refresh_pattern ^http:\/\/\.www[0-9][0-9]\.indowebster\.com\/(.*)(mp3|rar|zip|flv|wmv|3gp|mp(4|3)|exe|msi|zip) 43200 99999% 129600 reload-into-ims ignore-reload override-expire ignore-no-cache ignore-no-store store-stale ignore-auth

#OTHER URL
refresh_pattern \.rapidshare.*\/[0-9]*\/.*\/[^\/]* 161280 90% 161280 ignore-reload store-stale
refresh_pattern (get_video\?|videoplayback\?|videodownload\?|\.flv?) 5259487 99999999% 5259487 override-expire ignore-reload store-stale ignore-private negative-ttl=0
refresh_pattern \.(ico|video-stats) 5259487 999999% 5259487 override-expire ignore-reload ignore-no-cache ignore-no-store ignore-private ignore-auth override-lastmod ignore-must-revalidate negative-ttl=10080 store-stale
refresh_pattern \.etology\? 5259487 999999% 5259487 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern galleries\.video(\?|sz) 5259487 999999% 5259487 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern brazzers\? 5259487 999999% 5259487 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern \.adtology\? 5259487 999999% 5259487 override-expire ignore-reload ignore-no-cache store-stale
refresh_pattern ^.*safebrowsing.*google 5259487 999999% 5259487 override-expire ignore-reload ignore-no-cache ignore-no-store ignore-private ignore-auth ignore-must-revalidate negative-ttl=10080 store-stale
refresh_pattern ^http://((cbk|mt|khm|mlt)[0-9]?)\.google\.co(m|\.id) 5259487 999999% 5259487 override-expire ignore-reload store-stale ignore-private negative-ttl=10080
refresh_pattern ytimg\.com.*\.(jpg|png) 5259487 999999% 5259487 override-expire ignore-reload store-stale
refresh_pattern images\.friendster\.com.*\.(png|gif) 5259487 999999% 5259487 override-expire ignore-reload store-stale
refresh_pattern garena\.com 5259487 999999% 5259487 override-expire reload-into-ims store-stale
refresh_pattern photobucket.*\.(jp(e?g|e|2)|tiff?|bmp|gif|png) 5259487 999999% 5259487 override-expire ignore-reload store-stale
refresh_pattern vid\.akm\.dailymotion\.com.*\.on2\? 5259487 999999% 5259487 ignore-no-cache override-expire override-lastmod store-stale
refresh_pattern ^http:\/\/images|openx|pics|thumbs[0-9]\. 5259487 999999% 5259487 ignore-no-cache ignore-no-store ignore-reload override-expire store-stale
refresh_pattern ^http:\/\/www.onemanga.com.*\/ 5259487 999999% 5259487 reload-into-ims override-expire store-stale
refresh_pattern mediafire.com\/images.*\.(jp(e?g|e|2)|tiff?|bmp|gif|png) 5259487 999999% 5259487 reload-into-ims override-expire ignore-private store-stale
refresh_pattern ^http://v\.okezone\.com/get_video\/([a-zA-Z0-9]) 43200 999999% 43200 override-expire ignore-reload ignore-no-cache ignore-private override-lastmod

refresh_pattern \.(jp(e?g|e|2)|tiff?|bmp|gif|png) 0 999999% 4380 ignore-no-cache ignore-no-store reload-into-ims override-expire ignore-must-revalidate store-stale
refresh_pattern \.(z(ip|[0-9]{2})|r(ar|[0-9]{2})|jar|bz2|gz|tar|rpm|vpu) 5259487 100% 5259487 override-expire reload-into-ims
refresh_pattern \.(mp3|wav|og(g|a)|flac|midi?|rm|aac|wma|mka|ape) 5259487 100% 5259487 override-expire reload-into-ims ignore-reload
refresh_pattern \.(exe|msi|dmg|bin|xpi|iso|swf|mar|psf|cab) 5259487 999999%% 5259487 override-expire reload-into-ims ignore-no-cache ignore-must-revalidate
refresh_pattern -i \.(exe|zip|rar|tgz|msi|sis|xpi|bin|jar)(\?|$) 10080 3000% 43200 reload-into-ims ignore-no-cache
refresh_pattern \.(mpeg|ra?m|avi|mp(g|e|4)|mov|divx|asf|wmv|m\dv|rv|vob|asx|ogm|flv|3gp|on2) 5259487 100% 5259487 override-expire reload-into-ims
refresh_pattern \.(pp(t?x)|s|t)|pdf|rtf|wax|wm(a|v)|wmx|wpl|cb(r|z|t)|xl(s?x)|do(c?x)) 43200 999999% 129600 ignore-no-cache ignore-private override-expire override-lastmod reload-into-ims store-stale
refresh_pattern -i \.index.(html|htm|php|asp|aspx)$ 0 40% 4320
refresh_pattern -i (cgi-bin) 0 0% 0
refresh_pattern (cgi-bin|\?) 0 0% 0
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern ^ftp: 10080 95% 43200 override-lastmod reload-into-ims store-stale
refresh_pattern . 180 95% 43200 override-lastmod reload-into-ims store-stale

# CONFIGURATION OF TUNNING
header_access X-Forwarded-For deny all
header_access Accept-Encoding deny all
client_persistent_connections off
server_persistent_connections on
half_closed_clients off
strip_query_terms off
quick_abort_min 0 KB
quick_abort_max 0 KB
quick_abort_pct 100
vary_ignore_expire on
reload_into_ims on
pipeline_prefetch on
#range_offset_limit 50 KB
#read_timeout 30 minutes
#client_lifetime 6 hours
negative_ttl 30 seconds
positive_dns_ttl 6 hours
negative_dns_ttl 60 seconds
pconn_timeout 15 seconds
request_timeout 1 minute
store_avg_object_size 13 KB
log_icp_queries off
ipcache_size 16384
ipcache_low 98
ipcache_high 99
log_fqdn off
fqdncache_size 16384
memory_pools off
forwarded_for on
prefer_direct on

#TAG ZPH TOS
tcp_outgoing_tos 0x30 localnet
zph_mode tos
zph_local 0x30
zph_parent 0
zph_option 136

#cachemgr_passwd none info
cachemgr_passwd none all
client_db on
max_filedescriptors 8192

######### for Lusca Only #############
#n_aiops_threads 24
#load_check_stopen on
#load_check_stcreate on
#download_fastest_client_speed on

Storeurl.pl
Tampilkan
#!/usr/bin/perl
# $Rev$
# by chudy_fernandez@yahoo.com
# Updates at http://wiki.squid-cache.org/ConfigExamp ... Discussion
$|=1;
while () {
@X = split;
# $X[1] =~ s/&sig=.*//;
$x = $X[0] . " ";
$_ = $X[1];
$u = $X[1];


# compatibility for old cached get_video?video_id
if (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(videoplayback\?id=.*?|video_id=.*?)\&(.*?)/) {
$z = $2; $z =~ s/video_id=/get_video?video_id=/;
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $z . "\n";

# youtube HD itag=22
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=22).*?\&(id=[a-zA-Z0-9]*)/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . "&" . $3 . "\n";

# youtube Normal screen always HD itag 35, Normal screen never HD itag 34, itag=18 <--normal?
} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=[0-9]*).*?\&(id=[a-zA-Z0-9]*)/) {
print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $3 . "\n";

} elsif (m/^http:\/\/www\.google-analytics\.com\/__utm\.gif\?.*/) {
print $x . "http://www.google-analytics.com/__utm.gif\n";

#Cache High Latency Ads
} elsif (m/^http:\/\/([a-z0-9.]*)(\.doubleclick\.net|\.quantserve\.com|\.googlesyndication\.com|yieldmanager|cpxinteractive)(.*)/) {
$y = $3;$z = $2;
for ($y) {
s/pixel;.*/pixel/;
s/activity;.*/activity/;
s/(imgad[^&]*).*/\1/;
s/;ord=[?0-9]*//;
s/;&timestamp=[0-9]*//;
s/[&?]correlator=[0-9]*//;
s/&cookie=[^&]*//;
s/&ga_hid=[^&]*//;
s/&ga_vid=[^&]*//;
s/&ga_sid=[^&]*//;
# s/&prev_slotnames=[^&]*//
# s/&u_his=[^&]*//;
s/&dt=[^&]*//;
s/&dtd=[^&]*//;
s/&lmt=[^&]*//;
s/(&alternate_ad_url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&url=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&ref=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/(&cookie=http%3A%2F%2F[^(%2F)]*)[^&]*/\1/;
s/[;&?]ord=[?0-9]*//;
s/[;&]mpvid=[^&;]*//;
s/&xpc=[^&]*//;
# yieldmanager
s/\?clickTag=[^&]*//;
s/&u=[^&]*//;
s/&slotname=[^&]*//;
s/&page_slots=[^&]*//;
}
print $x . "http://" . $1 . $2 . $y . "\n";

#cache high latency ads
} elsif (m/^http:\/\/(.*?)\/(ads)\?(.*?)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

# spicific servers starts here....
} elsif (m/^http:\/\/(www\.ziddu\.com.*\.[^\/]{3,4})\/(.*?)/) {
print $x . "http://" . $1 . "\n";

#cdn, varialble 1st path
} elsif (($u =~ /filehippo/) && (m/^http:\/\/(.*?)\.(.*?)\/(.*?)\/(.*)\.([a-z0-9]{3,4})(\?.*)?/)) {
@y = ($1,$2,$4,$5);
$y[0] =~ s/[a-z0-9]{2,5}/cdn./;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

#rapidshare
} elsif (($u =~ /rapidshare/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?)([a-z]*\.[^\/]{3}\/[a-z]*\/[0-9]*)\/(.*?)\/([^\/\?\&]{4,})$/)) {
print $x . "http://cdn." . $3 . "/SQUIDINTERNAL/" . $5 . "\n";

} elsif (($u =~ /maxporn/) && (m/^http:\/\/([^\/]*?)\/(.*?)\/([^\/]*?)(\?.*)?$/)) {
print $x . "http://" . $1 . "/SQUIDINTERNAL/" . $3 . "\n";

#like porn hub variables url and center part of the path, filename etention 3 or 4 with or without ? at the end
} elsif (($u =~ /tube8|pornhub|xvideos/) && (m/^http:\/\/(([A-Za-z]+[0-9-.]+)*?)\.([a-z]*[0-9]?\.[^\/]{3}\/[a-z]*)(.*?)((\/[a-z]*)?(\/[^\/]*){4}\.[^\/\?]{3,4})(\?.*)?$/)) {
print $x . "http://cdn." . $3 . $5 . "\n";
#...spicific servers end here.

#photos-X.ak.fbcdn.net where X a-z
} elsif (m/^http:\/\/photos-[a-z].ak.fbcdn.net\/(.*)/) {
print $x . "http://photos.ak.fbcdn.net/" . $1 . "\n";

#general purpose for cdn servers. add above your specific servers.
} elsif (m/^http:\/\/([0-9.]*?)\/\/(.*?)\.(.*)\?(.*?)/) {
print $x . "http://squid-cdn-url//" . $2 . "." . $3 . "\n";

#for yimg.com doubled
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*?)\.yimg\.com\/(.*?)\?(.*)/) {
print $x . "http://cdn.yimg.com/" . $3 . "\n";

#for yimg.com with &sig=
} elsif (m/^http:\/\/(.*?)\.yimg\.com\/(.*)/) {
@y = ($1,$2);
$y[0] =~ s/[a-z]+[0-9]+/cdn/;
$y[1] =~ s/&sig=.*//;
print $x . "http://" . $y[0] . ".yimg.com/" . $y[1] . "\n";

#generic http://variable.domain.com/path/filename. or "exte" with or withour "?"
} elsif (m/^http:\/\/(.*)([^\.\-]*?\..*?)\/(.*)\.([^\/\?\&]{3,4})(\?.*)?$/) {
@y = ($1,$2,$3,$4);
$y[0] =~ s/(([a-zA-A-]+[0-9-]+)|(.*cdn.*)|(.*cache.*))/cdn/;
print $x . "http://" . $y[0] . $y[1] . "/" . $y[2] . "." . $y[3] . "\n";

# generic http://variable.domain.com/...
} elsif (m/^http:\/\/(([A-Za-z]+[0-9-]+)*?|.*cdn.*|.*cache.*)\.(.*?)\.(.*?)\/(.*)$/) {
print $x . "http://cdn." . $3 . "." . $4 . "/" . $5 . "\n";

# spicific extention that ends with ?
} elsif (m/^http:\/\/(.*?)\/(.*?)\.(jp(e?g|e|2)|gif|png|tiff?|bmp|ico|flv|on2)\?(.*)/) {
print $x . "http://" . $1 . "/" . $2 . "." . $3 . "\n";

# all that ends with ;
} elsif (m/^http:\/\/(.*?)\/(.*?)\;(.*)/) {
print $x . "http://" . $1 . "/" . $2 . "\n";

} else {
print $x . $_ . "\n";
}
}

Cacahe proxy lambat mengisinya dan kalau browsing suka loading/ada jeda dulu...
Mohon koreksi dan kritikannya...
User avatar
sudo2su
Posts: 25
Joined: 28 Apr 2012, 02:24
Location: pare, indonesia
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby sudo2su » 02 May 2012, 20:57

ijin nyoba ya
User avatar
Bandi_Shippuden
Posts: 62
Joined: 04 May 2012, 12:06
Location: Pekanbaru, Indonesia
Contact:

Re: [HELP] Youtube An error occurred, please try again later

Postby Bandi_Shippuden » 04 May 2012, 12:26

passwornya pa mas ? :confused:

Return to “Ubuntu Server”

Who is online

Users browsing this forum: No registered users and 25 guests