From bf1ee80cb0905587fba0c320036b0082dfd13b3e Mon Sep 17 00:00:00 2001 From: z00nx Date: Fri, 11 Jan 2013 07:48:46 +1100 Subject: Initial CatShareNet plugin --- module/plugins/hoster/CatShareNet.py | 39 ++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 module/plugins/hoster/CatShareNet.py (limited to 'module') diff --git a/module/plugins/hoster/CatShareNet.py b/module/plugins/hoster/CatShareNet.py new file mode 100644 index 000000000..ef77071a3 --- /dev/null +++ b/module/plugins/hoster/CatShareNet.py @@ -0,0 +1,39 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +import re +from module.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo +from module.plugins.ReCaptcha import ReCaptcha + + +class CatShareNet(SimpleHoster): + __name__ = "CatShareNet" + __type__ = "hoster" + __pattern__ = r"http://(www\.)?catshare.net/\w{16}.*" + __version__ = "0.01" + __description__ = """CatShare.net Download Hoster""" + __author_name__ = ("z00nx") + __author_mail__ = ("z00nx0@gmail.com") + + FILE_INFO_PATTERN = r'

]+>(?P.*)

\s+

]+>(?P.*)

' + FILE_OFFLINE_PATTERN = r'Podany plik został usunięty' + SECONDS_PATTERN = 'var\s+count\s+=\s+(\d+);' + RECAPTCHA_KEY = "6Lfln9kSAAAAANZ9JtHSOgxUPB9qfDFeLUI_QMEy" + + def handleFree(self): + self.logDebug(self.pyfile.url) + found = re.search(self.SECONDS_PATTERN, self.html) + seconds = int(found.group(1)) + self.logDebug("Seconds found", seconds) + self.setWait(seconds + 1) + self.wait() + recaptcha = ReCaptcha(self) + challenge, code = recaptcha.challenge(self.RECAPTCHA_KEY) + post_data = {"recaptcha_challenge_field": challenge, "recaptcha_response_field": code} + self.download(self.pyfile.url, post=post_data) + check = self.checkDownload({"html": re.compile("\A Date: Fri, 11 Jan 2013 13:51:27 +1100 Subject: Remove unneeded debugging --- module/plugins/hoster/CatShareNet.py | 1 - 1 file changed, 1 deletion(-) (limited to 'module') diff --git a/module/plugins/hoster/CatShareNet.py b/module/plugins/hoster/CatShareNet.py index ef77071a3..431ced356 100644 --- a/module/plugins/hoster/CatShareNet.py +++ b/module/plugins/hoster/CatShareNet.py @@ -20,7 +20,6 @@ class CatShareNet(SimpleHoster): RECAPTCHA_KEY = "6Lfln9kSAAAAANZ9JtHSOgxUPB9qfDFeLUI_QMEy" def handleFree(self): - self.logDebug(self.pyfile.url) found = re.search(self.SECONDS_PATTERN, self.html) seconds = int(found.group(1)) self.logDebug("Seconds found", seconds) -- cgit v1.2.3 From 38611d80d6c1cb23d04c6fa4150d984597a2f339 Mon Sep 17 00:00:00 2001 From: z00nx Date: Fri, 11 Jan 2013 16:57:03 +1100 Subject: Fixed offline regex --- module/plugins/hoster/CatShareNet.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module') diff --git a/module/plugins/hoster/CatShareNet.py b/module/plugins/hoster/CatShareNet.py index 431ced356..47063096e 100644 --- a/module/plugins/hoster/CatShareNet.py +++ b/module/plugins/hoster/CatShareNet.py @@ -15,7 +15,7 @@ class CatShareNet(SimpleHoster): __author_mail__ = ("z00nx0@gmail.com") FILE_INFO_PATTERN = r'

]+>(?P.*)

\s+

]+>(?P.*)

' - FILE_OFFLINE_PATTERN = r'Podany plik został usunięty' + FILE_OFFLINE_PATTERN = r'Podany plik zosta' SECONDS_PATTERN = 'var\s+count\s+=\s+(\d+);' RECAPTCHA_KEY = "6Lfln9kSAAAAANZ9JtHSOgxUPB9qfDFeLUI_QMEy" -- cgit v1.2.3 From 2e205cef74305413e438d514cc675c0d96d46751 Mon Sep 17 00:00:00 2001 From: z00nx Date: Fri, 11 Jan 2013 17:22:08 +1100 Subject: Added BSecureUploadEu plugin --- module/plugins/hoster/SecureUploadEu.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 module/plugins/hoster/SecureUploadEu.py (limited to 'module') diff --git a/module/plugins/hoster/SecureUploadEu.py b/module/plugins/hoster/SecureUploadEu.py new file mode 100644 index 000000000..b9a900d96 --- /dev/null +++ b/module/plugins/hoster/SecureUploadEu.py @@ -0,0 +1,18 @@ +# -*- coding: utf-8 -*- +from module.plugins.hoster.XFileSharingPro import XFileSharingPro, create_getInfo + + +class SecureUploadEu(XFileSharingPro): + __name__ = "SecureUploadEu" + __type__ = "hoster" + __pattern__ = r"http://(www\.)?secureupload\.eu/(\w){12}(/\w+)" + __version__ = "0.01" + __description__ = """SecureUpload.eu hoster plugin""" + __author_name__ = ("z00nx") + __author_mail__ = ("z00nx0@gmail.com") + + HOSTER_NAME = "secureupload.eu" + FILE_INFO_PATTERN = '

Downloading (?P[^<]+) \((?P[^<]+)\)

' + FILE_OFFLINE_PATTERN = 'The file was removed|File Not Found' + +getInfo = create_getInfo(SecureUploadEu) -- cgit v1.2.3 From 6672e9690f79569f55a2afbb2575d7c671d82812 Mon Sep 17 00:00:00 2001 From: z00nx Date: Fri, 11 Jan 2013 18:56:40 +1100 Subject: Added LetitbitNetFolder decrypter --- module/plugins/crypter/LetitbitNetFolder.py | 33 +++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 module/plugins/crypter/LetitbitNetFolder.py (limited to 'module') diff --git a/module/plugins/crypter/LetitbitNetFolder.py b/module/plugins/crypter/LetitbitNetFolder.py new file mode 100644 index 000000000..68aad9dd7 --- /dev/null +++ b/module/plugins/crypter/LetitbitNetFolder.py @@ -0,0 +1,33 @@ +# -*- 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'(.*)
' + LINK_PATTERN = r'' + + 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') -- cgit v1.2.3 From 61ce00d1945b0d72d2f0323df0c49ef228a96eda Mon Sep 17 00:00:00 2001 From: z00nx Date: Sat, 12 Jan 2013 21:21:48 +1100 Subject: Added IFileWs plugin --- module/plugins/hoster/IFileWs.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 module/plugins/hoster/IFileWs.py (limited to 'module') diff --git a/module/plugins/hoster/IFileWs.py b/module/plugins/hoster/IFileWs.py new file mode 100644 index 000000000..d2f017c4b --- /dev/null +++ b/module/plugins/hoster/IFileWs.py @@ -0,0 +1,21 @@ +# -*- coding: utf-8 -*- +import re +from module.plugins.hoster.XFileSharingPro import XFileSharingPro, create_getInfo +from module.common.json_layer import json_loads +from module.plugins.ReCaptcha import ReCaptcha + + +class IFileWs(XFileSharingPro): + __name__ = "IFileWs" + __type__ = "hoster" + __pattern__ = r"http://(www\.)?ifile\.ws/\w+(/.+)?" + __version__ = "0.01" + __description__ = """Ifile.ws hoster plugin""" + __author_name__ = ("z00nx") + __author_mail__ = ("z00nx0@gmail.com") + + FILE_INFO_PATTERN = '(?P[^<]+)\s+\[(?P[^]]+)\]' + FILE_OFFLINE_PATTERN = 'File Not Found|The file was removed by administrator' + HOSTER_NAME = "ifile.ws" + +getInfo = create_getInfo(IFileWs) -- cgit v1.2.3 From 18239f374b085202837788dc4b74e0a9d0f50cdb Mon Sep 17 00:00:00 2001 From: z00nx Date: Tue, 15 Jan 2013 21:15:42 +1100 Subject: Removed unneeded imported modules, added todo list --- module/plugins/hoster/IFileWs.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'module') diff --git a/module/plugins/hoster/IFileWs.py b/module/plugins/hoster/IFileWs.py index d2f017c4b..038e9f174 100644 --- a/module/plugins/hoster/IFileWs.py +++ b/module/plugins/hoster/IFileWs.py @@ -1,8 +1,5 @@ # -*- coding: utf-8 -*- -import re from module.plugins.hoster.XFileSharingPro import XFileSharingPro, create_getInfo -from module.common.json_layer import json_loads -from module.plugins.ReCaptcha import ReCaptcha class IFileWs(XFileSharingPro): @@ -17,5 +14,7 @@ class IFileWs(XFileSharingPro): FILE_INFO_PATTERN = '(?P[^<]+)\s+\[(?P[^]]+)\]' FILE_OFFLINE_PATTERN = 'File Not Found|The file was removed by administrator' HOSTER_NAME = "ifile.ws" + #TODO: fix Form not found/Download link not found + getInfo = create_getInfo(IFileWs) -- cgit v1.2.3 From 9fa332dd228c62f572939e5dc0c92125a798bdb6 Mon Sep 17 00:00:00 2001 From: z00nx Date: Wed, 16 Jan 2013 19:27:51 +1100 Subject: Added LONG_WAIT_PATTERN regex --- module/plugins/hoster/IFileWs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module') diff --git a/module/plugins/hoster/IFileWs.py b/module/plugins/hoster/IFileWs.py index 038e9f174..160fe641c 100644 --- a/module/plugins/hoster/IFileWs.py +++ b/module/plugins/hoster/IFileWs.py @@ -14,7 +14,7 @@ class IFileWs(XFileSharingPro): FILE_INFO_PATTERN = '(?P[^<]+)\s+\[(?P[^]]+)\]' FILE_OFFLINE_PATTERN = 'File Not Found|The file was removed by administrator' HOSTER_NAME = "ifile.ws" - #TODO: fix Form not found/Download link not found + LONG_WAIT_PATTERN = "(?P\d(?=\s+minutes)).*(?P\d+(?=\s+seconds))" getInfo = create_getInfo(IFileWs) -- cgit v1.2.3