diff options
Diffstat (limited to 'pyload/plugins/hook')
-rw-r--r-- | pyload/plugins/hook/AlldebridCom.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/Captcha9kw.py | 31 | ||||
-rw-r--r-- | pyload/plugins/hook/DebridItaliaCom.py | 17 | ||||
-rw-r--r-- | pyload/plugins/hook/EasybytezCom.py | 17 | ||||
-rw-r--r-- | pyload/plugins/hook/FastixRu.py | 5 | ||||
-rw-r--r-- | pyload/plugins/hook/FreeWayMe.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/LinksnappyCom.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/MegaDebridEu.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/MyfastfileCom.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/OverLoadMe.py | 3 | ||||
-rw-r--r-- | pyload/plugins/hook/PremiumizeMe.py | 4 | ||||
-rw-r--r-- | pyload/plugins/hook/RPNetBiz.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/RehostTo.py | 3 | ||||
-rw-r--r-- | pyload/plugins/hook/SimplyPremiumCom.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/SimplydebridCom.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/UnrestrictLi.py | 2 | ||||
-rw-r--r-- | pyload/plugins/hook/XFileSharingPro.py | 8 | ||||
-rw-r--r-- | pyload/plugins/hook/ZeveraCom.py | 2 |
18 files changed, 57 insertions, 51 deletions
diff --git a/pyload/plugins/hook/AlldebridCom.py b/pyload/plugins/hook/AlldebridCom.py index 9ed80f101..cf79af917 100644 --- a/pyload/plugins/hook/AlldebridCom.py +++ b/pyload/plugins/hook/AlldebridCom.py @@ -22,6 +22,6 @@ class AlldebridCom(MultiHoster): def getHoster(self): https = "https" if self.getConfig("https") else "http" - page = getURL(https + "://www.alldebrid.com/api.php?action=get_host").replace("\"", "").strip() + page = getURL(https + "://www.alldebrid.com/api.php", get={'action': "get_host"}).replace("\"", "").strip() return [x.strip() for x in page.split(",") if x.strip()] diff --git a/pyload/plugins/hook/Captcha9kw.py b/pyload/plugins/hook/Captcha9kw.py index fa4710542..f01f45011 100644 --- a/pyload/plugins/hook/Captcha9kw.py +++ b/pyload/plugins/hook/Captcha9kw.py @@ -16,18 +16,19 @@ from pyload.plugins.internal.Addon import Hook class Captcha9kw(Hook): __name__ = "Captcha9kw" __type__ = "hook" - __version__ = "0.24" - - __config__ = [("ssl", "bool", "Use HTTPS", True), - ("force", "bool", "Force captcha resolving even if client is connected", True), - ("confirm", "bool", "Confirm Captcha (cost +6 credits)", False), - ("captchaperhour", "int", "Captcha per hour", "9999"), - ("prio", "int", "Priority (max 10)(cost +0 -> +10 credits)", "0"), - ("queue", "int", "Max. Queue (max 999)", "50"), - ("hoster_options", "string", "Hoster options (format: pluginname:prio=1:selfsolfe=1:confirm=1:timeout=900|...)", "ShareonlineBiz:prio=0:timeout=999 | UploadedTo:prio=0:timeout=999"), - ("selfsolve", "bool", "Selfsolve (manually solve your captcha in your 9kw client if active)", "0"), - ("passkey", "password", "API key", ""), - ("timeout", "int", "Timeout in seconds (min 60, max 3999)", "900")] + __version__ = "0.25" + + __config__ = [("ssl" , "bool" , "Use HTTPS" , True ), + ("force" , "bool" , "Force captcha resolving even if client is connected" , True ), + ("confirm" , "bool" , "Confirm Captcha (cost +6 credits)" , False ), + ("captchaperhour", "int" , "Captcha per hour" , "9999" ), + ("captchapermin" , "int" , "Captcha per minute" , "9999" ), + ("prio" , "int" , "Priority (max 10)(cost +0 -> +10 credits)" , "0" ), + ("queue" , "int" , "Max. Queue (max 999)" , "50" ), + ("hoster_options", "string" , "Hoster options (format: pluginname:prio=1:selfsolfe=1:confirm=1:timeout=900|...)", "ShareonlineBiz:prio=0:timeout=999 | UploadedTo:prio=0:timeout=999"), + ("selfsolve" , "bool" , "Selfsolve (manually solve your captcha in your 9kw client if active)" , "0" ), + ("passkey" , "password", "API key" , "" ), + ("timeout" , "int" , "Timeout in seconds (min 60, max 3999)" , "900" )] __description__ = """Send captchas to 9kw.eu""" __license__ = "GPLv3" @@ -52,7 +53,7 @@ class Captcha9kw(Hook): if res.isdigit(): self.logInfo(_("%s credits left") % res) - credits = self.info["credits"] = int(res) + credits = self.info['credits'] = int(res) return credits else: self.logError(res) @@ -82,7 +83,8 @@ class Captcha9kw(Hook): 'confirm' : self.getConfig("confirm"), 'timeout' : min(max(self.getConfig("timeout"), 300), 3999), 'selfsolve' : self.getConfig("selfsolve"), - 'cph' : self.getConfig("captchaperhour")} + 'cph' : self.getConfig("captchaperhour"), + 'cpm' : self.getConfig("captchapermin")} for opt in str(self.getConfig("hoster_options").split('|')): @@ -109,6 +111,7 @@ class Captcha9kw(Hook): 'maxtimeout' : option['timeout'], 'selfsolve' : option['selfsolve'], 'captchaperhour': option['cph'], + 'captchapermin' : option['cpm'], 'case-sensitive': option['case_sensitive'], 'min_len' : option['min'], 'max_len' : option['max'], diff --git a/pyload/plugins/hook/DebridItaliaCom.py b/pyload/plugins/hook/DebridItaliaCom.py index 9c8f866f0..01e085ad2 100644 --- a/pyload/plugins/hook/DebridItaliaCom.py +++ b/pyload/plugins/hook/DebridItaliaCom.py @@ -1,12 +1,15 @@ # -*- coding: utf-8 -*- +import re + +from pyload.network.RequestFactory import getURL from pyload.plugins.internal.MultiHoster import MultiHoster class DebridItaliaCom(MultiHoster): __name__ = "DebridItaliaCom" __type__ = "hook" - __version__ = "0.07" + __version__ = "0.08" __config__ = [("hosterListMode", "all;listed;unlisted", "Use for hosters (if supported)", "all"), ("hosterList", "str", "Hoster list (comma separated)", ""), @@ -15,14 +18,10 @@ class DebridItaliaCom(MultiHoster): __description__ = """Debriditalia.com hook plugin""" __license__ = "GPLv3" - __authors__ = [("stickell", "l.stickell@yahoo.it")] + __authors__ = [("stickell", "l.stickell@yahoo.it"), + ("Walter Purcaro", "vuolter@gmail.com")] def getHoster(self): - return ["netload.in", "hotfile.com", "rapidshare.com", "multiupload.com", - "uploading.com", "megashares.com", "crocko.com", "filepost.com", - "bitshare.com", "share-links.biz", "putlocker.com", "uploaded.to", - "speedload.org", "rapidgator.net", "likeupload.net", "cyberlocker.ch", - "depositfiles.com", "extabit.com", "filefactory.com", "sharefiles.co", - "ryushare.com", "tusfiles.net", "nowvideo.co", "cloudzer.net", "letitbit.net", - "easybytez.com", "uptobox.com", "ddlstorage.com"] + html = getURL("http://www.debriditalia.com/status.php") + return re.findall(r'title="(.+?)"> \1</td><td><img src="/images/(?:attivo|testing)', html) diff --git a/pyload/plugins/hook/EasybytezCom.py b/pyload/plugins/hook/EasybytezCom.py index 15033c8e7..9d92b96f7 100644 --- a/pyload/plugins/hook/EasybytezCom.py +++ b/pyload/plugins/hook/EasybytezCom.py @@ -23,14 +23,17 @@ class EasybytezCom(MultiHoster): user = self.account.selectAccount()[0] try: - req = self.account.getAccountRequest(user) + req = self.account.getAccountRequest(user) page = req.load("http://www.easybytez.com") - m = re.search(r'</textarea>\s*Supported sites:(.*)', page) - return m.group(1).split(',') + hosters = re.search(r'</textarea>\s*Supported sites:(.*)', page).group(1).split(',') + except Exception, e: - self.logDebug(e) self.logWarning(_("Unable to load supported hoster list, using last known")) - return ["bitshare.com", "crocko.com", "ddlstorage.com", "depositfiles.com", "extabit.com", "hotfile.com", - "mediafire.com", "netload.in", "rapidgator.net", "rapidshare.com", "uploading.com", "uload.to", - "uploaded.to"] + self.logDebug(e) + + hosters = ["bitshare.com", "crocko.com", "ddlstorage.com", "depositfiles.com", "extabit.com", "hotfile.com", + "mediafire.com", "netload.in", "rapidgator.net", "rapidshare.com", "uploading.com", "uload.to", + "uploaded.to"] + finally: + return hosters diff --git a/pyload/plugins/hook/FastixRu.py b/pyload/plugins/hook/FastixRu.py index a7a5e6b8c..0ae853544 100644 --- a/pyload/plugins/hook/FastixRu.py +++ b/pyload/plugins/hook/FastixRu.py @@ -20,8 +20,9 @@ class FastixRu(MultiHoster): def getHoster(self): - page = getURL( - "http://fastix.ru/api_v2/?apikey=5182964c3f8f9a7f0b00000a_kelmFB4n1IrnCDYuIFn2y&sub=allowed_sources") + page = getURL("http://fastix.ru/api_v2", + get={'apikey': "5182964c3f8f9a7f0b00000a_kelmFB4n1IrnCDYuIFn2y", + 'sub' : "allowed_sources"}) host_list = json_loads(page) host_list = host_list['allow'] return host_list diff --git a/pyload/plugins/hook/FreeWayMe.py b/pyload/plugins/hook/FreeWayMe.py index b9955c90a..5d955e156 100644 --- a/pyload/plugins/hook/FreeWayMe.py +++ b/pyload/plugins/hook/FreeWayMe.py @@ -20,6 +20,6 @@ class FreeWayMe(MultiHoster): def getHoster(self): - hostis = getURL("https://www.free-way.me/ajax/jd.php", get={"id": 3}).replace("\"", "").strip() + hostis = getURL("https://www.free-way.me/ajax/jd.php", get={'id': 3}).replace("\"", "").strip() self.logDebug("Hosters", hostis) return [x.strip() for x in hostis.split(",") if x.strip()] diff --git a/pyload/plugins/hook/LinksnappyCom.py b/pyload/plugins/hook/LinksnappyCom.py index 0957b6a91..381eb6a2a 100644 --- a/pyload/plugins/hook/LinksnappyCom.py +++ b/pyload/plugins/hook/LinksnappyCom.py @@ -21,7 +21,7 @@ class LinksnappyCom(MultiHoster): def getHoster(self): - json_data = getURL('http://gen.linksnappy.com/lseAPI.php?act=FILEHOSTS') + json_data = getURL("http://gen.linksnappy.com/lseAPI.php", get={'act': "FILEHOSTS"}) json_data = json_loads(json_data) return json_data['return'].keys() diff --git a/pyload/plugins/hook/MegaDebridEu.py b/pyload/plugins/hook/MegaDebridEu.py index 6c3e2b03a..5a52dbf41 100644 --- a/pyload/plugins/hook/MegaDebridEu.py +++ b/pyload/plugins/hook/MegaDebridEu.py @@ -18,7 +18,7 @@ class MegaDebridEu(MultiHoster): def getHoster(self): - reponse = getURL('http://www.mega-debrid.eu/api.php?action=getHosters') + reponse = getURL("http://www.mega-debrid.eu/api.php", get={'action': "getHosters"}) json_data = json_loads(reponse) if json_data['response_code'] == "ok": diff --git a/pyload/plugins/hook/MyfastfileCom.py b/pyload/plugins/hook/MyfastfileCom.py index affaa2261..07988d2b9 100644 --- a/pyload/plugins/hook/MyfastfileCom.py +++ b/pyload/plugins/hook/MyfastfileCom.py @@ -23,7 +23,7 @@ class MyfastfileCom(MultiHoster): def getHoster(self): - json_data = getURL('http://myfastfile.com/api.php?hosts', decode=True) + json_data = getURL("http://myfastfile.com/api.php", get={'hosts': ""}, decode=True) self.logDebug("JSON data", json_data) json_data = json_loads(json_data) diff --git a/pyload/plugins/hook/OverLoadMe.py b/pyload/plugins/hook/OverLoadMe.py index 2766165fd..83ce3e842 100644 --- a/pyload/plugins/hook/OverLoadMe.py +++ b/pyload/plugins/hook/OverLoadMe.py @@ -23,8 +23,7 @@ class OverLoadMe(MultiHoster): def getHoster(self): https = "https" if self.getConfig("https") else "http" page = getURL(https + "://api.over-load.me/hoster.php", - get={"auth": "0001-cb1f24dadb3aa487bda5afd3b76298935329be7700cd7-5329be77-00cf-1ca0135f"} - ).replace("\"", "").strip() + get={'auth': "0001-cb1f24dadb3aa487bda5afd3b76298935329be7700cd7-5329be77-00cf-1ca0135f"}).replace("\"", "").strip() self.logDebug("Hosterlist", page) return [x.strip() for x in page.split(",") if x.strip()] diff --git a/pyload/plugins/hook/PremiumizeMe.py b/pyload/plugins/hook/PremiumizeMe.py index a751e7b61..5824115b6 100644 --- a/pyload/plugins/hook/PremiumizeMe.py +++ b/pyload/plugins/hook/PremiumizeMe.py @@ -30,8 +30,8 @@ class PremiumizeMe(MultiHoster): # Get supported hosters list from premiumize.me using the # json API v1 (see https://secure.premiumize.me/?show=api) - answer = getURL("https://api.premiumize.me/pm-api/v1.php?method=hosterlist¶ms[login]=%s¶ms[pass]=%s" % ( - user, data['password'])) + answer = getURL("https://api.premiumize.me/pm-api/v1.php" + get={'method': "hosterlist", 'params[login]': user, 'params[pass]': data['password']}) data = json_loads(answer) # If account is not valid thera are no hosters available diff --git a/pyload/plugins/hook/RPNetBiz.py b/pyload/plugins/hook/RPNetBiz.py index 3bbdcf839..dc3caf39e 100644 --- a/pyload/plugins/hook/RPNetBiz.py +++ b/pyload/plugins/hook/RPNetBiz.py @@ -29,7 +29,7 @@ class RPNetBiz(MultiHoster): (user, data) = self.account.selectAccount() res = getURL("https://premium.rpnet.biz/client_api.php", - get={"username": user, "password": data['password'], "action": "showHosterList"}) + get={'username': user, 'password': data['password'], 'action': "showHosterList"}) hoster_list = json_loads(res) # If account is not valid thera are no hosters available diff --git a/pyload/plugins/hook/RehostTo.py b/pyload/plugins/hook/RehostTo.py index 2c8739869..6c334bf06 100644 --- a/pyload/plugins/hook/RehostTo.py +++ b/pyload/plugins/hook/RehostTo.py @@ -20,7 +20,8 @@ class RehostTo(MultiHoster): def getHoster(self): - page = getURL("http://rehost.to/api.php?cmd=get_supported_och_dl&long_ses=%s" % self.long_ses) + page = getURL("http://rehost.to/api.php", + get={'cmd': "get_supported_och_dl", 'long_ses': self.long_ses}) return [x.strip() for x in page.replace("\"", "").split(",")] diff --git a/pyload/plugins/hook/SimplyPremiumCom.py b/pyload/plugins/hook/SimplyPremiumCom.py index 9945cce38..8c32cbf7a 100644 --- a/pyload/plugins/hook/SimplyPremiumCom.py +++ b/pyload/plugins/hook/SimplyPremiumCom.py @@ -21,7 +21,7 @@ class SimplyPremiumCom(MultiHoster): def getHoster(self): - json_data = getURL('http://www.simply-premium.com/api/hosts.php?format=json&online=1') + json_data = getURL("http://www.simply-premium.com/api/hosts.php", get={'format': "json", 'online': 1}) json_data = json_loads(json_data) host_list = [element['regex'] for element in json_data['result']] diff --git a/pyload/plugins/hook/SimplydebridCom.py b/pyload/plugins/hook/SimplydebridCom.py index 4668da45b..89d8cb752 100644 --- a/pyload/plugins/hook/SimplydebridCom.py +++ b/pyload/plugins/hook/SimplydebridCom.py @@ -18,5 +18,5 @@ class SimplydebridCom(MultiHoster): def getHoster(self): - page = getURL("http://simply-debrid.com/api.php?list=1") + page = getURL("http://simply-debrid.com/api.php", get={'list': 1}) return [x.strip() for x in page.rstrip(';').replace("\"", "").split(";")] diff --git a/pyload/plugins/hook/UnrestrictLi.py b/pyload/plugins/hook/UnrestrictLi.py index cfe580048..255cee43d 100644 --- a/pyload/plugins/hook/UnrestrictLi.py +++ b/pyload/plugins/hook/UnrestrictLi.py @@ -22,7 +22,7 @@ class UnrestrictLi(MultiHoster): def getHoster(self): - json_data = getURL('http://unrestrict.li/api/jdownloader/hosts.php?format=json') + json_data = getURL("http://unrestrict.li/api/jdownloader/hosts.php", get={'format': "json"}) json_data = json_loads(json_data) host_list = [element['host'] for element in json_data['result']] diff --git a/pyload/plugins/hook/XFileSharingPro.py b/pyload/plugins/hook/XFileSharingPro.py index 268e91909..42c4c6264 100644 --- a/pyload/plugins/hook/XFileSharingPro.py +++ b/pyload/plugins/hook/XFileSharingPro.py @@ -8,11 +8,11 @@ from pyload.plugins.internal.Addon import Hook class XFileSharingPro(Hook): __name__ = "XFileSharingPro" __type__ = "hook" - __version__ = "0.24" + __version__ = "0.25" __config__ = [("activated", "bool", "Activated", True), ("use_hoster_list", "bool", "Load listed hosters only", True), - ("use_crypter_list", "bool", "Load listed crypters only", True), + ("use_crypter_list", "bool", "Load listed crypters only", False), ("use_builtin_list", "bool", "Load built-in plugin list", True), ("hoster_list", "str", "Hoster list (comma separated)", ""), ("crypter_list", "str", "Crypter list (comma separated)", "")] @@ -23,9 +23,9 @@ class XFileSharingPro(Hook): # event_list = ["pluginConfigChanged"] - regexp = {'hoster' : (r'https?://(?:www\.)?([\w^_]+(?:\.[a-zA-Z]{2,})+(?:\:\d+)?)/(?:embed-)?\w{12}(?:\W|$)', + regexp = {'hoster' : (r'https?://(?:www\.)?([\w.^_]+(?:\.[a-zA-Z]{2,})(?:\:\d+)?)/(?:embed-)?\w{12}(?:\W|$)', r'https?://(?:[^/]+\.)?(%s)/(?:embed-)?\w+'), - 'crypter': (r'https?://(?:www\.)?([\w^_]+(?:\.[a-zA-Z]{2,})+(?:\:\d+)?)/(?:user|folder)s?/\w+', + 'crypter': (r'https?://(?:www\.)?([\w.^_]+(?:\.[a-zA-Z]{2,})(?:\:\d+)?)/(?:user|folder)s?/\w+', r'https?://(?:[^/]+\.)?(%s)/(?:user|folder)s?/\w+')} HOSTER_LIST = [#WORKING HOSTERS: diff --git a/pyload/plugins/hook/ZeveraCom.py b/pyload/plugins/hook/ZeveraCom.py index 09e3953a2..21fdf6c92 100644 --- a/pyload/plugins/hook/ZeveraCom.py +++ b/pyload/plugins/hook/ZeveraCom.py @@ -18,5 +18,5 @@ class ZeveraCom(MultiHoster): def getHoster(self): - page = getURL("http://www.zevera.com/jDownloader.ashx?cmd=gethosters") + page = getURL("http://www.zevera.com/jDownloader.ashx", get={'cmd': "gethosters"}) return [x.strip() for x in page.replace("\"", "").split(",")] |