From 3ebfa9a6348983437712e9cea22504d38f633588 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 5 Jul 2014 16:34:09 +0200 Subject: [PutlockerCom] Renamed to FiredriveCom --- module/plugins/hoster/FiredriveCom.py | 51 +++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 module/plugins/hoster/FiredriveCom.py (limited to 'module/plugins/hoster/FiredriveCom.py') diff --git a/module/plugins/hoster/FiredriveCom.py b/module/plugins/hoster/FiredriveCom.py new file mode 100644 index 000000000..9c150bc11 --- /dev/null +++ b/module/plugins/hoster/FiredriveCom.py @@ -0,0 +1,51 @@ +# -*- 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 . +############################################################################### + +import re + +from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo + + +class FiredriveCom(SimpleHoster): + __name__ = "FiredriveCom" + __type__ = "hoster" + __pattern__ = r'https?://(?:www\.)?(firedrive|putlocker)\.com/(mobile/)?(file|embed)/(?P\w+)' + __version__ = "0.01" + __description__ = """Firedrive.com hoster plugin""" + __author_name__ = "Walter Purcaro" + __author_mail__ = "vuolter@gmail.com" + + FILE_NAME_PATTERN = r'Name: (?P.+)
' + FILE_SIZE_PATTERN = r'Size: (?P[\d.]+) (?P[a-zA-Z]+)
' + FILE_OFFLINE_PATTERN = r'class="sad_face_image"' + + FILE_URL_REPLACEMENTS = [(__pattern__, r'http://www.firedrive.com/file/\g')] + + def setup(self): + self.multiDL = self.resumeDownload = True + self.chunkLimit = -1 + + def handleFree(self): + link = self._getLink() + self.logDebug("Direct link: " + link) + self.download(link, disposition=True) + + def _getLink(self): + self.html = self.load(self.pyfile.url, post={"confirm": re.search(r'name="confirm" value="(.*)"', self.html).group(1)}) + return re.search(r' Date: Sat, 5 Jul 2014 16:54:20 +0200 Subject: [SimpleHoster] Better inline docs + changed "FILE_OFFLINE_PATTERN" to "OFFLINE_PATTERN" --- module/plugins/hoster/FiredriveCom.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/hoster/FiredriveCom.py') diff --git a/module/plugins/hoster/FiredriveCom.py b/module/plugins/hoster/FiredriveCom.py index 9c150bc11..5c6b4ea0c 100644 --- a/module/plugins/hoster/FiredriveCom.py +++ b/module/plugins/hoster/FiredriveCom.py @@ -30,7 +30,7 @@ class FiredriveCom(SimpleHoster): FILE_NAME_PATTERN = r'Name: (?P.+)
' FILE_SIZE_PATTERN = r'Size: (?P[\d.]+) (?P[a-zA-Z]+)
' - FILE_OFFLINE_PATTERN = r'class="sad_face_image"' + OFFLINE_PATTERN = r'class="sad_face_image"' FILE_URL_REPLACEMENTS = [(__pattern__, r'http://www.firedrive.com/file/\g')] -- cgit v1.2.3 From 9473df4c5b8708da5936fa23c26957da092f4228 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Mon, 7 Jul 2014 18:40:48 +0200 Subject: [FiredriveCom] Fixed download link recognition + added TEMP_OFFLINE_PATTERN --- module/plugins/hoster/FiredriveCom.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'module/plugins/hoster/FiredriveCom.py') diff --git a/module/plugins/hoster/FiredriveCom.py b/module/plugins/hoster/FiredriveCom.py index 5c6b4ea0c..e7bd49674 100644 --- a/module/plugins/hoster/FiredriveCom.py +++ b/module/plugins/hoster/FiredriveCom.py @@ -23,7 +23,7 @@ class FiredriveCom(SimpleHoster): __name__ = "FiredriveCom" __type__ = "hoster" __pattern__ = r'https?://(?:www\.)?(firedrive|putlocker)\.com/(mobile/)?(file|embed)/(?P\w+)' - __version__ = "0.01" + __version__ = "0.02" __description__ = """Firedrive.com hoster plugin""" __author_name__ = "Walter Purcaro" __author_mail__ = "vuolter@gmail.com" @@ -31,6 +31,7 @@ class FiredriveCom(SimpleHoster): FILE_NAME_PATTERN = r'Name: (?P.+)
' FILE_SIZE_PATTERN = r'Size: (?P[\d.]+) (?P[a-zA-Z]+)
' OFFLINE_PATTERN = r'class="sad_face_image"' + TEMP_OFFLINE_PATTERN = r'>(File Temporarily Unavailable|Server Error. Try again later)' FILE_URL_REPLACEMENTS = [(__pattern__, r'http://www.firedrive.com/file/\g')] @@ -44,8 +45,12 @@ class FiredriveCom(SimpleHoster): self.download(link, disposition=True) def _getLink(self): - self.html = self.load(self.pyfile.url, post={"confirm": re.search(r'name="confirm" value="(.*)"', self.html).group(1)}) - return re.search(r'
Date: Mon, 7 Jul 2014 21:08:40 +0200 Subject: New crypter FiredriveComFolder --- module/plugins/hoster/FiredriveCom.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/hoster/FiredriveCom.py') diff --git a/module/plugins/hoster/FiredriveCom.py b/module/plugins/hoster/FiredriveCom.py index e7bd49674..4dce23462 100644 --- a/module/plugins/hoster/FiredriveCom.py +++ b/module/plugins/hoster/FiredriveCom.py @@ -30,7 +30,7 @@ class FiredriveCom(SimpleHoster): FILE_NAME_PATTERN = r'Name: (?P.+)
' FILE_SIZE_PATTERN = r'Size: (?P[\d.]+) (?P[a-zA-Z]+)
' - OFFLINE_PATTERN = r'class="sad_face_image"' + OFFLINE_PATTERN = r'class="sad_face_image"|>No such page here.<' TEMP_OFFLINE_PATTERN = r'>(File Temporarily Unavailable|Server Error. Try again later)' FILE_URL_REPLACEMENTS = [(__pattern__, r'http://www.firedrive.com/file/\g')] -- cgit v1.2.3 From 3e6e2e858cd17439992a45afa2c4e9bf5f2da177 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Wed, 9 Jul 2014 22:16:30 +0200 Subject: [FiredriveCom] Handle parse error --- module/plugins/hoster/FiredriveCom.py | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'module/plugins/hoster/FiredriveCom.py') diff --git a/module/plugins/hoster/FiredriveCom.py b/module/plugins/hoster/FiredriveCom.py index 4dce23462..6a77ded55 100644 --- a/module/plugins/hoster/FiredriveCom.py +++ b/module/plugins/hoster/FiredriveCom.py @@ -23,7 +23,7 @@ class FiredriveCom(SimpleHoster): __name__ = "FiredriveCom" __type__ = "hoster" __pattern__ = r'https?://(?:www\.)?(firedrive|putlocker)\.com/(mobile/)?(file|embed)/(?P\w+)' - __version__ = "0.02" + __version__ = "0.03" __description__ = """Firedrive.com hoster plugin""" __author_name__ = "Walter Purcaro" __author_mail__ = "vuolter@gmail.com" @@ -35,6 +35,9 @@ class FiredriveCom(SimpleHoster): FILE_URL_REPLACEMENTS = [(__pattern__, r'http://www.firedrive.com/file/\g')] + LINK_PATTERN = r'
Date: Fri, 1 Aug 2014 19:35:59 +0200 Subject: Remove trailing whitespaces + remove license headers + import urllib methods directly + sort and fix key attributes + use save_join instead join + sort some import declarations + other minor code cosmetics --- module/plugins/hoster/FiredriveCom.py | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) (limited to 'module/plugins/hoster/FiredriveCom.py') diff --git a/module/plugins/hoster/FiredriveCom.py b/module/plugins/hoster/FiredriveCom.py index 6a77ded55..47c6a4214 100644 --- a/module/plugins/hoster/FiredriveCom.py +++ b/module/plugins/hoster/FiredriveCom.py @@ -1,18 +1,4 @@ # -*- 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 . -############################################################################### import re @@ -22,8 +8,10 @@ from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo class FiredriveCom(SimpleHoster): __name__ = "FiredriveCom" __type__ = "hoster" - __pattern__ = r'https?://(?:www\.)?(firedrive|putlocker)\.com/(mobile/)?(file|embed)/(?P\w+)' __version__ = "0.03" + + __pattern__ = r'https?://(?:www\.)?(firedrive|putlocker)\.com/(mobile/)?(file|embed)/(?P\w+)' + __description__ = """Firedrive.com hoster plugin""" __author_name__ = "Walter Purcaro" __author_mail__ = "vuolter@gmail.com" -- cgit v1.2.3