summaryrefslogtreecommitdiffstats
path: root/module/plugins/crypter
diff options
context:
space:
mode:
Diffstat (limited to 'module/plugins/crypter')
-rw-r--r--module/plugins/crypter/BitshareComFolder.py31
-rw-r--r--module/plugins/crypter/C1neonCom.py13
-rw-r--r--module/plugins/crypter/CrockoComFolder.py15
-rw-r--r--module/plugins/crypter/CryptItCom.py13
-rw-r--r--module/plugins/crypter/CzshareComFolder.py31
-rw-r--r--module/plugins/crypter/DDLMusicOrg.py45
-rw-r--r--module/plugins/crypter/DataHuFolder.py55
-rw-r--r--module/plugins/crypter/DdlstorageComFolder.py30
-rw-r--r--module/plugins/crypter/DepositfilesComFolder.py15
-rw-r--r--module/plugins/crypter/Dereferer.py35
-rw-r--r--module/plugins/crypter/DontKnowMe.py22
-rw-r--r--module/plugins/crypter/DownloadVimeoCom.py31
-rw-r--r--module/plugins/crypter/DuckCryptInfo.py57
-rw-r--r--module/plugins/crypter/DuploadOrgFolder.py30
-rw-r--r--module/plugins/crypter/EasybytezComFolder.py35
-rw-r--r--module/plugins/crypter/EmbeduploadCom.py53
-rw-r--r--module/plugins/crypter/FilebeerInfoFolder.py14
-rw-r--r--module/plugins/crypter/FilefactoryComFolder.py45
-rw-r--r--module/plugins/crypter/FileserveComFolder.py33
-rw-r--r--module/plugins/crypter/FilestubeCom.py31
-rw-r--r--module/plugins/crypter/FiletramCom.py31
-rw-r--r--module/plugins/crypter/FourChanOrg.py26
-rw-r--r--module/plugins/crypter/FreakhareComFolder.py47
-rw-r--r--module/plugins/crypter/FreetexthostCom.py37
-rw-r--r--module/plugins/crypter/FshareVnFolder.py15
-rw-r--r--module/plugins/crypter/GooGl.py41
-rw-r--r--module/plugins/crypter/HoerbuchIn.py56
-rw-r--r--module/plugins/crypter/HotfileFolderCom.py28
-rw-r--r--module/plugins/crypter/ILoadTo.py13
-rw-r--r--module/plugins/crypter/LetitbitNetFolder.py33
-rw-r--r--module/plugins/crypter/LinkSaveIn.py228
-rw-r--r--module/plugins/crypter/LinkdecrypterCom.py104
-rw-r--r--module/plugins/crypter/LixIn.py59
-rw-r--r--module/plugins/crypter/LofCc.py13
-rw-r--r--module/plugins/crypter/MBLinkInfo.py13
-rw-r--r--module/plugins/crypter/MediafireComFolder.py57
-rw-r--r--module/plugins/crypter/Movie2kTo.py13
-rw-r--r--module/plugins/crypter/MultiloadCz.py42
-rw-r--r--module/plugins/crypter/MultiuploadCom.py64
-rw-r--r--module/plugins/crypter/NCryptIn.py304
-rw-r--r--module/plugins/crypter/NetfolderIn.py71
-rw-r--r--module/plugins/crypter/OneKhDe.py38
-rwxr-xr-xmodule/plugins/crypter/OronComFolder.py13
-rw-r--r--module/plugins/crypter/PastebinCom.py31
-rw-r--r--module/plugins/crypter/QuickshareCzFolder.py31
-rw-r--r--module/plugins/crypter/RSLayerCom.py13
-rw-r--r--module/plugins/crypter/RelinkUs.py264
-rw-r--r--module/plugins/crypter/SecuredIn.py13
-rw-r--r--module/plugins/crypter/SerienjunkiesOrg.py320
-rw-r--r--module/plugins/crypter/ShareLinksBiz.py269
-rw-r--r--module/plugins/crypter/ShareRapidComFolder.py15
-rw-r--r--module/plugins/crypter/SpeedLoadOrgFolder.py28
-rw-r--r--module/plugins/crypter/StealthTo.py49
-rw-r--r--module/plugins/crypter/TrailerzoneInfo.py13
-rw-r--r--module/plugins/crypter/TurbobitNetFolder.py60
-rw-r--r--module/plugins/crypter/UlozToFolder.py42
-rw-r--r--module/plugins/crypter/UploadedToFolder.py50
-rw-r--r--module/plugins/crypter/WiiReloadedOrg.py13
-rw-r--r--module/plugins/crypter/XupPl.py18
-rw-r--r--module/plugins/crypter/YoutubeBatch.py44
-rw-r--r--module/plugins/crypter/__init__.py0
61 files changed, 0 insertions, 3253 deletions
diff --git a/module/plugins/crypter/BitshareComFolder.py b/module/plugins/crypter/BitshareComFolder.py
deleted file mode 100644
index b77ddb9d9..000000000
--- a/module/plugins/crypter/BitshareComFolder.py
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class BitshareComFolder(SimpleCrypter):
- __name__ = "BitshareComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?bitshare\.com/\?d=\w+"
- __version__ = "0.01"
- __description__ = """Bitshare.com Folder Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- LINK_PATTERN = r'<a href="(http://bitshare.com/files/.+)">.+</a></td>'
- TITLE_PATTERN = r'View public folder "(?P<title>.+)"</h1>'
diff --git a/module/plugins/crypter/C1neonCom.py b/module/plugins/crypter/C1neonCom.py
deleted file mode 100644
index c1e9013b3..000000000
--- a/module/plugins/crypter/C1neonCom.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class C1neonCom(DeadCrypter):
- __name__ = "C1neonCom"
- __type__ = "container"
- __pattern__ = r"http://(www\.)?c1neon.com/.*?"
- __version__ = "0.05"
- __description__ = """C1neon.Com Container Plugin"""
- __author_name__ = ("godofdream")
- __author_mail__ = ("soilfiction@gmail.com")
diff --git a/module/plugins/crypter/CrockoComFolder.py b/module/plugins/crypter/CrockoComFolder.py
deleted file mode 100644
index ffa8039a1..000000000
--- a/module/plugins/crypter/CrockoComFolder.py
+++ /dev/null
@@ -1,15 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class CrockoComFolder(SimpleCrypter):
- __name__ = "CrockoComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?crocko.com/f/.*"
- __version__ = "0.01"
- __description__ = """Crocko.com Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- LINK_PATTERN = r'<td class="last"><a href="([^"]+)">download</a>' \ No newline at end of file
diff --git a/module/plugins/crypter/CryptItCom.py b/module/plugins/crypter/CryptItCom.py
deleted file mode 100644
index 679e891b9..000000000
--- a/module/plugins/crypter/CryptItCom.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class CryptItCom(DeadCrypter):
- __name__ = "CryptItCom"
- __type__ = "container"
- __pattern__ = r"http://[\w\.]*?crypt-it\.com/(s|e|d|c)/[\w]+"
- __version__ = "0.11"
- __description__ = """Crypt.It.com Container Plugin"""
- __author_name__ = ("jeix")
- __author_mail__ = ("jeix@hasnomail.de")
diff --git a/module/plugins/crypter/CzshareComFolder.py b/module/plugins/crypter/CzshareComFolder.py
deleted file mode 100644
index 9ccda3ed2..000000000
--- a/module/plugins/crypter/CzshareComFolder.py
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-
-
-class CzshareComFolder(Crypter):
- __name__ = "CzshareComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(\w*\.)*czshare\.(com|cz)/folders/.*"
- __version__ = "0.1"
- __description__ = """Czshare.com Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- FOLDER_PATTERN = r'<tr class="subdirectory">\s*<td>\s*<table>(.*?)</table>'
- LINK_PATTERN = r'<td class="col2"><a href="([^"]+)">info</a></td>'
- #NEXT_PAGE_PATTERN = r'<a class="next " href="/([^"]+)">&nbsp;</a>'
-
- def decrypt(self, pyfile):
- html = self.load(self.pyfile.url)
-
- new_links = []
- found = re.search(self.FOLDER_PATTERN, html, re.DOTALL)
- if found is None: self.fail("Parse error (FOLDER)")
- new_links.extend(re.findall(self.LINK_PATTERN, found.group(1)))
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links') \ No newline at end of file
diff --git a/module/plugins/crypter/DDLMusicOrg.py b/module/plugins/crypter/DDLMusicOrg.py
deleted file mode 100644
index 822addca1..000000000
--- a/module/plugins/crypter/DDLMusicOrg.py
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-from time import sleep
-
-from module.plugins.Crypter import Crypter
-
-
-class DDLMusicOrg(Crypter):
- __name__ = "DDLMusicOrg"
- __type__ = "container"
- __pattern__ = r"http://[\w\.]*?ddl-music\.org/captcha/ddlm_cr\d\.php\?\d+\?\d+"
- __version__ = "0.3"
- __description__ = """ddl-music.org Container Plugin"""
- __author_name__ = ("mkaay")
- __author_mail__ = ("mkaay@mkaay.de")
-
- def setup(self):
- self.multiDL = False
-
- def decrypt(self, pyfile):
- html = self.req.load(self.pyfile.url, cookies=True)
-
- if re.search(r"Wer dies nicht rechnen kann", html) is not None:
- self.offline()
-
- math = re.search(r"(\d+) ([\+-]) (\d+) =\s+<inp", self.html)
- id = re.search(r"name=\"id\" value=\"(\d+)\"", self.html).group(1)
- linknr = re.search(r"name=\"linknr\" value=\"(\d+)\"", self.html).group(1)
-
- solve = ""
- if math.group(2) == "+":
- solve = int(math.group(1)) + int(math.group(3))
- else:
- solve = int(math.group(1)) - int(math.group(3))
- sleep(3)
- htmlwithlink = self.req.load(self.pyfile.url, cookies=True,
- post={"calc%s" % linknr: solve, "send%s" % linknr: "Send", "id": id,
- "linknr": linknr})
- m = re.search(r"<form id=\"ff\" action=\"(.*?)\" method=\"post\">", htmlwithlink)
- if m:
- self.packages.append((self.pyfile.package().name, [m.group(1)], self.pyfile.package().folder))
- else:
- self.retry()
diff --git a/module/plugins/crypter/DataHuFolder.py b/module/plugins/crypter/DataHuFolder.py
deleted file mode 100644
index f710f60d7..000000000
--- a/module/plugins/crypter/DataHuFolder.py
+++ /dev/null
@@ -1,55 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-import re
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class DataHuFolder(SimpleCrypter):
- __name__ = "DataHuFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?data.hu/dir/\w+"
- __version__ = "0.03"
- __description__ = """Data.hu Folder Plugin"""
- __author_name__ = ("crash", "stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- LINK_PATTERN = r"<a href='(http://data\.hu/get/.+)' target='_blank'>\1</a>"
- TITLE_PATTERN = ur'<title>(?P<title>.+) Let\xf6lt\xe9se</title>'
-
- def decrypt(self, pyfile):
- self.html = self.load(pyfile.url, decode=True)
-
- if u'K\xe9rlek add meg a jelsz\xf3t' in self.html: # Password protected
- password = self.getPassword()
- if password is '':
- self.fail("No password specified, please set right password on Add package form and retry")
- self.logDebug('The folder is password protected', 'Using password: ' + password)
- self.html = self.load(pyfile.url, post={'mappa_pass': password}, decode=True)
- if u'Hib\xe1s jelsz\xf3' in self.html: # Wrong password
- self.fail("Incorrect password, please set right password on Add package form and retry")
-
- package_name, folder_name = self.getPackageNameAndFolder()
-
- package_links = re.findall(self.LINK_PATTERN, self.html)
- self.logDebug('Package has %d links' % len(package_links))
-
- if package_links:
- self.packages = [(package_name, package_links, folder_name)]
- else:
- self.fail('Could not extract any links')
diff --git a/module/plugins/crypter/DdlstorageComFolder.py b/module/plugins/crypter/DdlstorageComFolder.py
deleted file mode 100644
index d76988c92..000000000
--- a/module/plugins/crypter/DdlstorageComFolder.py
+++ /dev/null
@@ -1,30 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class DdlstorageComFolder(SimpleCrypter):
- __name__ = "DdlstorageComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:\w*\.)*?ddlstorage.com/folder/\w{10}"
- __version__ = "0.02"
- __description__ = """DDLStorage.com Folder Plugin"""
- __author_name__ = ("godofdream", "stickell")
- __author_mail__ = ("soilfiction@gmail.com", "l.stickell@yahoo.it")
-
- LINK_PATTERN = '<a class="sub_title" style="text-decoration:none;" href="(http://www.ddlstorage.com/.*)">'
diff --git a/module/plugins/crypter/DepositfilesComFolder.py b/module/plugins/crypter/DepositfilesComFolder.py
deleted file mode 100644
index 15c317acf..000000000
--- a/module/plugins/crypter/DepositfilesComFolder.py
+++ /dev/null
@@ -1,15 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class DepositfilesComFolder(SimpleCrypter):
- __name__ = "DepositfilesComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?depositfiles.com/folders/\w+"
- __version__ = "0.01"
- __description__ = """Depositfiles.com Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- LINK_PATTERN = r'<div class="progressName"[^>]*>\s*<a href="([^"]+)" title="[^"]*" target="_blank">'
diff --git a/module/plugins/crypter/Dereferer.py b/module/plugins/crypter/Dereferer.py
deleted file mode 100644
index 7b7c34fee..000000000
--- a/module/plugins/crypter/Dereferer.py
+++ /dev/null
@@ -1,35 +0,0 @@
-# -*- coding: utf-8 -*-
-
-"""
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License,
- or (at your option) any later version.
-
- 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 GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, see <http://www.gnu.org/licenses/>.
-"""
-
-import re
-import urllib
-
-from module.plugins.Crypter import Crypter
-
-
-class Dereferer(Crypter):
- __name__ = "Dereferer"
- __type__ = "crypter"
- __pattern__ = r'https?://([^/]+)/.*?(?P<url>(ht|f)tps?(://|%3A%2F%2F).*)'
- __version__ = "0.1"
- __description__ = """Crypter for dereferers"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- def decrypt(self, pyfile):
- link = re.match(self.__pattern__, self.pyfile.url).group('url')
- self.core.files.addLinks([urllib.unquote(link).rstrip('+')], self.pyfile.package().id)
diff --git a/module/plugins/crypter/DontKnowMe.py b/module/plugins/crypter/DontKnowMe.py
deleted file mode 100644
index 0791e3c22..000000000
--- a/module/plugins/crypter/DontKnowMe.py
+++ /dev/null
@@ -1,22 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-import urllib
-
-from module.plugins.Crypter import Crypter
-
-
-class DontKnowMe(Crypter):
- __name__ = "DontKnowMe"
- __type__ = "crypter"
- __pattern__ = r"http://dontknow.me/at/\?.+$"
- __version__ = "0.1"
- __description__ = """DontKnowMe"""
- __author_name__ = ("selaux")
- __author_mail__ = ("")
-
- LINK_PATTERN = r"http://dontknow.me/at/\?(.+)$"
-
- def decrypt(self, pyfile):
- link = re.findall(self.LINK_PATTERN, self.pyfile.url)[0]
- self.core.files.addLinks([urllib.unquote(link)], self.pyfile.package().id)
diff --git a/module/plugins/crypter/DownloadVimeoCom.py b/module/plugins/crypter/DownloadVimeoCom.py
deleted file mode 100644
index 562672599..000000000
--- a/module/plugins/crypter/DownloadVimeoCom.py
+++ /dev/null
@@ -1,31 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-import HTMLParser
-from module.plugins.Crypter import Crypter
-
-
-class DownloadVimeoCom(Crypter):
- __name__ = 'DownloadVimeoCom'
- __type__ = 'crypter'
- __pattern__ = r'(?:http://vimeo\.com/\d*|http://smotri\.com/video/view/\?id=.*)'
- ## The download from dailymotion failed with a 403
- __version__ = '0.1'
- __description__ = """Video Download Plugin based on downloadvimeo.com"""
- __author_name__ = ('4Christopher')
- __author_mail__ = ('4Christopher@gmx.de')
- BASE_URL = 'http://downloadvimeo.com'
-
- def decrypt(self, pyfile):
- self.package = pyfile.package()
- html = self.load('%s/generate?url=%s' % (self.BASE_URL, pyfile.url))
- h = HTMLParser.HTMLParser()
- try:
- f = re.search(r'cmd quality="(?P<quality>[^"]+?)">\s*?(?P<URL>[^<]*?)</cmd>', html)
- except:
- self.logDebug('Failed to find the URL')
- else:
- url = h.unescape(f.group('URL'))
- self.logDebug('Quality: %s, URL: %s' % (f.group('quality'), url))
- self.packages.append((self.package.name, [url], self.package.folder))
diff --git a/module/plugins/crypter/DuckCryptInfo.py b/module/plugins/crypter/DuckCryptInfo.py
deleted file mode 100644
index 64302c800..000000000
--- a/module/plugins/crypter/DuckCryptInfo.py
+++ /dev/null
@@ -1,57 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.lib.BeautifulSoup import BeautifulSoup
-from module.plugins.Crypter import Crypter
-
-
-class DuckCryptInfo(Crypter):
- __name__ = "DuckCryptInfo"
- __type__ = "container"
- __pattern__ = r"http://(?:www\.)?duckcrypt.info/(folder|wait|link)/(\w+)/?(\w*)"
- __version__ = "0.02"
- __description__ = """DuckCrypt.Info Container Plugin"""
- __author_name__ = ("godofdream")
- __author_mail__ = ("soilfiction@gmail.com")
-
- TIMER_PATTERN = r'<span id="timer">(.*)</span>'
-
- def decrypt(self, pyfile):
- url = pyfile.url
- # seems we don't need to wait
- #src = self.req.load(str(url))
- #found = re.search(self.TIMER_PATTERN, src)
- #if found:
- # self.logDebug("Sleeping for" % found.group(1))
- # self.setWait(int(found.group(1)) ,False)
- found = re.search(self.__pattern__, url)
- if not found:
- self.fail('Weird error in link')
- if str(found.group(1)) == "link":
- self.handleLink(url)
- else:
- self.handleFolder(found)
-
-
- def handleFolder(self, found):
- src = self.load("http://duckcrypt.info/ajax/auth.php?hash=" + str(found.group(2)))
- found = re.search(self.__pattern__, src)
- self.logDebug("Redirectet to " + str(found.group(0)))
- src = self.load(str(found.group(0)))
- soup = BeautifulSoup(src)
- cryptlinks = soup.findAll("div", attrs={"class": "folderbox"})
- self.logDebug("Redirectet to " + str(cryptlinks))
- if not cryptlinks:
- self.fail('no links found - (Plugin out of date?)')
- for clink in cryptlinks:
- if clink.find("a"):
- self.handleLink(clink.find("a")['href'])
-
- def handleLink(self, url):
- src = self.load(url)
- soup = BeautifulSoup(src)
- link = soup.find("iframe")["src"]
- if not link:
- self.logDebug('no links found - (Plugin out of date?)')
- else:
- self.core.files.addLinks([link], self.pyfile.package().id)
diff --git a/module/plugins/crypter/DuploadOrgFolder.py b/module/plugins/crypter/DuploadOrgFolder.py
deleted file mode 100644
index a1918f055..000000000
--- a/module/plugins/crypter/DuploadOrgFolder.py
+++ /dev/null
@@ -1,30 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class DuploadOrgFolder(SimpleCrypter):
- __name__ = "DuploadOrgFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?dupload\.org/folder/\d+/"
- __version__ = "0.01"
- __description__ = """Dupload.org Folder Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- LINK_PATTERN = r'<td style="[^"]+"><a href="(http://[^"]+)" target="_blank">[^<]+</a></td>'
diff --git a/module/plugins/crypter/EasybytezComFolder.py b/module/plugins/crypter/EasybytezComFolder.py
deleted file mode 100644
index 56be72669..000000000
--- a/module/plugins/crypter/EasybytezComFolder.py
+++ /dev/null
@@ -1,35 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class EasybytezComFolder(SimpleCrypter):
- __name__ = "EasybytezComFolder"
- __type__ = "crypter"
- __pattern__ = r"https?://(www\.)?easybytez\.com/users/\w+/\w+"
- __version__ = "0.03"
- __description__ = """Easybytez Crypter Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- LINK_PATTERN = r'<div class="link"><a href="(http://www\.easybytez\.com/\w+)" target="_blank">.+</a></div>'
- TITLE_PATTERN = r'<Title>Files of \d+: (?P<title>.+) folder</Title>'
- PAGES_PATTERN = r"<a href='[^']+'>(?P<pages>\d+)</a><a href='[^']+'>Next &#187;</a><br><small>\(\d+ total\)</small></div>"
-
- def loadPage(self, page_n):
- return self.load(self.pyfile.url, get={'page': page_n}, decode=True)
diff --git a/module/plugins/crypter/EmbeduploadCom.py b/module/plugins/crypter/EmbeduploadCom.py
deleted file mode 100644
index 122c0f671..000000000
--- a/module/plugins/crypter/EmbeduploadCom.py
+++ /dev/null
@@ -1,53 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-from module.network.HTTPRequest import BadHeader
-
-
-class EmbeduploadCom(Crypter):
- __name__ = "EmbeduploadCom"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?embedupload.com/\?d=.*"
- __version__ = "0.02"
- __description__ = """EmbedUpload.com crypter"""
- __config__ = [("preferedHoster", "str", "Prefered hoster list (bar-separated) ", "embedupload"),
- ("ignoredHoster", "str", "Ignored hoster list (bar-separated) ", "")]
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- LINK_PATTERN = r'<div id="([^"]+)"[^>]*>\s*<a href="([^"]+)" target="_blank" (?:class="DownloadNow"|style="color:red")>'
-
- def decrypt(self, pyfile):
- self.html = self.load(self.pyfile.url, decode=True)
- tmp_links = []
- new_links = []
-
- found = re.findall(self.LINK_PATTERN, self.html)
- if found:
- prefered_set = set(self.getConfig("preferedHoster").split('|'))
- prefered_set = map(lambda s: s.lower().split('.')[0], prefered_set)
- print "PF", prefered_set
- tmp_links.extend([x[1] for x in found if x[0] in prefered_set])
- self.getLocation(tmp_links, new_links)
-
- if not new_links:
- ignored_set = set(self.getConfig("ignoredHoster").split('|'))
- ignored_set = map(lambda s: s.lower().split('.')[0], ignored_set)
- print "IG", ignored_set
- tmp_links.extend([x[1] for x in found if x[0] not in ignored_set])
- self.getLocation(tmp_links, new_links)
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
-
- def getLocation(self, tmp_links, new_links):
- for link in tmp_links:
- try:
- header = self.load(link, just_header=True)
- if "location" in header:
- new_links.append(header['location'])
- except BadHeader:
- pass
diff --git a/module/plugins/crypter/FilebeerInfoFolder.py b/module/plugins/crypter/FilebeerInfoFolder.py
deleted file mode 100644
index b6bf4fd07..000000000
--- a/module/plugins/crypter/FilebeerInfoFolder.py
+++ /dev/null
@@ -1,14 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class FilebeerInfoFolder(DeadCrypter):
- __name__ = "FilebeerInfoFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?filebeer\.info/(\d+~f).*"
- __version__ = "0.02"
- __description__ = """Filebeer.info Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
diff --git a/module/plugins/crypter/FilefactoryComFolder.py b/module/plugins/crypter/FilefactoryComFolder.py
deleted file mode 100644
index 64b8ac37e..000000000
--- a/module/plugins/crypter/FilefactoryComFolder.py
+++ /dev/null
@@ -1,45 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-
-
-class FilefactoryComFolder(Crypter):
- __name__ = "FilefactoryComFolder"
- __type__ = "crypter"
- __pattern__ = r"(http://(www\.)?filefactory\.com/f/\w+).*"
- __version__ = "0.1"
- __description__ = """Filefactory.com Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- FOLDER_PATTERN = r'<table class="items" cellspacing="0" cellpadding="0">(.*?)</table>'
- LINK_PATTERN = r'<td class="name"><a href="([^"]+)">'
- PAGINATOR_PATTERN = r'<div class="list">\s*<label>Pages</label>\s*<ul>(.*?)</ul>\s*</div>'
- NEXT_PAGE_PATTERN = r'<li class="current">.*?</li>\s*<li class=""><a href="([^"]+)">'
-
- def decrypt(self, pyfile):
- url_base = re.search(self.__pattern__, self.pyfile.url).group(1)
- html = self.load(url_base)
-
- new_links = []
- for i in range(1, 100):
- self.logInfo("Fetching links from page %i" % i)
- found = re.search(self.FOLDER_PATTERN, html, re.DOTALL)
- if found is None: self.fail("Parse error (FOLDER)")
-
- new_links.extend(re.findall(self.LINK_PATTERN, found.group(1)))
-
- try:
- paginator = re.search(self.PAGINATOR_PATTERN, html, re.DOTALL).group(1)
- next_page = re.search(self.NEXT_PAGE_PATTERN, paginator).group(1)
- html = self.load("%s/%s" % (url_base, next_page))
- except Exception, e:
- break
- else:
- self.logInfo("Limit of 99 pages reached, aborting")
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
diff --git a/module/plugins/crypter/FileserveComFolder.py b/module/plugins/crypter/FileserveComFolder.py
deleted file mode 100644
index 42481c15e..000000000
--- a/module/plugins/crypter/FileserveComFolder.py
+++ /dev/null
@@ -1,33 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.Crypter import Crypter
-
-
-class FileserveComFolder(Crypter):
- __name__ = "FileserveComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?fileserve.com/list/\w+"
- __version__ = "0.11"
- __description__ = """FileServeCom.com Folder Plugin"""
- __author_name__ = ("fionnc")
- __author_mail__ = ("fionnc@gmail.com")
-
- FOLDER_PATTERN = r'<table class="file_list">(.*?)</table>'
- LINK_PATTERN = r'<a href="([^"]+)" class="sheet_icon wbold">'
-
- def decrypt(self, pyfile):
- html = self.load(self.pyfile.url)
-
- new_links = []
-
- folder = re.search(self.FOLDER_PATTERN, html, re.DOTALL)
- if folder is None: self.fail("Parse error (FOLDER)")
-
- new_links.extend(re.findall(self.LINK_PATTERN, folder.group(1)))
-
- if new_links:
- self.core.files.addLinks(map(lambda s: "http://fileserve.com%s" % s, new_links), self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
diff --git a/module/plugins/crypter/FilestubeCom.py b/module/plugins/crypter/FilestubeCom.py
deleted file mode 100644
index 1e5712cb5..000000000
--- a/module/plugins/crypter/FilestubeCom.py
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class FilestubeCom(SimpleCrypter):
- __name__ = "FilestubeCom"
- __type__ = "crypter"
- __pattern__ = r"http://(?:w{3}.)?filestube\.com/\w+"
- __version__ = "0.01"
- __description__ = """Filestube.com Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- LINK_PATTERN = r"link_download'\]\); renderGo\('(http://[^)]+)'\);"
- TITLE_PATTERN = r"<title>(?P<title>.+) download"
diff --git a/module/plugins/crypter/FiletramCom.py b/module/plugins/crypter/FiletramCom.py
deleted file mode 100644
index 886b8be30..000000000
--- a/module/plugins/crypter/FiletramCom.py
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class FiletramCom(SimpleCrypter):
- __name__ = "FiletramCom"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?filetram.com/[^/]+/.+"
- __version__ = "0.01"
- __description__ = """Filetram.com Plugin"""
- __author_name__ = ("igel", "stickell")
- __author_mail__ = ("igelkun@myopera.com", "l.stickell@yahoo.it")
-
- LINK_PATTERN = r"\s+(http://.+)"
- TITLE_PATTERN = r"<title>(?P<title>[^<]+) - Free Download[^<]*</title>"
diff --git a/module/plugins/crypter/FourChanOrg.py b/module/plugins/crypter/FourChanOrg.py
deleted file mode 100644
index 700a09b97..000000000
--- a/module/plugins/crypter/FourChanOrg.py
+++ /dev/null
@@ -1,26 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.Crypter import Crypter
-
-
-class FourChanOrg(Crypter):
- # Based on 4chandl by Roland Beermann
- # https://gist.github.com/enkore/3492599
- __name__ = "FourChanOrg"
- __type__ = "container"
- __version__ = "0.3"
- __pattern__ = r"http://boards\.4chan.org/\w+/res/(\d+)"
- __description__ = "Downloader for entire 4chan threads"
-
- def decrypt(self, pyfile):
- pagehtml = self.load(pyfile.url)
-
- images = set(re.findall(r'(images\.4chan\.org/[^/]*/src/[^"<]*)', pagehtml))
- urls = []
- for image in images:
- urls.append("http://" + image)
-
- self.core.files.addLinks(urls, self.pyfile.package().id)
diff --git a/module/plugins/crypter/FreakhareComFolder.py b/module/plugins/crypter/FreakhareComFolder.py
deleted file mode 100644
index 519a468f3..000000000
--- a/module/plugins/crypter/FreakhareComFolder.py
+++ /dev/null
@@ -1,47 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-import re
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class FreakhareComFolder(SimpleCrypter):
- __name__ = "FreakhareComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?freakshare\.com/folder/.+"
- __version__ = "0.01"
- __description__ = """Freakhare.com Folder Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- LINK_PATTERN = r'<a href="(http://freakshare.com/files/[^"]+)" target="_blank">'
- TITLE_PATTERN = r'Folder:</b> (?P<title>.+)'
- PAGES_PATTERN = r'Pages: +(?P<pages>\d+)'
-
- def loadPage(self, page_n):
- if not hasattr(self, 'f_id') and not hasattr(self, 'f_md5'):
- m = re.search(r'http://freakshare.com/\?x=folder&f_id=(\d+)&f_md5=(\w+)', self.html)
- if m:
- self.f_id = m.group(1)
- self.f_md5 = m.group(2)
- return self.load('http://freakshare.com/', get={'x': 'folder',
- 'f_id': self.f_id,
- 'f_md5': self.f_md5,
- 'entrys': '20',
- 'page': page_n - 1,
- 'order': ''}, decode=True)
diff --git a/module/plugins/crypter/FreetexthostCom.py b/module/plugins/crypter/FreetexthostCom.py
deleted file mode 100644
index 8d165abe4..000000000
--- a/module/plugins/crypter/FreetexthostCom.py
+++ /dev/null
@@ -1,37 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-import re
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class FreetexthostCom(SimpleCrypter):
- __name__ = "FreetexthostCom"
- __type__ = "crypter"
- __pattern__ = r"http://(?:w{3}.)?freetexthost\.com/\w+"
- __version__ = "0.01"
- __description__ = """Freetexthost.com Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- def getLinks(self):
- m = re.search(r'<div id="contentsinner">\s*(.+)<div class="viewcount">', self.html, re.DOTALL)
- if not m:
- self.fail('Unable to extract links | Plugin may be out-of-date')
- links = m.group(1)
- return links.strip().split("<br />\r\n")
diff --git a/module/plugins/crypter/FshareVnFolder.py b/module/plugins/crypter/FshareVnFolder.py
deleted file mode 100644
index 2d7a3c490..000000000
--- a/module/plugins/crypter/FshareVnFolder.py
+++ /dev/null
@@ -1,15 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class FshareVnFolder(SimpleCrypter):
- __name__ = "FshareVnFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?fshare.vn/folder/.*"
- __version__ = "0.01"
- __description__ = """Fshare.vn Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- LINK_PATTERN = r'<li class="w_80pc"><a href="([^"]+)" target="_blank">'
diff --git a/module/plugins/crypter/GooGl.py b/module/plugins/crypter/GooGl.py
deleted file mode 100644
index bcb1d7494..000000000
--- a/module/plugins/crypter/GooGl.py
+++ /dev/null
@@ -1,41 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.Crypter import Crypter
-from module.common.json_layer import json_loads
-
-
-class GooGl(Crypter):
- __name__ = "GooGl"
- __type__ = "crypter"
- __pattern__ = r"https?://(www\.)?goo\.gl/\w+"
- __version__ = "0.01"
- __description__ = """Goo.gl Crypter Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- API_URL = 'https://www.googleapis.com/urlshortener/v1/url'
-
- def decrypt(self, pyfile):
- rep = self.load(self.API_URL, get={'shortUrl': pyfile.url})
- self.logDebug('JSON data: ' + rep)
- rep = json_loads(rep)
-
- if 'longUrl' in rep:
- self.core.files.addLinks([rep['longUrl']], self.pyfile.package().id)
- else:
- self.fail('Unable to expand shortened link')
diff --git a/module/plugins/crypter/HoerbuchIn.py b/module/plugins/crypter/HoerbuchIn.py
deleted file mode 100644
index f8cb18b19..000000000
--- a/module/plugins/crypter/HoerbuchIn.py
+++ /dev/null
@@ -1,56 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.Crypter import Crypter
-from module.lib.BeautifulSoup import BeautifulSoup, BeautifulStoneSoup
-
-
-class HoerbuchIn(Crypter):
- __name__ = "HoerbuchIn"
- __type__ = "container"
- __pattern__ = r"http://(www\.)?hoerbuch\.in/(wp/horbucher/\d+/.+/|tp/out.php\?.+|protection/folder_\d+\.html)"
- __version__ = "0.6"
- __description__ = """Hoerbuch.in Container Plugin"""
- __author_name__ = ("spoob", "mkaay")
- __author_mail__ = ("spoob@pyload.org", "mkaay@mkaay.de")
-
- article = re.compile("http://(www\.)?hoerbuch\.in/wp/horbucher/\d+/.+/")
- protection = re.compile("http://(www\.)?hoerbuch\.in/protection/folder_\d+.html")
-
- def decrypt(self, pyfile):
- self.pyfile = pyfile
-
- if self.article.match(self.pyfile.url):
- src = self.load(self.pyfile.url)
- soup = BeautifulSoup(src, convertEntities=BeautifulStoneSoup.HTML_ENTITIES)
-
- abookname = soup.find("a", attrs={"rel": "bookmark"}).text
- for a in soup.findAll("a", attrs={"href": self.protection}):
- package = "%s (%s)" % (abookname, a.previousSibling.previousSibling.text[:-1])
- links = self.decryptFolder(a["href"])
-
- self.packages.append((package, links, self.pyfile.package().folder))
- else:
- links = self.decryptFolder(self.pyfile.url)
-
- self.packages.append((self.pyfile.package().name, links, self.pyfile.package().folder))
-
- def decryptFolder(self, url):
- m = self.protection.search(url)
- if not m:
- self.fail("Bad URL")
- url = m.group(0)
-
- self.pyfile.url = url
- src = self.req.load(url, post={"viewed": "adpg"})
-
- links = []
- pattern = re.compile("http://www\.hoerbuch\.in/protection/(\w+)/(.*?)\"")
- for hoster, lid in pattern.findall(src):
- self.req.lastURL = url
- self.load("http://www.hoerbuch.in/protection/%s/%s" % (hoster, lid))
- links.append(self.req.lastEffectiveURL)
-
- return links
diff --git a/module/plugins/crypter/HotfileFolderCom.py b/module/plugins/crypter/HotfileFolderCom.py
deleted file mode 100644
index 79691ad01..000000000
--- a/module/plugins/crypter/HotfileFolderCom.py
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.Crypter import Crypter
-
-
-class HotfileFolderCom(Crypter):
- __name__ = "HotfileFolderCom"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?hotfile.com/list/\w+/\w+"
- __version__ = "0.1"
- __description__ = """HotfileFolder Download Plugin"""
- __author_name__ = ("RaNaN")
- __author_mail__ = ("RaNaN@pyload.org")
-
- def decrypt(self, pyfile):
- html = self.load(pyfile.url)
-
- name = re.findall(
- r'<img src="/i/folder.gif" width="23" height="14" style="margin-bottom: -2px;" />([^<]+)', html,
- re.MULTILINE)[0].replace("/", "")
- new_links = re.findall(r'href="(http://(www.)?hotfile\.com/dl/\d+/[0-9a-zA-Z]+[^"]+)', html)
-
- new_links = [x[0] for x in new_links]
-
- self.packages.append((name, new_links, name))
diff --git a/module/plugins/crypter/ILoadTo.py b/module/plugins/crypter/ILoadTo.py
deleted file mode 100644
index d155f4bb6..000000000
--- a/module/plugins/crypter/ILoadTo.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class ILoadTo(DeadCrypter):
- __name__ = "ILoadTo"
- __type__ = "crypter"
- __pattern__ = r"http://iload\.to/go/\d+-[\w\.-]+/"
- __version__ = "0.11"
- __description__ = """iload.to Crypter Plugin"""
- __author_name__ = ("hzpz")
- __author_mail__ = ("")
diff --git a/module/plugins/crypter/LetitbitNetFolder.py b/module/plugins/crypter/LetitbitNetFolder.py
deleted file mode 100644
index 68aad9dd7..000000000
--- a/module/plugins/crypter/LetitbitNetFolder.py
+++ /dev/null
@@ -1,33 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-
-
-class LetitbitNetFolder(Crypter):
- __name__ = "LetitbitNetFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?letitbit.net/folder/\w+"
- __version__ = "0.1"
- __description__ = """Letitbit.net Folder Plugin"""
- __author_name__ = ("DHMH", "z00nx")
- __author_mail__ = ("webmaster@pcProfil.de", "z00nx0@gmail.com")
-
- FOLDER_PATTERN = r'<table>(.*)</table>'
- LINK_PATTERN = r'<a href="([^"]+)" target="_blank">'
-
- def decrypt(self, pyfile):
- html = self.load(self.pyfile.url)
-
- new_links = []
-
- folder = re.search(self.FOLDER_PATTERN, html, re.DOTALL)
- if folder is None:
- self.fail("Parse error (FOLDER)")
-
- new_links.extend(re.findall(self.LINK_PATTERN, folder.group(0)))
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
diff --git a/module/plugins/crypter/LinkSaveIn.py b/module/plugins/crypter/LinkSaveIn.py
deleted file mode 100644
index 129da6608..000000000
--- a/module/plugins/crypter/LinkSaveIn.py
+++ /dev/null
@@ -1,228 +0,0 @@
-# -*- coding: utf-8 -*-
-
-#
-# v2.01 - hagg
-# * cnl2 and web links are skipped if JS is not available (instead of failing the package)
-# * only best available link source is used (priority: cnl2>rsdf>ccf>dlc>web
-#
-
-import base64
-import binascii
-import re
-
-from Crypto.Cipher import AES
-from module.plugins.Crypter import Crypter
-from module.unescape import unescape
-
-
-class LinkSaveIn(Crypter):
- __name__ = "LinkSaveIn"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?linksave.in/(?P<id>\w+)$"
- __version__ = "2.01"
- __description__ = """LinkSave.in Crypter Plugin"""
- __author_name__ = ("fragonib")
- __author_mail__ = ("fragonib[AT]yahoo[DOT]es")
-
- # Constants
- _JK_KEY_ = "jk"
- _CRYPTED_KEY_ = "crypted"
- HOSTER_DOMAIN = "linksave.in"
-
- def setup(self):
- self.html = None
- self.fileid = None
- self.captcha = False
- self.package = None
- self.preferred_sources = ['cnl2', 'rsdf', 'ccf', 'dlc', 'web']
-
- def decrypt(self, pyfile):
-
- # Init
- self.package = pyfile.package()
- self.fileid = re.match(self.__pattern__, pyfile.url).group('id')
- self.req.cj.setCookie(self.HOSTER_DOMAIN, "Linksave_Language", "english")
-
- # Request package
- self.html = self.load(self.pyfile.url)
- if not self.isOnline():
- self.offline()
-
- # Check for protection
- if self.isPasswordProtected():
- self.unlockPasswordProtection()
- self.handleErrors()
-
- if self.isCaptchaProtected():
- self.captcha = True
- self.unlockCaptchaProtection()
- self.handleErrors()
-
- # Get package name and folder
- (package_name, folder_name) = self.getPackageInfo()
-
- # Extract package links
- package_links = []
- for type_ in self.preferred_sources:
- package_links.extend(self.handleLinkSource(type_))
- if package_links: # use only first source which provides links
- break
- package_links = set(package_links)
-
- # Pack
- if package_links:
- self.packages = [(package_name, package_links, folder_name)]
- else:
- self.fail('Could not extract any links')
-
- def isOnline(self):
- if "<big>Error 404 - Folder not found!</big>" in self.html:
- self.logDebug("File not found")
- return False
- return True
-
- def isPasswordProtected(self):
- if re.search(r'''<input.*?type="password"''', self.html):
- self.logDebug("Links are password protected")
- return True
-
- def isCaptchaProtected(self):
- if "<b>Captcha:</b>" in self.html:
- self.logDebug("Links are captcha protected")
- return True
- return False
-
- def unlockPasswordProtection(self):
- password = self.getPassword()
- self.logDebug("Submitting password [%s] for protected links" % password)
- post = {"id": self.fileid, "besucherpasswort": password, 'login': 'submit'}
- self.html = self.load(self.pyfile.url, post=post)
-
- def unlockCaptchaProtection(self):
- captcha_hash = re.search(r'name="hash" value="([^"]+)', self.html).group(1)
- captcha_url = re.search(r'src=".(/captcha/cap.php\?hsh=[^"]+)', self.html).group(1)
- captcha_code = self.decryptCaptcha("http://linksave.in" + captcha_url, forceUser=True)
- self.html = self.load(self.pyfile.url, post={"id": self.fileid, "hash": captcha_hash, "code": captcha_code})
-
- def getPackageInfo(self):
- name = self.pyfile.package().name
- folder = self.pyfile.package().folder
- self.logDebug("Defaulting to pyfile name [%s] and folder [%s] for package" % (name, folder))
- return name, folder
-
- def handleErrors(self):
- if "The visitorpassword you have entered is wrong" in self.html:
- self.logDebug("Incorrect password, please set right password on 'Edit package' form and retry")
- self.fail("Incorrect password, please set right password on 'Edit package' form and retry")
-
- if self.captcha:
- if "Wrong code. Please retry" in self.html:
- self.logDebug("Invalid captcha, retrying")
- self.invalidCaptcha()
- self.retry()
- else:
- self.correctCaptcha()
-
- def handleLinkSource(self, type_):
- if type_ == 'cnl2':
- return self.handleCNL2()
- elif type_ in ('rsdf', 'ccf', 'dlc'):
- return self.handleContainer(type_)
- elif type_ == 'web':
- return self.handleWebLinks()
- else:
- self.fail('unknown source type "%s" (this is probably a bug)' % type_)
-
- def handleWebLinks(self):
- package_links = []
- self.logDebug("Search for Web links")
- if not self.js:
- self.logDebug("no JS -> skip Web links")
- else:
- #@TODO: Gather paginated web links
- pattern = r'<a href="http://linksave\.in/(\w{43})"'
- ids = re.findall(pattern, self.html)
- self.logDebug("Decrypting %d Web links" % len(ids))
- for i, weblink_id in enumerate(ids):
- try:
- webLink = "http://linksave.in/%s" % weblink_id
- self.logDebug("Decrypting Web link %d, %s" % (i + 1, webLink))
- fwLink = "http://linksave.in/fw-%s" % weblink_id
- response = self.load(fwLink)
- jscode = re.findall(r'<script type="text/javascript">(.*)</script>', response)[-1]
- jseval = self.js.eval("document = { write: function(e) { return e; } }; %s" % jscode)
- dlLink = re.search(r'http://linksave\.in/dl-\w+', jseval).group(0)
- self.logDebug("JsEngine returns value [%s] for redirection link" % dlLink)
- response = self.load(dlLink)
- link = unescape(re.search(r'<iframe src="(.+?)"', response).group(1))
- package_links.append(link)
- except Exception, detail:
- self.logDebug("Error decrypting Web link %s, %s" % (webLink, detail))
- return package_links
-
- def handleContainer(self, type_):
- package_links = []
- type_ = type_.lower()
- self.logDebug('Seach for %s Container links' % type_.upper())
- if not type_.isalnum(): # check to prevent broken re-pattern (cnl2,rsdf,ccf,dlc,web are all alpha-numeric)
- self.fail('unknown container type "%s" (this is probably a bug)' % type_)
- pattern = r"\('%s_link'\).href=unescape\('(.*?\.%s)'\)" % (type_, type_)
- containersLinks = re.findall(pattern, self.html)
- self.logDebug("Found %d %s Container links" % (len(containersLinks), type_.upper()))
- for containerLink in containersLinks:
- link = "http://linksave.in/%s" % unescape(containerLink)
- package_links.append(link)
- return package_links
-
- def handleCNL2(self):
- package_links = []
- self.logDebug("Search for CNL2 links")
- if not self.js:
- self.logDebug("no JS -> skip CNL2 links")
- elif 'cnl2_load' in self.html:
- try:
- (vcrypted, vjk) = self._getCipherParams()
- for (crypted, jk) in zip(vcrypted, vjk):
- package_links.extend(self._getLinks(crypted, jk))
- except:
- self.fail("Unable to decrypt CNL2 links")
- return package_links
-
- def _getCipherParams(self):
-
- # Get jk
- jk_re = r'<INPUT.*?NAME="%s".*?VALUE="(.*?)"' % LinkSaveIn._JK_KEY_
- vjk = re.findall(jk_re, self.html)
-
- # Get crypted
- crypted_re = r'<INPUT.*?NAME="%s".*?VALUE="(.*?)"' % LinkSaveIn._CRYPTED_KEY_
- vcrypted = re.findall(crypted_re, self.html)
-
- # Log and return
- self.logDebug("Detected %d crypted blocks" % len(vcrypted))
- return vcrypted, vjk
-
- def _getLinks(self, crypted, jk):
-
- # Get key
- jreturn = self.js.eval("%s f()" % jk)
- self.logDebug("JsEngine returns value [%s]" % jreturn)
- key = binascii.unhexlify(jreturn)
-
- # Decode crypted
- crypted = base64.standard_b64decode(crypted)
-
- # Decrypt
- Key = key
- IV = key
- obj = AES.new(Key, AES.MODE_CBC, IV)
- text = obj.decrypt(crypted)
-
- # Extract links
- text = text.replace("\x00", "").replace("\r", "")
- links = text.split("\n")
- links = filter(lambda x: x != "", links)
-
- # Log and return
- self.logDebug("Package has %d links" % len(links))
- return links
diff --git a/module/plugins/crypter/LinkdecrypterCom.py b/module/plugins/crypter/LinkdecrypterCom.py
deleted file mode 100644
index 6a11c98b0..000000000
--- a/module/plugins/crypter/LinkdecrypterCom.py
+++ /dev/null
@@ -1,104 +0,0 @@
-# -*- coding: utf-8 -*-
-"""
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License,
- or (at your option) any later version.
-
- 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 GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, see <http://www.gnu.org/licenses/>.
-
- @author: zoidberg
-"""
-
-import re
-from module.plugins.Crypter import Crypter
-
-
-class LinkdecrypterCom(Crypter):
- __name__ = "LinkdecrypterCom"
- __type__ = "crypter"
- __version__ = "0.27"
- __description__ = """linkdecrypter.com"""
- __author_name__ = ("zoidberg", "flowlee")
-
- TEXTAREA_PATTERN = r'<textarea name="links" wrap="off" readonly="1" class="caja_des">(.+)</textarea>'
- PASSWORD_PATTERN = r'<input type="text" name="password"'
- CAPTCHA_PATTERN = r'<img class="captcha" src="(.+?)"(.*?)>'
- REDIR_PATTERN = r'<i>(Click <a href="./">here</a> if your browser does not redirect you).</i>'
-
- def decrypt(self, pyfile):
-
- self.passwords = self.getPassword().splitlines()
-
- # API not working anymore
- new_links = self.decryptHTML()
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
-
- def decryptAPI(self):
-
- get_dict = {"t": "link", "url": self.pyfile.url, "lcache": "1"}
- self.html = self.load('http://linkdecrypter.com/api', get=get_dict)
- if self.html.startswith('http://'):
- return self.html.splitlines()
-
- if self.html == 'INTERRUPTION(PASSWORD)':
- for get_dict['pass'] in self.passwords:
- self.html = self.load('http://linkdecrypter.com/api', get=get_dict)
- if self.html.startswith('http://'):
- return self.html.splitlines()
-
- self.logError('API', self.html)
- if self.html == 'INTERRUPTION(PASSWORD)':
- self.fail("No or incorrect password")
-
- return None
-
- def decryptHTML(self):
-
- retries = 5
-
- post_dict = {"link_cache": "on", "pro_links": self.pyfile.url, "modo_links": "text"}
- self.html = self.load('http://linkdecrypter.com/', post=post_dict, cookies=True, decode=True)
-
- while self.passwords or retries:
- found = re.search(self.TEXTAREA_PATTERN, self.html, flags=re.DOTALL)
- if found:
- return [x for x in found.group(1).splitlines() if '[LINK-ERROR]' not in x]
-
- found = re.search(self.CAPTCHA_PATTERN, self.html)
- if found:
- captcha_url = 'http://linkdecrypter.com/' + found.group(1)
- result_type = "positional" if "getPos" in found.group(2) else "textual"
-
- found = re.search(r"<p><i><b>([^<]+)</b></i></p>", self.html)
- msg = found.group(1) if found else ""
- self.logInfo("Captcha protected link", result_type, msg)
-
- captcha = self.decryptCaptcha(captcha_url, result_type=result_type)
- if result_type == "positional":
- captcha = "%d|%d" % captcha
- self.html = self.load('http://linkdecrypter.com/', post={"captcha": captcha}, decode=True)
- retries -= 1
-
- elif self.PASSWORD_PATTERN in self.html:
- if self.passwords:
- password = self.passwords.pop(0)
- self.logInfo("Password protected link, trying " + password)
- self.html = self.load('http://linkdecrypter.com/', post={'password': password}, decode=True)
- else:
- self.fail("No or incorrect password")
-
- else:
- retries -= 1
- self.html = self.load('http://linkdecrypter.com/', cookies=True, decode=True)
-
- return None
diff --git a/module/plugins/crypter/LixIn.py b/module/plugins/crypter/LixIn.py
deleted file mode 100644
index 52abe1b3c..000000000
--- a/module/plugins/crypter/LixIn.py
+++ /dev/null
@@ -1,59 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.Crypter import Crypter
-
-
-class LixIn(Crypter):
- __name__ = "LixIn"
- __type__ = "container"
- __pattern__ = r"http://(www.)?lix.in/(?P<id>.*)"
- __version__ = "0.22"
- __description__ = """Lix.in Container Plugin"""
- __author_name__ = ("spoob")
- __author_mail__ = ("spoob@pyload.org")
-
- CAPTCHA_PATTERN = '<img src="(?P<image>captcha_img.php\?.*?)"'
- SUBMIT_PATTERN = r"value='continue.*?'"
- LINK_PATTERN = r'name="ifram" src="(?P<link>.*?)"'
-
- def decrypt(self, pyfile):
- url = pyfile.url
-
- matches = re.search(self.__pattern__, url)
- if not matches:
- self.fail("couldn't identify file id")
-
- id = matches.group("id")
- self.logDebug("File id is %s" % id)
-
- self.html = self.req.load(url, decode=True)
-
- matches = re.search(self.SUBMIT_PATTERN, self.html)
- if not matches:
- self.fail("link doesn't seem valid")
-
- matches = re.search(self.CAPTCHA_PATTERN, self.html)
- if matches:
- for i in range(5):
- matches = re.search(self.CAPTCHA_PATTERN, self.html)
- if matches:
- self.logDebug("trying captcha")
- captcharesult = self.decryptCaptcha("http://lix.in/" + matches.group("image"))
- self.html = self.req.load(url, decode=True,
- post={"capt": captcharesult, "submit": "submit", "tiny": id})
- else:
- self.logDebug("no captcha/captcha solved")
- else:
- self.html = self.req.load(url, decode=True, post={"submit": "submit", "tiny": id})
-
- matches = re.search(self.LINK_PATTERN, self.html)
- if not matches:
- self.fail("can't find destination url")
-
- new_link = matches.group("link")
- self.logDebug("Found link %s, adding to package" % new_link)
-
- self.packages.append((self.pyfile.package().name, [new_link], self.pyfile.package().name))
diff --git a/module/plugins/crypter/LofCc.py b/module/plugins/crypter/LofCc.py
deleted file mode 100644
index 458609881..000000000
--- a/module/plugins/crypter/LofCc.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class LofCc(DeadCrypter):
- __name__ = "LofCc"
- __type__ = "container"
- __pattern__ = r"http://lof.cc/(.*)"
- __version__ = "0.21"
- __description__ = """lof.cc Plugin"""
- __author_name__ = ("mkaay")
- __author_mail__ = ("mkaay@mkaay.de")
diff --git a/module/plugins/crypter/MBLinkInfo.py b/module/plugins/crypter/MBLinkInfo.py
deleted file mode 100644
index 434819d07..000000000
--- a/module/plugins/crypter/MBLinkInfo.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class MBLinkInfo(DeadCrypter):
- __name__ = "MBLinkInfo"
- __type__ = "container"
- __pattern__ = r"http://(?:www\.)?mblink\.info/?\?id=(\d+)"
- __version__ = "0.03"
- __description__ = """MBLink.Info Container Plugin"""
- __author_name__ = ("Gummibaer", "stickell")
- __author_mail__ = ("Gummibaer@wiki-bierkiste.de", "l.stickell@yahoo.it")
diff --git a/module/plugins/crypter/MediafireComFolder.py b/module/plugins/crypter/MediafireComFolder.py
deleted file mode 100644
index 3709d3349..000000000
--- a/module/plugins/crypter/MediafireComFolder.py
+++ /dev/null
@@ -1,57 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-from module.plugins.hoster.MediafireCom import checkHTMLHeader
-from module.common.json_layer import json_loads
-
-
-class MediafireComFolder(Crypter):
- __name__ = "MediafireComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(\w*\.)*mediafire\.com/(folder/|\?sharekey=|\?\w{13}($|[/#]))"
- __version__ = "0.14"
- __description__ = """Mediafire.com Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- FOLDER_KEY_PATTERN = r"var afI= '(\w+)';"
- FILE_URL_PATTERN = '<meta property="og:url" content="http://www.mediafire.com/\?(\w+)"/>'
-
- def decrypt(self, pyfile):
- new_links = []
-
- url, result = checkHTMLHeader(pyfile.url)
- self.logDebug('Location (%d): %s' % (result, url))
-
- if result == 0:
- # load and parse html
- html = self.load(pyfile.url)
- found = re.search(self.FILE_URL_PATTERN, html)
- if found:
- # file page
- new_links.append("http://www.mediafire.com/file/%s" % found.group(1))
- else:
- # folder page
- found = re.search(self.FOLDER_KEY_PATTERN, html)
- if found:
- folder_key = found.group(1)
- self.logDebug("FOLDER KEY: %s" % folder_key)
-
- json_resp = json_loads(self.load(
- "http://www.mediafire.com/api/folder/get_info.php?folder_key=%s&response_format=json&version=1" % folder_key))
- #self.logInfo(json_resp)
- if json_resp['response']['result'] == "Success":
- for link in json_resp['response']['folder_info']['files']:
- new_links.append("http://www.mediafire.com/file/%s" % link['quickkey'])
- else:
- self.fail(json_resp['response']['message'])
- elif result == 1:
- self.offline()
- else:
- new_links.append(url)
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
diff --git a/module/plugins/crypter/Movie2kTo.py b/module/plugins/crypter/Movie2kTo.py
deleted file mode 100644
index c9c3f8f2d..000000000
--- a/module/plugins/crypter/Movie2kTo.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class Movie2kTo(DeadCrypter):
- __name__ = "Movie2kTo"
- __type__ = "container"
- __pattern__ = r"http://(?:www\.)?movie2k\.to/(.*)\.html"
- __version__ = "0.51"
- __description__ = """Movie2k.to Container Plugin"""
- __author_name__ = ("4Christopher")
- __author_mail__ = ("4Christopher@gmx.de")
diff --git a/module/plugins/crypter/MultiloadCz.py b/module/plugins/crypter/MultiloadCz.py
deleted file mode 100644
index 055d72375..000000000
--- a/module/plugins/crypter/MultiloadCz.py
+++ /dev/null
@@ -1,42 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-
-
-class MultiloadCz(Crypter):
- __name__ = "MultiloadCz"
- __type__ = "crypter"
- __pattern__ = r"http://.*multiload.cz/(stahnout|slozka)/.*"
- __version__ = "0.4"
- __description__ = """multiload.cz"""
- __config__ = [("usedHoster", "str", "Prefered hoster list (bar-separated) ", ""),
- ("ignoredHoster", "str", "Ignored hoster list (bar-separated) ", "")]
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- FOLDER_PATTERN = r'<form action="" method="get"><textarea[^>]*>([^>]*)</textarea></form>'
- LINK_PATTERN = r'<p class="manager-server"><strong>([^<]+)</strong></p><p class="manager-linky"><a href="([^"]+)">'
-
- def decrypt(self, pyfile):
- self.html = self.load(self.pyfile.url, decode=True)
- new_links = []
-
- if re.search(self.__pattern__, self.pyfile.url).group(1) == "slozka":
- found = re.search(self.FOLDER_PATTERN, self.html)
- if found is not None:
- new_links.extend(found.group(1).split())
- else:
- found = re.findall(self.LINK_PATTERN, self.html)
- if found:
- prefered_set = set(self.getConfig("usedHoster").split('|'))
- new_links.extend([x[1] for x in found if x[0] in prefered_set])
-
- if not new_links:
- ignored_set = set(self.getConfig("ignoredHoster").split('|'))
- new_links.extend([x[1] for x in found if x[0] not in ignored_set])
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
diff --git a/module/plugins/crypter/MultiuploadCom.py b/module/plugins/crypter/MultiuploadCom.py
deleted file mode 100644
index 111ecdf6c..000000000
--- a/module/plugins/crypter/MultiuploadCom.py
+++ /dev/null
@@ -1,64 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from time import time
-
-from module.plugins.Crypter import Crypter
-from module.common.json_layer import json_loads
-
-
-class MultiuploadCom(Crypter):
- __name__ = "MultiuploadCom"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?multiupload.com/(\w+)"
- __version__ = "0.01"
- __description__ = """MultiUpload.com crypter"""
- __config__ = [("preferedHoster", "str", "Prefered hoster list (bar-separated) ", "multiupload"),
- ("ignoredHoster", "str", "Ignored hoster list (bar-separated) ", "")]
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- ML_LINK_PATTERN = r'<div id="downloadbutton_" style=""><a href="([^"]+)"'
-
- def decrypt(self, pyfile):
- self.html = self.load(pyfile.url)
- found = re.search(self.ML_LINK_PATTERN, self.html)
- ml_url = found.group(1) if found else None
-
- json_list = json_loads(self.load("http://multiupload.com/progress/", get={
- "d": re.search(self.__pattern__, pyfile.url).group(1),
- "r": str(int(time() * 1000))
- }))
- new_links = []
-
- prefered_set = map(lambda s: s.lower().split('.')[0], set(self.getConfig("preferedHoster").split('|')))
-
- if ml_url and 'multiupload' in prefered_set:
- new_links.append(ml_url)
-
- for link in json_list:
- if link['service'].lower() in prefered_set and int(link['status']) and not int(link['deleted']):
- url = self.getLocation(link['url'])
- if url:
- new_links.append(url)
-
- if not new_links:
- ignored_set = map(lambda s: s.lower().split('.')[0], set(self.getConfig("ignoredHoster").split('|')))
-
- if 'multiupload' not in ignored_set:
- new_links.append(ml_url)
-
- for link in json_list:
- if link['service'].lower() not in ignored_set and int(link['status']) and not int(link['deleted']):
- url = self.getLocation(link['url'])
- if url:
- new_links.append(url)
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
-
- def getLocation(self, url):
- header = self.load(url, just_header=True)
- return header['location'] if "location" in header else None
diff --git a/module/plugins/crypter/NCryptIn.py b/module/plugins/crypter/NCryptIn.py
deleted file mode 100644
index 3a474a1c6..000000000
--- a/module/plugins/crypter/NCryptIn.py
+++ /dev/null
@@ -1,304 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import base64
-import binascii
-import re
-
-from Crypto.Cipher import AES
-from module.plugins.Crypter import Crypter
-from module.plugins.internal.CaptchaService import ReCaptcha
-
-
-class NCryptIn(Crypter):
- __name__ = "NCryptIn"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?ncrypt.in/(?P<type>folder|link|frame)-([^/\?]+)"
- __version__ = "1.32"
- __description__ = """NCrypt.in Crypter Plugin"""
- __author_name__ = ("fragonib", "stickell")
- __author_mail__ = ("fragonib[AT]yahoo[DOT]es", "l.stickell@yahoo.it")
-
- # Constants
- _JK_KEY_ = "jk"
- _CRYPTED_KEY_ = "crypted"
-
- NAME_PATTERN = r'<meta name="description" content="(?P<N>[^"]+)"'
-
- def setup(self):
- self.package = None
- self.html = None
- self.cleanedHtml = None
- self.links_source_order = ['cnl2', 'rsdf', 'ccf', 'dlc', 'web']
- self.protection_type = None
-
- def decrypt(self, pyfile):
-
- # Init
- self.package = pyfile.package()
- package_links = []
- package_name = self.package.name
- folder_name = self.package.folder
-
- # Deal with single links
- if self.isSingleLink():
- package_links.extend(self.handleSingleLink())
-
- # Deal with folders
- else:
-
- # Request folder home
- self.html = self.requestFolderHome()
- self.cleanedHtml = self.removeHtmlCrap(self.html)
- if not self.isOnline():
- self.offline()
-
- # Check for folder protection
- if self.isProtected():
- self.html = self.unlockProtection()
- self.cleanedHtml = self.removeHtmlCrap(self.html)
- self.handleErrors()
-
- # Prepare package name and folder
- (package_name, folder_name) = self.getPackageInfo()
-
- # Extract package links
- for link_source_type in self.links_source_order:
- package_links.extend(self.handleLinkSource(link_source_type))
- if package_links: # use only first source which provides links
- break
- package_links = set(package_links)
-
- # Pack and return links
- if not package_links:
- self.fail('Could not extract any links')
- self.packages = [(package_name, package_links, folder_name)]
-
- def isSingleLink(self):
- link_type = re.search(self.__pattern__, self.pyfile.url).group('type')
- return link_type in ('link', 'frame')
-
- def requestFolderHome(self):
- return self.load(self.pyfile.url, decode=True)
-
- def removeHtmlCrap(self, content):
- patterns = (r'(type="hidden".*?(name=".*?")?.*?value=".*?")',
- r'display:none;">(.*?)</(div|span)>',
- r'<div\s+class="jdownloader"(.*?)</div>',
- r'<table class="global">(.*?)</table>',
- r'<iframe\s+style="display:none(.*?)</iframe>')
- for pattern in patterns:
- rexpr = re.compile(pattern, re.DOTALL)
- content = re.sub(rexpr, "", content)
- return content
-
- def isOnline(self):
- if "Your folder does not exist" in self.cleanedHtml:
- self.logDebug("File not found")
- return False
- return True
-
- def isProtected(self):
- form_match = re.search(r'<form.*?name.*?protected.*?>(.*?)</form>', self.cleanedHtml, re.DOTALL)
- if form_match:
- form_content = form_match.group(1)
- for keyword in ("password", "captcha"):
- if keyword in form_content:
- self.protection_type = keyword
- self.logDebug("Links are %s protected" % self.protection_type)
- return True
- return False
-
- def getPackageInfo(self):
- m = re.search(self.NAME_PATTERN, self.html)
- if m:
- name = folder = m.group('N').strip()
- self.logDebug("Found name [%s] and folder [%s] in package info" % (name, folder))
- else:
- name = self.package.name
- folder = self.package.folder
- self.logDebug("Package info not found, defaulting to pyfile name [%s] and folder [%s]" % (name, folder))
- return name, folder
-
- def unlockProtection(self):
-
- postData = {}
-
- form = re.search(r'<form name="protected"(.*?)</form>', self.cleanedHtml, re.DOTALL).group(1)
-
- # Submit package password
- if "password" in form:
- password = self.getPassword()
- self.logDebug("Submitting password [%s] for protected links" % password)
- postData['password'] = password
-
- # Resolve anicaptcha
- if "anicaptcha" in form:
- self.logDebug("Captcha protected")
- captchaUri = re.search(r'src="(/temp/anicaptcha/[^"]+)', form).group(1)
- captcha = self.decryptCaptcha("http://ncrypt.in" + captchaUri)
- self.logDebug("Captcha resolved [%s]" % captcha)
- postData['captcha'] = captcha
-
- # Resolve recaptcha
- if "recaptcha" in form:
- self.logDebug("ReCaptcha protected")
- captcha_key = re.search(r'\?k=(.*?)"', form).group(1)
- self.logDebug("Resolving ReCaptcha with key [%s]" % captcha_key)
- recaptcha = ReCaptcha(self)
- challenge, code = recaptcha.challenge(captcha_key)
- postData['recaptcha_challenge_field'] = challenge
- postData['recaptcha_response_field'] = code
-
- # Resolve circlecaptcha
- if "circlecaptcha" in form:
- self.logDebug("CircleCaptcha protected")
- captcha_img_url = "http://ncrypt.in/classes/captcha/circlecaptcha.php"
- coords = self.decryptCaptcha(captcha_img_url, forceUser=True, imgtype="png", result_type='positional')
- self.logDebug("Captcha resolved, coords [%s]" % str(coords))
- postData['circle.x'] = coords[0]
- postData['circle.y'] = coords[1]
-
- # Unlock protection
- postData['submit_protected'] = 'Continue to folder'
- return self.load(self.pyfile.url, post=postData, decode=True)
-
- def handleErrors(self):
-
- if self.protection_type == "password":
- if "This password is invalid!" in self.cleanedHtml:
- self.logDebug("Incorrect password, please set right password on 'Edit package' form and retry")
- self.fail("Incorrect password, please set right password on 'Edit package' form and retry")
-
- if self.protection_type == "captcha":
- if "The securitycheck was wrong!" in self.cleanedHtml:
- self.logDebug("Invalid captcha, retrying")
- self.invalidCaptcha()
- self.retry()
- else:
- self.correctCaptcha()
-
- def handleLinkSource(self, link_source_type):
-
- # Check for JS engine
- require_js_engine = link_source_type in ('cnl2', 'rsdf', 'ccf', 'dlc')
- if require_js_engine and not self.js:
- self.logDebug("No JS engine available, skip %s links" % link_source_type)
- return []
-
- # Select suitable handler
- if link_source_type == 'single':
- return self.handleSingleLink()
- if link_source_type == 'cnl2':
- return self.handleCNL2()
- elif link_source_type in ('rsdf', 'ccf', 'dlc'):
- return self.handleContainer(link_source_type)
- elif link_source_type == 'web':
- return self.handleWebLinks()
- else:
- self.fail('unknown source type "%s" (this is probably a bug)' % link_source_type)
-
- def handleSingleLink(self):
-
- self.logDebug("Handling Single link")
- package_links = []
-
- # Decrypt single link
- decrypted_link = self.decryptLink(self.pyfile.url)
- if decrypted_link:
- package_links.append(decrypted_link)
-
- return package_links
-
- def handleCNL2(self):
-
- self.logDebug("Handling CNL2 links")
- package_links = []
-
- if 'cnl2_output' in self.cleanedHtml:
- try:
- (vcrypted, vjk) = self._getCipherParams()
- for (crypted, jk) in zip(vcrypted, vjk):
- package_links.extend(self._getLinks(crypted, jk))
- except:
- self.fail("Unable to decrypt CNL2 links")
-
- return package_links
-
- def handleContainers(self):
-
- self.logDebug("Handling Container links")
- package_links = []
-
- pattern = r"/container/(rsdf|dlc|ccf)/([a-z0-9]+)"
- containersLinks = re.findall(pattern, self.html)
- self.logDebug("Decrypting %d Container links" % len(containersLinks))
- for containerLink in containersLinks:
- link = "http://ncrypt.in/container/%s/%s.%s" % (containerLink[0], containerLink[1], containerLink[0])
- package_links.append(link)
-
- return package_links
-
- def handleWebLinks(self):
-
- self.logDebug("Handling Web links")
- pattern = r"(http://ncrypt\.in/link-.*?=)"
- links = re.findall(pattern, self.html)
-
- package_links = []
- self.logDebug("Decrypting %d Web links" % len(links))
- for i, link in enumerate(links):
- self.logDebug("Decrypting Web link %d, %s" % (i + 1, link))
- decrypted_link = self.decrypt(link)
- if decrypted_link:
- package_links.append(decrypted_link)
-
- return package_links
-
- def decryptLink(self, link):
- try:
- url = link.replace("link-", "frame-")
- link = self.load(url, just_header=True)['location']
- return link
- except Exception, detail:
- self.logDebug("Error decrypting link %s, %s" % (link, detail))
-
- def _getCipherParams(self):
-
- pattern = r'<input.*?name="%s".*?value="(.*?)"'
-
- # Get jk
- jk_re = pattern % NCryptIn._JK_KEY_
- vjk = re.findall(jk_re, self.html)
-
- # Get crypted
- crypted_re = pattern % NCryptIn._CRYPTED_KEY_
- vcrypted = re.findall(crypted_re, self.html)
-
- # Log and return
- self.logDebug("Detected %d crypted blocks" % len(vcrypted))
- return vcrypted, vjk
-
- def _getLinks(self, crypted, jk):
-
- # Get key
- jreturn = self.js.eval("%s f()" % jk)
- self.logDebug("JsEngine returns value [%s]" % jreturn)
- key = binascii.unhexlify(jreturn)
-
- # Decode crypted
- crypted = base64.standard_b64decode(crypted)
-
- # Decrypt
- Key = key
- IV = key
- obj = AES.new(Key, AES.MODE_CBC, IV)
- text = obj.decrypt(crypted)
-
- # Extract links
- text = text.replace("\x00", "").replace("\r", "")
- links = text.split("\n")
- links = filter(lambda x: x != "", links)
-
- # Log and return
- self.logDebug("Block has %d links" % len(links))
- return links
diff --git a/module/plugins/crypter/NetfolderIn.py b/module/plugins/crypter/NetfolderIn.py
deleted file mode 100644
index c5c602c27..000000000
--- a/module/plugins/crypter/NetfolderIn.py
+++ /dev/null
@@ -1,71 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class NetfolderIn(SimpleCrypter):
- __name__ = "NetfolderIn"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?netfolder.in/((?P<id1>\w+)/\w+|folder.php\?folder_id=(?P<id2>\w+))"
- __version__ = "0.6"
- __description__ = """NetFolder Crypter Plugin"""
- __author_name__ = ("RaNaN", "fragonib")
- __author_mail__ = ("RaNaN@pyload.org", "fragonib[AT]yahoo[DOT]es")
-
- TITLE_PATTERN = r'<div class="Text">Inhalt des Ordners <span(.*)>(?P<title>.+)</span></div>'
-
- def decrypt(self, pyfile):
- # Request package
- self.html = self.load(pyfile.url)
-
- # Check for password protection
- if self.isPasswordProtected():
- self.html = self.submitPassword()
- if self.html is None:
- self.fail("Incorrect password, please set right password on Add package form and retry")
-
- # Get package name and folder
- (package_name, folder_name) = self.getPackageNameAndFolder()
-
- # Get package links
- package_links = self.getLinks()
-
- # Set package
- self.packages = [(package_name, package_links, folder_name)]
-
- def isPasswordProtected(self):
-
- if '<input type="password" name="password"' in self.html:
- self.logDebug("Links are password protected")
- return True
- return False
-
- def submitPassword(self):
- # Gather data
- try:
- m = re.match(self.__pattern__, self.pyfile.url)
- id = max(m.group('id1'), m.group('id2'))
- except AttributeError:
- self.logDebug("Unable to get package id from url [%s]" % self.pyfile.url)
- return
- url = "http://netfolder.in/folder.php?folder_id=" + id
- password = self.getPassword()
-
- # Submit package password
- post = {'password': password, 'save': 'Absenden'}
- self.logDebug("Submitting password [%s] for protected links with id [%s]" % (password, id))
- html = self.load(url, {}, post)
-
- # Check for invalid password
- if '<div class="InPage_Error">' in html:
- self.logDebug("Incorrect password, please set right password on Edit package form and retry")
- return None
-
- return html
-
- def getLinks(self):
- links = re.search(r'name="list" value="(.*?)"', self.html).group(1).split(",")
- self.logDebug("Package has %d links" % len(links))
- return links
diff --git a/module/plugins/crypter/OneKhDe.py b/module/plugins/crypter/OneKhDe.py
deleted file mode 100644
index a2e6d039e..000000000
--- a/module/plugins/crypter/OneKhDe.py
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.unescape import unescape
-from module.plugins.Crypter import Crypter
-
-
-class OneKhDe(Crypter):
- __name__ = "OneKhDe"
- __type__ = "container"
- __pattern__ = r"http://(www\.)?1kh.de/f/"
- __version__ = "0.1"
- __description__ = """1kh.de Container Plugin"""
- __author_name__ = ("spoob")
- __author_mail__ = ("spoob@pyload.org")
-
- def __init__(self, parent):
- Crypter.__init__(self, parent)
- self.parent = parent
- self.html = None
-
- def file_exists(self):
- """ returns True or False
- """
- return True
-
- def proceed(self, url, location):
- url = self.parent.url
- self.html = self.req.load(url)
- temp_links = []
- link_ids = re.findall(r"<a id=\"DownloadLink_(\d*)\" href=\"http://1kh.de/", self.html)
- for id in link_ids:
- new_link = unescape(
- re.search("width=\"100%\" src=\"(.*)\"></iframe>", self.req.load("http://1kh.de/l/" + id)).group(1))
- temp_links.append(new_link)
- self.links = temp_links
diff --git a/module/plugins/crypter/OronComFolder.py b/module/plugins/crypter/OronComFolder.py
deleted file mode 100755
index 98d7e8242..000000000
--- a/module/plugins/crypter/OronComFolder.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class OronComFolder(DeadCrypter):
- __name__ = "OronComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?oron.com/folder/\w+"
- __version__ = "0.11"
- __description__ = """Oron.com Folder Plugin"""
- __author_name__ = ("DHMH")
- __author_mail__ = ("webmaster@pcProfil.de")
diff --git a/module/plugins/crypter/PastebinCom.py b/module/plugins/crypter/PastebinCom.py
deleted file mode 100644
index 942ab613b..000000000
--- a/module/plugins/crypter/PastebinCom.py
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class PastebinCom(SimpleCrypter):
- __name__ = "PastebinCom"
- __type__ = "crypter"
- __pattern__ = r"http://(?:w{3}.)?pastebin\.com/\w+"
- __version__ = "0.01"
- __description__ = """Pastebin.com Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- LINK_PATTERN = r'<div class="de\d+">(https?://[^ <]+)(?:[^<]*)</div>'
- TITLE_PATTERN = r'<div class="paste_box_line1" title="(?P<title>[^"]+)">'
diff --git a/module/plugins/crypter/QuickshareCzFolder.py b/module/plugins/crypter/QuickshareCzFolder.py
deleted file mode 100644
index 18ac68eec..000000000
--- a/module/plugins/crypter/QuickshareCzFolder.py
+++ /dev/null
@@ -1,31 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-
-
-class QuickshareCzFolder(Crypter):
- __name__ = "QuickshareCzFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?quickshare.cz/slozka-\d+.*"
- __version__ = "0.1"
- __description__ = """Quickshare.cz Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- FOLDER_PATTERN = r'<textarea[^>]*>(.*?)</textarea>'
- LINK_PATTERN = r'(http://www.quickshare.cz/\S+)'
-
- def decrypt(self, pyfile):
- html = self.load(self.pyfile.url)
-
- new_links = []
- found = re.search(self.FOLDER_PATTERN, html, re.DOTALL)
- if found is None:
- self.fail("Parse error (FOLDER)")
- new_links.extend(re.findall(self.LINK_PATTERN, found.group(1)))
-
- if new_links:
- self.core.files.addLinks(new_links, self.pyfile.package().id)
- else:
- self.fail('Could not extract any links') \ No newline at end of file
diff --git a/module/plugins/crypter/RSLayerCom.py b/module/plugins/crypter/RSLayerCom.py
deleted file mode 100644
index 0dc7ddf4e..000000000
--- a/module/plugins/crypter/RSLayerCom.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class RSLayerCom(DeadCrypter):
- __name__ = "RSLayerCom"
- __type__ = "container"
- __pattern__ = r"http://(www\.)?rs-layer.com/directory-"
- __version__ = "0.21"
- __description__ = """RS-Layer.com Container Plugin"""
- __author_name__ = ("hzpz")
- __author_mail__ = ("none")
diff --git a/module/plugins/crypter/RelinkUs.py b/module/plugins/crypter/RelinkUs.py
deleted file mode 100644
index 104968e06..000000000
--- a/module/plugins/crypter/RelinkUs.py
+++ /dev/null
@@ -1,264 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import base64
-import binascii
-import re
-import os
-
-from Crypto.Cipher import AES
-from module.plugins.Crypter import Crypter
-
-
-class RelinkUs(Crypter):
- __name__ = "RelinkUs"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?relink.us/(f/|((view|go).php\?id=))(?P<id>.+)"
- __version__ = "3.0"
- __description__ = """Relink.us Crypter Plugin"""
- __author_name__ = ("fragonib")
- __author_mail__ = ("fragonib[AT]yahoo[DOT]es")
-
- # Constants
- PREFERRED_LINK_SOURCES = ['cnl2', 'dlc', 'web']
-
- OFFLINE_TOKEN = "<title>Tattooside"
- PASSWORD_TOKEN = "container_password.php"
- PASSWORD_ERROR_ROKEN = "You have entered an incorrect password"
- PASSWORD_SUBMIT_URL = "http://www.relink.us/container_password.php"
- CAPTCHA_TOKEN = "container_captcha.php"
- CAPTCHA_ERROR_ROKEN = "You have solved the captcha wrong"
- CAPTCHA_IMG_URL = "http://www.relink.us/core/captcha/circlecaptcha.php"
- CAPTCHA_SUBMIT_URL = "http://www.relink.us/container_captcha.php"
- FILE_TITLE_REGEX = r"<th>Title</th><td><i>(.*)</i></td></tr>"
- FILE_NOTITLE = 'No title'
-
- CNL2_FORM_REGEX = r'<form id="cnl_form-(.*?)</form>'
- CNL2_FORMINPUT_REGEX = r'<input.*?name="%s".*?value="(.*?)"'
- CNL2_JK_KEY = "jk"
- CNL2_CRYPTED_KEY = "crypted"
- DLC_LINK_REGEX = r'<a href=".*?" class="dlc_button" target="_blank">'
- DLC_DOWNLOAD_URL = "http://www.relink.us/download.php"
- WEB_FORWARD_REGEX = r"getFile\('(?P<link>.+)'\)"
- WEB_FORWARD_URL = "http://www.relink.us/frame.php"
- WEB_LINK_REGEX = r'<iframe name="Container" height="100%" frameborder="no" width="100%" src="(?P<link>.+)"></iframe>'
-
- def setup(self):
- self.fileid = None
- self.package = None
- self.password = None
- self.html = None
- self.captcha = False
-
- def decrypt(self, pyfile):
-
- # Init
- self.initPackage(pyfile)
-
- # Request package
- self.requestPackage()
-
- # Check for online
- if not self.isOnline():
- self.offline()
-
- # Check for protection
- if self.isPasswordProtected():
- self.unlockPasswordProtection()
- self.handleErrors()
-
- if self.isCaptchaProtected():
- self.captcha = True
- self.unlockCaptchaProtection()
- self.handleErrors()
-
- # Get package name and folder
- (package_name, folder_name) = self.getPackageInfo()
-
- # Extract package links
- package_links = []
- for sources in self.PREFERRED_LINK_SOURCES:
- package_links.extend(self.handleLinkSource(sources))
- if package_links: # use only first source which provides links
- break
- package_links = set(package_links)
-
- # Pack
- if package_links:
- self.packages = [(package_name, package_links, folder_name)]
- else:
- self.fail('Could not extract any links')
-
- def initPackage(self, pyfile):
- self.fileid = re.match(self.__pattern__, pyfile.url).group('id')
- self.package = pyfile.package()
- self.password = self.getPassword()
- self.url = pyfile.url
-
- def requestPackage(self):
- self.html = self.load(self.url, decode=True)
-
- def isOnline(self):
- if self.OFFLINE_TOKEN in self.html:
- self.logDebug("File not found")
- return False
- return True
-
- def isPasswordProtected(self):
- if self.PASSWORD_TOKEN in self.html:
- self.logDebug("Links are password protected")
- return True
-
- def isCaptchaProtected(self):
- if self.CAPTCHA_TOKEN in self.html:
- self.logDebug("Links are captcha protected")
- return True
- return False
-
- def unlockPasswordProtection(self):
- self.logDebug("Submitting password [%s] for protected links" % self.password)
- passwd_url = self.PASSWORD_SUBMIT_URL + "?id=%s" % self.fileid
- passwd_data = {'id': self.fileid, 'password': self.password, 'pw': 'submit'}
- self.html = self.load(passwd_url, post=passwd_data, decode=True)
-
- def unlockCaptchaProtection(self):
- self.logDebug("Request user positional captcha resolving")
- captcha_img_url = self.CAPTCHA_IMG_URL + "?id=%s" % self.fileid
- coords = self.decryptCaptcha(captcha_img_url, forceUser=True, imgtype="png", result_type='positional')
- self.logDebug("Captcha resolved, coords [%s]" % str(coords))
- captcha_post_url = self.CAPTCHA_SUBMIT_URL + "?id=%s" % self.fileid
- captcha_post_data = {'button.x': coords[0], 'button.y': coords[1], 'captcha': 'submit'}
- self.html = self.load(captcha_post_url, post=captcha_post_data, decode=True)
-
- def getPackageInfo(self):
- name = folder = None
-
- # Try to get info from web
- m = re.search(self.FILE_TITLE_REGEX, self.html)
- if m is not None:
- title = m.group(1).strip()
- if not self.FILE_NOTITLE in title:
- name = folder = title
- self.logDebug("Found name [%s] and folder [%s] in package info" % (name, folder))
-
- # Fallback to defaults
- if not name or not folder:
- name = self.package.name
- folder = self.package.folder
- self.logDebug("Package info not found, defaulting to pyfile name [%s] and folder [%s]" % (name, folder))
-
- # Return package info
- return name, folder
-
- def handleErrors(self):
- if self.PASSWORD_ERROR_ROKEN in self.html:
- msg = "Incorrect password, please set right password on 'Edit package' form and retry"
- self.logDebug(msg)
- self.fail(msg)
-
- if self.captcha:
- if self.CAPTCHA_ERROR_ROKEN in self.html:
- self.logDebug("Invalid captcha, retrying")
- self.invalidCaptcha()
- self.retry()
- else:
- self.correctCaptcha()
-
- def handleLinkSource(self, source):
- if source == 'cnl2':
- return self.handleCNL2Links()
- elif source == 'dlc':
- return self.handleDLCLinks()
- elif source == 'web':
- return self.handleWEBLinks()
- else:
- self.fail('Unknown source [%s] (this is probably a bug)' % source)
-
- def handleCNL2Links(self):
- self.logDebug("Search for CNL2 links")
- package_links = []
- m = re.search(self.CNL2_FORM_REGEX, self.html, re.DOTALL)
- if m is not None:
- cnl2_form = m.group(1)
- try:
- (vcrypted, vjk) = self._getCipherParams(cnl2_form)
- for (crypted, jk) in zip(vcrypted, vjk):
- package_links.extend(self._getLinks(crypted, jk))
- except:
- self.logDebug("Unable to decrypt CNL2 links")
- return package_links
-
- def handleDLCLinks(self):
- self.logDebug('Search for DLC links')
- package_links = []
- m = re.search(self.DLC_LINK_REGEX, self.html)
- if m is not None:
- container_url = self.DLC_DOWNLOAD_URL + "?id=%s&dlc=1" % self.fileid
- self.logDebug("Downloading DLC container link [%s]" % container_url)
- try:
- dlc = self.load(container_url)
- dlc_filename = self.fileid + ".dlc"
- dlc_filepath = os.path.join(self.config["general"]["download_folder"], dlc_filename)
- f = open(dlc_filepath, "wb")
- f.write(dlc)
- f.close()
- package_links.append(dlc_filepath)
- except:
- self.logDebug("Unable to download DLC container")
- return package_links
-
- def handleWEBLinks(self):
- self.logDebug("Search for WEB links")
- package_links = []
- fw_params = re.findall(self.WEB_FORWARD_REGEX, self.html)
- self.logDebug("Decrypting %d Web links" % len(fw_params))
- for index, fw_param in enumerate(fw_params):
- try:
- fw_url = self.WEB_FORWARD_URL + "?%s" % fw_param
- self.logDebug("Decrypting Web link %d, %s" % (index + 1, fw_url))
- fw_response = self.load(fw_url, decode=True)
- dl_link = re.search(self.WEB_LINK_REGEX, fw_response).group('link')
- package_links.append(dl_link)
- except Exception, detail:
- self.logDebug("Error decrypting Web link %s, %s" % (index, detail))
- self.setWait(4)
- self.wait()
- return package_links
-
- def _getCipherParams(self, cnl2_form):
-
- # Get jk
- jk_re = self.CNL2_FORMINPUT_REGEX % self.CNL2_JK_KEY
- vjk = re.findall(jk_re, cnl2_form, re.IGNORECASE)
-
- # Get crypted
- crypted_re = self.CNL2_FORMINPUT_REGEX % RelinkUs.CNL2_CRYPTED_KEY
- vcrypted = re.findall(crypted_re, cnl2_form, re.IGNORECASE)
-
- # Log and return
- self.logDebug("Detected %d crypted blocks" % len(vcrypted))
- return vcrypted, vjk
-
- def _getLinks(self, crypted, jk):
-
- # Get key
- jreturn = self.js.eval("%s f()" % jk)
- self.logDebug("JsEngine returns value [%s]" % jreturn)
- key = binascii.unhexlify(jreturn)
-
- # Decode crypted
- crypted = base64.standard_b64decode(crypted)
-
- # Decrypt
- Key = key
- IV = key
- obj = AES.new(Key, AES.MODE_CBC, IV)
- text = obj.decrypt(crypted)
-
- # Extract links
- text = text.replace("\x00", "").replace("\r", "")
- links = text.split("\n")
- links = filter(lambda x: x != "", links)
-
- # Log and return
- self.logDebug("Package has %d links" % len(links))
- return links
diff --git a/module/plugins/crypter/SecuredIn.py b/module/plugins/crypter/SecuredIn.py
deleted file mode 100644
index 4c3bbf4a6..000000000
--- a/module/plugins/crypter/SecuredIn.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class SecuredIn(DeadCrypter):
- __name__ = "SecuredIn"
- __type__ = "container"
- __pattern__ = r"http://[\w\.]*?secured\.in/download-[\d]+-[\w]{8}\.html"
- __version__ = "0.21"
- __description__ = """secured.in Container Plugin"""
- __author_name__ = ("mkaay")
- __author_mail__ = ("mkaay@mkaay.de")
diff --git a/module/plugins/crypter/SerienjunkiesOrg.py b/module/plugins/crypter/SerienjunkiesOrg.py
deleted file mode 100644
index e0eb7e240..000000000
--- a/module/plugins/crypter/SerienjunkiesOrg.py
+++ /dev/null
@@ -1,320 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from time import sleep
-import random
-from module.plugins.Crypter import Crypter
-from module.lib.BeautifulSoup import BeautifulSoup
-from module.unescape import unescape
-
-
-class SerienjunkiesOrg(Crypter):
- __name__ = "SerienjunkiesOrg"
- __type__ = "container"
- __pattern__ = r"http://.*?(serienjunkies.org|dokujunkies.org)/.*?"
- __version__ = "0.39"
- __config__ = [
- ("changeNameSJ", "Packagename;Show;Season;Format;Episode", "Take SJ.org name", "Show"),
- ("changeNameDJ", "Packagename;Show;Format;Episode", "Take DJ.org name", "Show"),
- ("randomPreferred", "bool", "Randomize Preferred-List", False),
- ("hosterListMode", "OnlyOne;OnlyPreferred(One);OnlyPreferred(All);All",
- "Use for hosters (if supported)", "All"),
- ("hosterList", "str", "Preferred Hoster list (comma separated)",
- "RapidshareCom,UploadedTo,NetloadIn,FilefactoryCom,FreakshareNet,FilebaseTo,HotfileCom,DepositfilesCom,EasyshareCom,KickloadCom"),
- ("ignoreList", "str", "Ignored Hoster list (comma separated)", "MegauploadCom")
- ]
- __description__ = """serienjunkies.org Container Plugin"""
- __author_name__ = ("mkaay", "godofdream")
- __author_mail__ = ("mkaay@mkaay.de", "soilfiction@gmail.com")
-
- def setup(self):
- self.multiDL = False
-
- def getSJSrc(self, url):
- src = self.req.load(str(url))
- if "This website is not available in your country" in src:
- self.fail("Not available in your country")
- if not src.find("Enter Serienjunkies") == -1:
- sleep(1)
- src = self.req.load(str(url))
- return src
-
- def handleShow(self, url):
- src = self.getSJSrc(url)
- soup = BeautifulSoup(src)
- packageName = self.pyfile.package().name
- if self.getConfig("changeNameSJ") == "Show":
- found = unescape(soup.find("h2").find("a").string.split(' &#8211;')[0])
- if found:
- packageName = found
-
- nav = soup.find("div", attrs={"id": "scb"})
-
- package_links = []
- for a in nav.findAll("a"):
- if self.getConfig("changeNameSJ") == "Show":
- package_links.append(a["href"])
- else:
- package_links.append(a["href"] + "#hasName")
- if self.getConfig("changeNameSJ") == "Show":
- self.packages.append((packageName, package_links, packageName))
- else:
- self.core.files.addLinks(package_links, self.pyfile.package().id)
-
- def handleSeason(self, url):
- src = self.getSJSrc(url)
- soup = BeautifulSoup(src)
- post = soup.find("div", attrs={"class": "post-content"})
- ps = post.findAll("p")
-
- seasonName = unescape(soup.find("a", attrs={"rel": "bookmark"}).string).replace("&#8211;", "-")
- groups = {}
- gid = -1
- for p in ps:
- if re.search("<strong>Sprache|<strong>Format", str(p)):
- var = p.findAll("strong")
- opts = {"Sprache": "", "Format": ""}
- for v in var:
- n = unescape(v.string).strip()
- n = re.sub(r"^([:]?)(.*?)([:]?)$", r'\2', n)
- if n.strip() not in opts:
- continue
- val = v.nextSibling
- if not val:
- continue
- val = val.replace("|", "").strip()
- val = re.sub(r"^([:]?)(.*?)([:]?)$", r'\2', val)
- opts[n.strip()] = val.strip()
- gid += 1
- groups[gid] = {}
- groups[gid]["ep"] = {}
- groups[gid]["opts"] = opts
- elif re.search("<strong>Download:", str(p)):
- parts = str(p).split("<br />")
- if re.search("<strong>", parts[0]):
- ename = re.search('<strong>(.*?)</strong>', parts[0]).group(1).strip().decode("utf-8").replace(
- "&#8211;", "-")
- groups[gid]["ep"][ename] = {}
- parts.remove(parts[0])
- for part in parts:
- hostername = re.search(r" \| ([-a-zA-Z0-9]+\.\w+)", part)
- if hostername:
- hostername = hostername.group(1)
- groups[gid]["ep"][ename][hostername] = []
- links = re.findall('href="(.*?)"', part)
- for link in links:
- groups[gid]["ep"][ename][hostername].append(link + "#hasName")
-
- links = []
- for g in groups.values():
- for ename in g["ep"]:
- links.extend(self.getpreferred(g["ep"][ename]))
- if self.getConfig("changeNameSJ") == "Episode":
- self.packages.append((ename, links, ename))
- links = []
- package = "%s (%s, %s)" % (seasonName, g["opts"]["Format"], g["opts"]["Sprache"])
- if self.getConfig("changeNameSJ") == "Format":
- self.packages.append((package, links, package))
- links = []
- if (self.getConfig("changeNameSJ") == "Packagename") or re.search("#hasName", url):
- self.core.files.addLinks(links, self.pyfile.package().id)
- elif (self.getConfig("changeNameSJ") == "Season") or not re.search("#hasName", url):
- self.packages.append((seasonName, links, seasonName))
-
- def handleEpisode(self, url):
- src = self.getSJSrc(url)
- if not src.find(
- "Du hast das Download-Limit &uuml;berschritten! Bitte versuche es sp&auml;ter nocheinmal.") == -1:
- self.fail(_("Downloadlimit reached"))
- else:
- soup = BeautifulSoup(src)
- form = soup.find("form")
- h1 = soup.find("h1")
-
- if h1.get("class") == "wrap":
- captchaTag = soup.find(attrs={"src": re.compile("^/secure/")})
- if not captchaTag:
- sleep(5)
- self.retry()
-
- captchaUrl = "http://download.serienjunkies.org" + captchaTag["src"]
- result = self.decryptCaptcha(str(captchaUrl), imgtype="png")
- sinp = form.find(attrs={"name": "s"})
-
- self.req.lastURL = str(url)
- sj = self.load(str(url), post={'s': sinp["value"], 'c': result, 'action': "Download"})
-
- soup = BeautifulSoup(sj)
- rawLinks = soup.findAll(attrs={"action": re.compile("^http://download.serienjunkies.org/")})
-
- if not len(rawLinks) > 0:
- sleep(1)
- self.retry()
- return
-
- self.correctCaptcha()
-
- links = []
- for link in rawLinks:
- frameUrl = link["action"].replace("/go-", "/frame/go-")
- links.append(self.handleFrame(frameUrl))
- if re.search("#hasName", url) or ((self.getConfig("changeNameSJ") == "Packagename") and
- (self.getConfig("changeNameDJ") == "Packagename")):
- self.core.files.addLinks(links, self.pyfile.package().id)
- else:
- if h1.text[2] == "_":
- eName = h1.text[3:]
- else:
- eName = h1.text
- self.packages.append((eName, links, eName))
-
- def handleOldStyleLink(self, url):
- sj = self.req.load(str(url))
- soup = BeautifulSoup(sj)
- form = soup.find("form", attrs={"action": re.compile("^http://serienjunkies.org")})
- captchaTag = form.find(attrs={"src": re.compile("^/safe/secure/")})
- captchaUrl = "http://serienjunkies.org" + captchaTag["src"]
- result = self.decryptCaptcha(str(captchaUrl))
- url = form["action"]
- sinp = form.find(attrs={"name": "s"})
-
- self.req.load(str(url), post={'s': sinp["value"], 'c': result, 'dl.start': "Download"}, cookies=False,
- just_header=True)
- decrypted = self.req.lastEffectiveURL
- if decrypted == str(url):
- self.retry()
- self.core.files.addLinks([decrypted], self.pyfile.package().id)
-
- def handleFrame(self, url):
- self.req.load(str(url))
- return self.req.lastEffectiveURL
-
- def handleShowDJ(self, url):
- src = self.getSJSrc(url)
- soup = BeautifulSoup(src)
- post = soup.find("div", attrs={"id": "page_post"})
- ps = post.findAll("p")
- found = unescape(soup.find("h2").find("a").string.split(' &#8211;')[0])
- if found:
- seasonName = found
-
- groups = {}
- gid = -1
- for p in ps:
- if re.search("<strong>Sprache|<strong>Format", str(p)):
- var = p.findAll("strong")
- opts = {"Sprache": "", "Format": ""}
- for v in var:
- n = unescape(v.string).strip()
- n = re.sub(r"^([:]?)(.*?)([:]?)$", r'\2', n)
- if n.strip() not in opts:
- continue
- val = v.nextSibling
- if not val:
- continue
- val = val.replace("|", "").strip()
- val = re.sub(r"^([:]?)(.*?)([:]?)$", r'\2', val)
- opts[n.strip()] = val.strip()
- gid += 1
- groups[gid] = {}
- groups[gid]["ep"] = {}
- groups[gid]["opts"] = opts
- elif re.search("<strong>Download:", str(p)):
- parts = str(p).split("<br />")
- if re.search("<strong>", parts[0]):
- ename = re.search('<strong>(.*?)</strong>', parts[0]).group(1).strip().decode("utf-8").replace(
- "&#8211;", "-")
- groups[gid]["ep"][ename] = {}
- parts.remove(parts[0])
- for part in parts:
- hostername = re.search(r" \| ([-a-zA-Z0-9]+\.\w+)", part)
- if hostername:
- hostername = hostername.group(1)
- groups[gid]["ep"][ename][hostername] = []
- links = re.findall('href="(.*?)"', part)
- for link in links:
- groups[gid]["ep"][ename][hostername].append(link + "#hasName")
-
- links = []
- for g in groups.values():
- for ename in g["ep"]:
- links.extend(self.getpreferred(g["ep"][ename]))
- if self.getConfig("changeNameDJ") == "Episode":
- self.packages.append((ename, links, ename))
- links = []
- package = "%s (%s, %s)" % (seasonName, g["opts"]["Format"], g["opts"]["Sprache"])
- if self.getConfig("changeNameDJ") == "Format":
- self.packages.append((package, links, package))
- links = []
- if (self.getConfig("changeNameDJ") == "Packagename") or re.search("#hasName", url):
- self.core.files.addLinks(links, self.pyfile.package().id)
- elif (self.getConfig("changeNameDJ") == "Show") or not re.search("#hasName", url):
- self.packages.append((seasonName, links, seasonName))
-
- def handleCategoryDJ(self, url):
- package_links = []
- src = self.getSJSrc(url)
- soup = BeautifulSoup(src)
- content = soup.find("div", attrs={"id": "content"})
- for a in content.findAll("a", attrs={"rel": "bookmark"}):
- package_links.append(a["href"])
- self.core.files.addLinks(package_links, self.pyfile.package().id)
-
- def decrypt(self, pyfile):
- showPattern = re.compile("^http://serienjunkies.org/serie/(.*)/$")
- seasonPattern = re.compile("^http://serienjunkies.org/.*?/(.*)/$")
- episodePattern = re.compile("^http://download.serienjunkies.org/f-.*?.html(#hasName)?$")
- oldStyleLink = re.compile("^http://serienjunkies.org/safe/(.*)$")
- categoryPatternDJ = re.compile("^http://dokujunkies.org/.*?(.*)$")
- showPatternDJ = re.compile(r"^http://dokujunkies.org/.*?/(.*)\.html(#hasName)?$")
- framePattern = re.compile("^http://download.(serienjunkies.org|dokujunkies.org)/frame/go-.*?/$")
- url = pyfile.url
- if framePattern.match(url):
- self.packages.append((self.pyfile.package().name, [self.handleFrame(url)], self.pyfile.package().name))
- elif episodePattern.match(url):
- self.handleEpisode(url)
- elif oldStyleLink.match(url):
- self.handleOldStyleLink(url)
- elif showPattern.match(url):
- self.handleShow(url)
- elif showPatternDJ.match(url):
- self.handleShowDJ(url)
- elif seasonPattern.match(url):
- self.handleSeason(url)
- elif categoryPatternDJ.match(url):
- self.handleCategoryDJ(url)
-
- #selects the preferred hoster, after that selects any hoster (ignoring the one to ignore)
- def getpreferred(self, hosterlist):
-
- result = []
- preferredList = self.getConfig("hosterList").strip().lower().replace(
- '|', ',').replace('.', '').replace(';', ',').split(',')
- if (self.getConfig("randomPreferred") is True) and (
- self.getConfig("hosterListMode") in ["OnlyOne", "OnlyPreferred(One)"]):
- random.shuffle(preferredList)
- # we don't want hosters be read two times
- hosterlist2 = hosterlist.copy()
-
- for preferred in preferredList:
- for Hoster in hosterlist:
- if preferred == Hoster.lower().replace('.', ''):
- for Part in hosterlist[Hoster]:
- self.logDebug("selected " + Part)
- result.append(str(Part))
- del (hosterlist2[Hoster])
- if self.getConfig("hosterListMode") in ["OnlyOne", "OnlyPreferred(One)"]:
- return result
-
- ignorelist = self.getConfig("ignoreList").strip().lower().replace(
- '|', ',').replace('.', '').replace(';', ',').split(',')
- if self.getConfig('hosterListMode') in ["OnlyOne", "All"]:
- for Hoster in hosterlist2:
- if Hoster.strip().lower().replace('.', '') not in ignorelist:
- for Part in hosterlist2[Hoster]:
- self.logDebug("selected2 " + Part)
- result.append(str(Part))
-
- if self.getConfig('hosterListMode') == "OnlyOne":
- return result
- return result
diff --git a/module/plugins/crypter/ShareLinksBiz.py b/module/plugins/crypter/ShareLinksBiz.py
deleted file mode 100644
index 09ac21873..000000000
--- a/module/plugins/crypter/ShareLinksBiz.py
+++ /dev/null
@@ -1,269 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import base64
-import binascii
-import re
-
-from Crypto.Cipher import AES
-from module.plugins.Crypter import Crypter
-
-
-class ShareLinksBiz(Crypter):
- __name__ = "ShareLinksBiz"
- __type__ = "crypter"
- __pattern__ = r"(?P<base>http://[\w\.]*?(share-links|s2l)\.biz)/(?P<id>_?[0-9a-z]+)(/.*)?"
- __version__ = "1.13"
- __description__ = """Share-Links.biz Crypter"""
- __author_name__ = ("fragonib")
- __author_mail__ = ("fragonib[AT]yahoo[DOT]es")
-
- def setup(self):
- self.baseUrl = None
- self.fileId = None
- self.package = None
- self.html = None
- self.captcha = False
-
- def decrypt(self, pyfile):
-
- # Init
- self.initFile(pyfile)
-
- # Request package
- url = self.baseUrl + '/' + self.fileId
- self.html = self.load(url, decode=True)
-
- # Unblock server (load all images)
- self.unblockServer()
-
- # Check for protection
- if self.isPasswordProtected():
- self.unlockPasswordProtection()
- self.handleErrors()
-
- if self.isCaptchaProtected():
- self.captcha = True
- self.unlockCaptchaProtection()
- self.handleErrors()
-
- # Extract package links
- package_links = []
- package_links.extend(self.handleWebLinks())
- package_links.extend(self.handleContainers())
- package_links.extend(self.handleCNL2())
- package_links = set(package_links)
-
- # Get package info
- package_name, package_folder = self.getPackageInfo()
-
- # Pack
- self.packages = [(package_name, package_links, package_folder)]
-
- def initFile(self, pyfile):
- url = pyfile.url
- if 's2l.biz' in url:
- url = self.load(url, just_header=True)['location']
- self.baseUrl = re.search(self.__pattern__, url).group(1)
- self.fileId = re.match(self.__pattern__, url).group('id')
- self.package = pyfile.package()
-
- def isOnline(self):
- if "No usable content was found" in self.html:
- self.logDebug("File not found")
- return False
- return True
-
- def isPasswordProtected(self):
- if re.search(r'''<form.*?id="passwordForm".*?>''', self.html):
- self.logDebug("Links are protected")
- return True
- return False
-
- def isCaptchaProtected(self):
- if '<map id="captchamap"' in self.html:
- self.logDebug("Links are captcha protected")
- return True
- return False
-
- def unblockServer(self):
- imgs = re.findall(r"(/template/images/.*?\.gif)", self.html)
- for img in imgs:
- self.load(self.baseUrl + img)
-
- def unlockPasswordProtection(self):
- password = self.getPassword()
- self.logDebug("Submitting password [%s] for protected links" % password)
- post = {"password": password, 'login': 'Submit form'}
- url = self.baseUrl + '/' + self.fileId
- self.html = self.load(url, post=post, decode=True)
-
- def unlockCaptchaProtection(self):
- # Get captcha map
- captchaMap = self._getCaptchaMap()
- self.logDebug("Captcha map with [%d] positions" % len(captchaMap.keys()))
-
- # Request user for captcha coords
- m = re.search(r'<img src="/captcha.gif\?d=(.*?)&amp;PHPSESSID=(.*?)&amp;legend=1"', self.html)
- captchaUrl = self.baseUrl + '/captcha.gif?d=%s&PHPSESSID=%s' % (m.group(1), m.group(2))
- self.logDebug("Waiting user for correct position")
- coords = self.decryptCaptcha(captchaUrl, forceUser=True, imgtype="gif", result_type='positional')
- self.logDebug("Captcha resolved, coords [%s]" % str(coords))
-
- # Resolve captcha
- href = self._resolveCoords(coords, captchaMap)
- if href is None:
- self.logDebug("Invalid captcha resolving, retrying")
- self.invalidCaptcha()
- self.setWait(5, False)
- self.wait()
- self.retry()
- url = self.baseUrl + href
- self.html = self.load(url, decode=True)
-
- def _getCaptchaMap(self):
- mapp = {}
- for m in re.finditer(r'<area shape="rect" coords="(.*?)" href="(.*?)"', self.html):
- rect = eval('(' + m.group(1) + ')')
- href = m.group(2)
- mapp[rect] = href
- return mapp
-
- def _resolveCoords(self, coords, captchaMap):
- x, y = coords
- for rect, href in captchaMap.items():
- x1, y1, x2, y2 = rect
- if (x >= x1 and x <= x2) and (y >= y1 and y <= y2):
- return href
-
- def handleErrors(self):
- if "The inserted password was wrong" in self.html:
- self.logDebug("Incorrect password, please set right password on 'Edit package' form and retry")
- self.fail("Incorrect password, please set right password on 'Edit package' form and retry")
-
- if self.captcha:
- if "Your choice was wrong" in self.html:
- self.logDebug("Invalid captcha, retrying")
- self.invalidCaptcha()
- self.setWait(5)
- self.wait()
- self.retry()
- else:
- self.correctCaptcha()
-
- def getPackageInfo(self):
- name = folder = None
-
- # Extract from web package header
- title_re = r'<h2><img.*?/>(.*)</h2>'
- m = re.search(title_re, self.html, re.DOTALL)
- if m is not None:
- title = m.group(1).strip()
- if 'unnamed' not in title:
- name = folder = title
- self.logDebug("Found name [%s] and folder [%s] in package info" % (name, folder))
-
- # Fallback to defaults
- if not name or not folder:
- name = self.package.name
- folder = self.package.folder
- self.logDebug("Package info not found, defaulting to pyfile name [%s] and folder [%s]" % (name, folder))
-
- # Return package info
- return name, folder
-
- def handleWebLinks(self):
- package_links = []
- self.logDebug("Handling Web links")
-
- #@TODO: Gather paginated web links
- pattern = r"javascript:_get\('(.*?)', \d+, ''\)"
- ids = re.findall(pattern, self.html)
- self.logDebug("Decrypting %d Web links" % len(ids))
- for i, ID in enumerate(ids):
- try:
- self.logDebug("Decrypting Web link %d, [%s]" % (i + 1, ID))
- dwLink = self.baseUrl + "/get/lnk/" + ID
- response = self.load(dwLink)
- code = re.search(r'frm/(\d+)', response).group(1)
- fwLink = self.baseUrl + "/get/frm/" + code
- response = self.load(fwLink)
- jscode = re.search(r'<script language="javascript">\s*eval\((.*)\)\s*</script>', response,
- re.DOTALL).group(1)
- jscode = self.js.eval("f = %s" % jscode)
- jslauncher = "window=''; parent={frames:{Main:{location:{href:''}}},location:''}; %s; parent.frames.Main.location.href"
- dlLink = self.js.eval(jslauncher % jscode)
- self.logDebug("JsEngine returns value [%s] for redirection link" % dlLink)
- package_links.append(dlLink)
- except Exception, detail:
- self.logDebug("Error decrypting Web link [%s], %s" % (ID, detail))
- return package_links
-
- def handleContainers(self):
- package_links = []
- self.logDebug("Handling Container links")
-
- pattern = r"javascript:_get\('(.*?)', 0, '(rsdf|ccf|dlc)'\)"
- containersLinks = re.findall(pattern, self.html)
- self.logDebug("Decrypting %d Container links" % len(containersLinks))
- for containerLink in containersLinks:
- link = "%s/get/%s/%s" % (self.baseUrl, containerLink[1], containerLink[0])
- package_links.append(link)
- return package_links
-
- def handleCNL2(self):
- package_links = []
- self.logDebug("Handling CNL2 links")
-
- if '/lib/cnl2/ClicknLoad.swf' in self.html:
- try:
- (crypted, jk) = self._getCipherParams()
- package_links.extend(self._getLinks(crypted, jk))
- except:
- self.fail("Unable to decrypt CNL2 links")
- return package_links
-
- def _getCipherParams(self):
-
- # Request CNL2
- code = re.search(r'ClicknLoad.swf\?code=(.*?)"', self.html).group(1)
- url = "%s/get/cnl2/%s" % (self.baseUrl, code)
- response = self.load(url)
- params = response.split(";;")
-
- # Get jk
- strlist = list(base64.standard_b64decode(params[1]))
- strlist.reverse()
- jk = ''.join(strlist)
-
- # Get crypted
- strlist = list(base64.standard_b64decode(params[2]))
- strlist.reverse()
- crypted = ''.join(strlist)
-
- # Log and return
- return crypted, jk
-
- def _getLinks(self, crypted, jk):
-
- # Get key
- jreturn = self.js.eval("%s f()" % jk)
- self.logDebug("JsEngine returns value [%s]" % jreturn)
- key = binascii.unhexlify(jreturn)
-
- # Decode crypted
- crypted = base64.standard_b64decode(crypted)
-
- # Decrypt
- Key = key
- IV = key
- obj = AES.new(Key, AES.MODE_CBC, IV)
- text = obj.decrypt(crypted)
-
- # Extract links
- text = text.replace("\x00", "").replace("\r", "")
- links = text.split("\n")
- links = filter(lambda x: x != "", links)
-
- # Log and return
- self.logDebug("Block has %d links" % len(links))
- return links
diff --git a/module/plugins/crypter/ShareRapidComFolder.py b/module/plugins/crypter/ShareRapidComFolder.py
deleted file mode 100644
index 951c09d45..000000000
--- a/module/plugins/crypter/ShareRapidComFolder.py
+++ /dev/null
@@ -1,15 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class ShareRapidComFolder(SimpleCrypter):
- __name__ = "ShareRapidComFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?((share(-?rapid\.(biz|com|cz|info|eu|net|org|pl|sk)|-(central|credit|free|net)\.cz|-ms\.net)|(s-?rapid|rapids)\.(cz|sk))|(e-stahuj|mediatack|premium-rapidshare|rapidshare-premium|qiuck)\.cz|kadzet\.com|stahuj-zdarma\.eu|strelci\.net|universal-share\.com)/(slozka/.+)"
- __version__ = "0.01"
- __description__ = """Share-Rapid.com Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- LINK_PATTERN = r'<td class="soubor"[^>]*><a href="([^"]+)">'
diff --git a/module/plugins/crypter/SpeedLoadOrgFolder.py b/module/plugins/crypter/SpeedLoadOrgFolder.py
deleted file mode 100644
index 7472e28fe..000000000
--- a/module/plugins/crypter/SpeedLoadOrgFolder.py
+++ /dev/null
@@ -1,28 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class SpeedLoadOrgFolder(DeadCrypter):
- __name__ = "SpeedLoadOrgFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?speedload\.org/(\d+~f$|folder/\d+/)"
- __version__ = "0.3"
- __description__ = """Speedload Crypter Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
diff --git a/module/plugins/crypter/StealthTo.py b/module/plugins/crypter/StealthTo.py
deleted file mode 100644
index 45a14f5a2..000000000
--- a/module/plugins/crypter/StealthTo.py
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.Crypter import Crypter
-
-
-class StealthTo(Crypter):
- __name__ = "StealthTo"
- __type__ = "container"
- __pattern__ = r"http://(www\.)?stealth.to/folder/"
- __version__ = "0.1"
- __description__ = """Stealth.to Container Plugin"""
- __author_name__ = ("spoob")
- __author_mail__ = ("spoob@pyload.org")
-
- def __init__(self, parent):
- Crypter.__init__(self, parent)
- self.parent = parent
- self.html = None
-
- def file_exists(self):
- """ returns True or False
- """
- return True
-
- def proceed(self, url, location):
- url = self.parent.url
- self.html = self.req.load(url, cookies=True)
- temp_links = []
- ids = []
- ats = [] # authenticity_token
- inputs = re.findall(r"(<(input|form)[^>]+)", self.html)
- for input in inputs:
- if re.search(r"name=\"authenticity_token\"", input[0]):
- ats.append(re.search(r"value=\"([^\"]+)", input[0]).group(1))
- if re.search(r"name=\"id\"", input[0]):
- ids.append(re.search(r"value=\"([^\"]+)", input[0]).group(1))
-
- for i in range(0, len(ids)):
- self.req.load(url + "/web",
- post={"authenticity_token": ats[i], "id": str(ids[i]), "link": ("download_" + str(ids[i]))},
- cookies=True)
- new_html = self.req.load(url + "/web", post={"authenticity_token": ats[i], "id": str(ids[i]), "link": "1"},
- cookies=True)
- temp_links.append(re.search(r"iframe src=\"(.*)\" frameborder", new_html).group(1))
-
- self.links = temp_links
diff --git a/module/plugins/crypter/TrailerzoneInfo.py b/module/plugins/crypter/TrailerzoneInfo.py
deleted file mode 100644
index cdd84bbc6..000000000
--- a/module/plugins/crypter/TrailerzoneInfo.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class TrailerzoneInfo(DeadCrypter):
- __name__ = "TrailerzoneInfo"
- __type__ = "crypter"
- __pattern__ = r"http://(www\.)?trailerzone.info/.*?"
- __version__ = "0.03"
- __description__ = """TrailerZone.info Crypter Plugin"""
- __author_name__ = ("godofdream")
- __author_mail__ = ("soilfiction@gmail.com")
diff --git a/module/plugins/crypter/TurbobitNetFolder.py b/module/plugins/crypter/TurbobitNetFolder.py
deleted file mode 100644
index e172f8037..000000000
--- a/module/plugins/crypter/TurbobitNetFolder.py
+++ /dev/null
@@ -1,60 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-import math
-import re
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-from module.common.json_layer import json_loads
-
-
-def format_links(fid):
- return 'http://turbobit.net/%s.html' % fid
-
-
-class TurbobitNetFolder(SimpleCrypter):
- __name__ = "TurbobitNetFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:w{3}.)?turbobit\.net/download/folder/(?P<id>\w+)"
- __version__ = "0.01"
- __description__ = """Turbobit.net Folder Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- TITLE_PATTERN = r"<img src='/js/lib/grid/icon/folder.png'>(?P<title>.+)</div>"
-
- def getLinks(self):
- folder_id = re.search(self.__pattern__, self.pyfile.url).group('id')
- grid = self.load('http://turbobit.net/downloadfolder/gridFile',
- get={'id_folder': folder_id, 'rows': 200}, decode=True)
- grid = json_loads(grid)
-
- links_count = grid["records"]
- pages = int(math.ceil(links_count / 200.0))
-
- ids = list()
- for i in grid['rows']:
- ids.append(i['id'])
-
- for p in range(2, pages + 1):
- grid = self.load('http://turbobit.net/downloadfolder/gridFile',
- get={'id_folder': folder_id, 'rows': 200, 'page': p}, decode=True)
- grid = json_loads(grid)
- for i in grid['rows']:
- ids.append(i['id'])
-
- return map(format_links, ids)
diff --git a/module/plugins/crypter/UlozToFolder.py b/module/plugins/crypter/UlozToFolder.py
deleted file mode 100644
index a5ccfc753..000000000
--- a/module/plugins/crypter/UlozToFolder.py
+++ /dev/null
@@ -1,42 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-from module.plugins.Crypter import Crypter
-
-
-class UlozToFolder(Crypter):
- __name__ = "UlozToFolder"
- __type__ = "crypter"
- __pattern__ = r"http://.*(uloz\.to|ulozto\.(cz|sk|net)|bagruj.cz|zachowajto.pl)/(m|soubory)/.*"
- __version__ = "0.2"
- __description__ = """Uloz.to Folder Plugin"""
- __author_name__ = ("zoidberg")
- __author_mail__ = ("zoidberg@mujmail.cz")
-
- FOLDER_PATTERN = r'<ul class="profile_files">(.*?)</ul>'
- LINK_PATTERN = r'<br /><a href="/([^"]+)">[^<]+</a>'
- NEXT_PAGE_PATTERN = r'<a class="next " href="/([^"]+)">&nbsp;</a>'
-
- def decrypt(self, pyfile):
- html = self.load(self.pyfile.url)
-
- new_links = []
- for i in range(1, 100):
- self.logInfo("Fetching links from page %i" % i)
- found = re.search(self.FOLDER_PATTERN, html, re.DOTALL)
- if found is None:
- self.fail("Parse error (FOLDER)")
-
- new_links.extend(re.findall(self.LINK_PATTERN, found.group(1)))
- found = re.search(self.NEXT_PAGE_PATTERN, html)
- if found:
- html = self.load("http://ulozto.net/" + found.group(1))
- else:
- break
- else:
- self.logInfo("Limit of 99 pages reached, aborting")
-
- if new_links:
- self.core.files.addLinks(map(lambda s: "http://ulozto.net/%s" % s, new_links), self.pyfile.package().id)
- else:
- self.fail('Could not extract any links')
diff --git a/module/plugins/crypter/UploadedToFolder.py b/module/plugins/crypter/UploadedToFolder.py
deleted file mode 100644
index 88d4e04e8..000000000
--- a/module/plugins/crypter/UploadedToFolder.py
+++ /dev/null
@@ -1,50 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 of the #
-# License, or (at your option) any later version. #
-# #
-# 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 #
-# GNU Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-import re
-
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
-
-
-class UploadedToFolder(SimpleCrypter):
- __name__ = "UploadedToFolder"
- __type__ = "crypter"
- __pattern__ = r"http://(?:www\.)?(uploaded|ul)\.(to|net)/(f|folder|list)/(?P<id>\w+)"
- __version__ = "0.3"
- __description__ = """UploadedTo Crypter Plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- PLAIN_PATTERN = r'<small class="date"><a href="(?P<plain>[\w/]+)" onclick='
- TITLE_PATTERN = r'<title>(?P<title>[^<]+)</title>'
-
- def decrypt(self, pyfile):
- self.html = self.load(pyfile.url)
-
- package_name, folder_name = self.getPackageNameAndFolder()
-
- m = re.search(self.PLAIN_PATTERN, self.html)
- if m:
- plain_link = 'http://uploaded.net/' + m.group('plain')
- else:
- self.fail('Parse error - Unable to find plain url list')
-
- self.html = self.load(plain_link)
- package_links = self.html.split('\n')[:-1]
- self.logDebug('Package has %d links' % len(package_links))
-
- self.packages = [(package_name, package_links, folder_name)]
diff --git a/module/plugins/crypter/WiiReloadedOrg.py b/module/plugins/crypter/WiiReloadedOrg.py
deleted file mode 100644
index df70c5aea..000000000
--- a/module/plugins/crypter/WiiReloadedOrg.py
+++ /dev/null
@@ -1,13 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.plugins.internal.DeadCrypter import DeadCrypter
-
-
-class WiiReloadedOrg(DeadCrypter):
- __name__ = "WiiReloadedOrg"
- __type__ = "crypter"
- __pattern__ = r"http://www\.wii-reloaded\.org/protect/get\.php\?i=.+"
- __version__ = "0.11"
- __description__ = """Wii-Reloaded.org Crypter Plugin"""
- __author_name__ = ("hzpz")
- __author_mail__ = ("none")
diff --git a/module/plugins/crypter/XupPl.py b/module/plugins/crypter/XupPl.py
deleted file mode 100644
index 09832f037..000000000
--- a/module/plugins/crypter/XupPl.py
+++ /dev/null
@@ -1,18 +0,0 @@
-from module.plugins.Crypter import Crypter
-
-
-class XupPl(Crypter):
- __name__ = "XupPl"
- __type__ = "crypter"
- __pattern__ = r"https?://.*\.xup\.pl/.*"
- __version__ = "0.1"
- __description__ = """Xup.pl Crypter Plugin"""
- __author_name__ = ("z00nx")
- __author_mail__ = ("z00nx0@gmail.com")
-
- def decrypt(self, pyfile):
- header = self.load(self.pyfile.url, just_header=True)
- if 'location' in header:
- self.core.files.addLinks([header['location']], self.pyfile.package().id)
- else:
- self.fail('Unable to find link')
diff --git a/module/plugins/crypter/YoutubeBatch.py b/module/plugins/crypter/YoutubeBatch.py
deleted file mode 100644
index b6178448d..000000000
--- a/module/plugins/crypter/YoutubeBatch.py
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-import re
-import json
-
-from module.plugins.Crypter import Crypter
-
-API_KEY = "AIzaSyCKnWLNlkX-L4oD1aEzqqhRw1zczeD6_k0"
-
-
-class YoutubeBatch(Crypter):
- __name__ = "YoutubeBatch"
- __type__ = "container"
- __pattern__ = r"https?://(?:[^/]*?)youtube\.com/(?:(?:view_play_list|playlist|.*?feature=PlayList).*?[?&](?:list|p)=)([a-zA-Z0-9-_]+)"
- __version__ = "0.93"
- __description__ = """Youtube.com Channel Download Plugin"""
- __author_name__ = ("RaNaN", "Spoob", "zoidberg", "roland")
- __author_mail__ = ("RaNaN@pyload.org", "spoob@pyload.org", "zoidberg@mujmail.cz", "roland@enkore.de")
-
- def get_videos(self, playlist_id, token=None):
- url = "https://www.googleapis.com/youtube/v3/playlistItems?playlistId=%s&part=snippet&key=%s&maxResults=50" % (
- playlist_id, API_KEY)
- if token:
- url += "&pageToken=" + token
-
- response = json.loads(self.load(url))
-
- for item in response["items"]:
- if item["kind"] == "youtube#playlistItem" and item["snippet"]["resourceId"]["kind"] == "youtube#video":
- yield "http://youtube.com/watch?v=" + item["snippet"]["resourceId"]["videoId"]
-
- if "nextPageToken" in response:
- for item in self.get_videos(playlist_id, response["nextPageToken"]):
- yield item
-
- def decrypt(self, pyfile):
- match_id = re.match(self.__pattern__, self.pyfile.url)
- new_links = []
- playlist_id = match_id.group(1)
-
- new_links.extend(self.get_videos(playlist_id))
-
- self.packages.append((self.pyfile.package().name, new_links, self.pyfile.package().name))
diff --git a/module/plugins/crypter/__init__.py b/module/plugins/crypter/__init__.py
deleted file mode 100644
index e69de29bb..000000000
--- a/module/plugins/crypter/__init__.py
+++ /dev/null