From 049298dbdbff33918454b03a3b072f418d47af97 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 6 Jun 2015 05:33:38 +0200 Subject: Use SSL when login account --- module/plugins/accounts/AlldebridCom.py | 4 ++-- module/plugins/accounts/BitshareCom.py | 2 +- module/plugins/accounts/CatShareNet.py | 2 +- module/plugins/accounts/CloudzillaTo.py | 2 +- module/plugins/accounts/DebridItaliaCom.py | 2 +- module/plugins/accounts/FastixRu.py | 2 +- module/plugins/accounts/FastshareCz.py | 2 +- module/plugins/accounts/FilefactoryCom.py | 2 +- module/plugins/accounts/FilesMailRu.py | 2 +- module/plugins/accounts/FourSharedCom.py | 2 +- module/plugins/accounts/FreakshareCom.py | 2 +- module/plugins/accounts/HellshareCz.py | 2 +- module/plugins/accounts/Keep2ShareCc.py | 2 +- module/plugins/accounts/LinksnappyCom.py | 2 +- module/plugins/accounts/MegaRapidCz.py | 2 +- module/plugins/accounts/MultishareCz.py | 2 +- module/plugins/accounts/MyfastfileCom.py | 2 +- module/plugins/accounts/OverLoadMe.py | 6 ++---- module/plugins/accounts/PremiumTo.py | 4 ++-- module/plugins/accounts/RehostTo.py | 4 ++-- module/plugins/accounts/SimplyPremiumCom.py | 2 +- module/plugins/accounts/SimplydebridCom.py | 2 +- module/plugins/accounts/UlozTo.py | 2 +- module/plugins/accounts/UploadedTo.py | 2 +- module/plugins/accounts/UploadingCom.py | 2 +- module/plugins/accounts/YibaishiwuCom.py | 2 +- 26 files changed, 30 insertions(+), 32 deletions(-) (limited to 'module') diff --git a/module/plugins/accounts/AlldebridCom.py b/module/plugins/accounts/AlldebridCom.py index d09086907..2d42b9c5c 100644 --- a/module/plugins/accounts/AlldebridCom.py +++ b/module/plugins/accounts/AlldebridCom.py @@ -38,7 +38,7 @@ class AlldebridCom(Account): #Get expiration date from API except Exception: data = self.getAccountData(user) - html = req.load("http://www.alldebrid.com/api.php", + html = req.load("https://www.alldebrid.com/api.php", get={'action': "info_user", 'login': user, 'pw': data['password']}) self.logDebug(html) @@ -51,7 +51,7 @@ class AlldebridCom(Account): def login(self, user, data, req): - html = req.load("http://www.alldebrid.com/register/", + html = req.load("https://www.alldebrid.com/register/", get={'action' : "login", 'login_login' : user, 'login_password': data['password']}, diff --git a/module/plugins/accounts/BitshareCom.py b/module/plugins/accounts/BitshareCom.py index 00e546f6d..28c5959fd 100644 --- a/module/plugins/accounts/BitshareCom.py +++ b/module/plugins/accounts/BitshareCom.py @@ -26,7 +26,7 @@ class BitshareCom(Account): def login(self, user, data, req): - html = req.load("http://bitshare.com/login.html", + html = req.load("https://bitshare.com/login.html", post={"user": user, "password": data['password'], "submit": "Login"}, decode=True) diff --git a/module/plugins/accounts/CatShareNet.py b/module/plugins/accounts/CatShareNet.py index 3ddadca8e..aa8be6854 100644 --- a/module/plugins/accounts/CatShareNet.py +++ b/module/plugins/accounts/CatShareNet.py @@ -50,7 +50,7 @@ class CatShareNet(Account): def login(self, user, data, req): - html = req.load("http://catshare.net/login", + html = req.load("https://catshare.net/login", post={'user_email': user, 'user_password': data['password'], 'remindPassword': 0, diff --git a/module/plugins/accounts/CloudzillaTo.py b/module/plugins/accounts/CloudzillaTo.py index d22d5e4b3..42702bcbc 100644 --- a/module/plugins/accounts/CloudzillaTo.py +++ b/module/plugins/accounts/CloudzillaTo.py @@ -27,7 +27,7 @@ class CloudzillaTo(Account): def login(self, user, data, req): - html = req.load("http://www.cloudzilla.to/", + html = req.load("https://www.cloudzilla.to/", post={'lusername': user, 'lpassword': data['password'], 'w' : "dologin"}, diff --git a/module/plugins/accounts/DebridItaliaCom.py b/module/plugins/accounts/DebridItaliaCom.py index 3df99101a..a375b3084 100644 --- a/module/plugins/accounts/DebridItaliaCom.py +++ b/module/plugins/accounts/DebridItaliaCom.py @@ -36,7 +36,7 @@ class DebridItaliaCom(Account): def login(self, user, data, req): - html = req.load("http://debriditalia.com/login.php", + html = req.load("https://debriditalia.com/login.php", get={'u': user, 'p': data['password']}, decode=True) diff --git a/module/plugins/accounts/FastixRu.py b/module/plugins/accounts/FastixRu.py index 51be3880f..0e5b28309 100644 --- a/module/plugins/accounts/FastixRu.py +++ b/module/plugins/accounts/FastixRu.py @@ -29,7 +29,7 @@ class FastixRu(Account): def login(self, user, data, req): - html = req.load("http://fastix.ru/api_v2/", + html = req.load("https://fastix.ru/api_v2/", get={'sub': "get_apikey", 'email': user, 'password': data['password']}) api = json_loads(html) diff --git a/module/plugins/accounts/FastshareCz.py b/module/plugins/accounts/FastshareCz.py index b946e29ba..7b28f38e9 100644 --- a/module/plugins/accounts/FastshareCz.py +++ b/module/plugins/accounts/FastshareCz.py @@ -42,7 +42,7 @@ class FastshareCz(Account): req.load('http://www.fastshare.cz/login') # Do not remove or it will not login - html = req.load("http://www.fastshare.cz/sql.php", + html = req.load("https://www.fastshare.cz/sql.php", post={'login': user, 'heslo': data['password']}, decode=True) diff --git a/module/plugins/accounts/FilefactoryCom.py b/module/plugins/accounts/FilefactoryCom.py index 37b6f97a8..6ef73e183 100644 --- a/module/plugins/accounts/FilefactoryCom.py +++ b/module/plugins/accounts/FilefactoryCom.py @@ -39,7 +39,7 @@ class FilefactoryCom(Account): def login(self, user, data, req): req.http.c.setopt(pycurl.REFERER, "http://www.filefactory.com/member/login.php") - html = req.load("http://www.filefactory.com/member/signin.php", + html = req.load("https://www.filefactory.com/member/signin.php", post={"loginEmail" : user, "loginPassword": data['password'], "Submit" : "Sign In"}) diff --git a/module/plugins/accounts/FilesMailRu.py b/module/plugins/accounts/FilesMailRu.py index ee309c425..707218548 100644 --- a/module/plugins/accounts/FilesMailRu.py +++ b/module/plugins/accounts/FilesMailRu.py @@ -20,7 +20,7 @@ class FilesMailRu(Account): def login(self, user, data, req): user, domain = user.split("@") - html = req.load("http://swa.mail.ru/cgi-bin/auth", + html = req.load("https://swa.mail.ru/cgi-bin/auth", post={"Domain": domain, "Login": user, "Password": data['password'], diff --git a/module/plugins/accounts/FourSharedCom.py b/module/plugins/accounts/FourSharedCom.py index 2777a142a..3976b897c 100644 --- a/module/plugins/accounts/FourSharedCom.py +++ b/module/plugins/accounts/FourSharedCom.py @@ -22,7 +22,7 @@ class FourSharedCom(Account): def login(self, user, data, req): req.cj.setCookie("4shared.com", "4langcookie", "en") - res = req.load("http://www.4shared.com/web/login", + res = req.load("https://www.4shared.com/web/login", post={'login' : user, 'password' : data['password'], 'remember' : "on", diff --git a/module/plugins/accounts/FreakshareCom.py b/module/plugins/accounts/FreakshareCom.py index ca3602a2c..19f159e3f 100644 --- a/module/plugins/accounts/FreakshareCom.py +++ b/module/plugins/accounts/FreakshareCom.py @@ -43,7 +43,7 @@ class FreakshareCom(Account): def login(self, user, data, req): req.load("http://freakshare.com/index.php?language=EN") - html = req.load("http://freakshare.com/login.html", + html = req.load("https://freakshare.com/login.html", post={"submit": "Login", "user": user, "pass": data['password']}, decode=True) diff --git a/module/plugins/accounts/HellshareCz.py b/module/plugins/accounts/HellshareCz.py index e559b28e1..f9feac38f 100644 --- a/module/plugins/accounts/HellshareCz.py +++ b/module/plugins/accounts/HellshareCz.py @@ -68,7 +68,7 @@ class HellshareCz(Account): self.logDebug("Already logged in") return - html = req.load('http://www.hellshare.com/login?do=loginForm-submit', + html = req.load('https://www.hellshare.com/login?do=loginForm-submit', post={"login": "Log in", "password": data['password'], "username": user, diff --git a/module/plugins/accounts/Keep2ShareCc.py b/module/plugins/accounts/Keep2ShareCc.py index d2ba1d237..1d70586a5 100644 --- a/module/plugins/accounts/Keep2ShareCc.py +++ b/module/plugins/accounts/Keep2ShareCc.py @@ -62,7 +62,7 @@ class Keep2ShareCc(Account): def login(self, user, data, req): req.cj.setCookie("keep2share.cc", "lang", "en") - html = req.load("http://keep2share.cc/login.html", + html = req.load("https://keep2share.cc/login.html", post={'LoginForm[username]' : user, 'LoginForm[password]' : data['password'], 'LoginForm[rememberMe]': 1, diff --git a/module/plugins/accounts/LinksnappyCom.py b/module/plugins/accounts/LinksnappyCom.py index 34571d374..e96a9e64f 100644 --- a/module/plugins/accounts/LinksnappyCom.py +++ b/module/plugins/accounts/LinksnappyCom.py @@ -47,7 +47,7 @@ class LinksnappyCom(Account): def login(self, user, data, req): - r = req.load("http://gen.linksnappy.com/lseAPI.php", + r = req.load("https://gen.linksnappy.com/lseAPI.php", get={'act' : 'USERDETAILS', 'username': user, 'password': hashlib.md5(data['password']).hexdigest()}, diff --git a/module/plugins/accounts/MegaRapidCz.py b/module/plugins/accounts/MegaRapidCz.py index 262d5a818..972cc0113 100644 --- a/module/plugins/accounts/MegaRapidCz.py +++ b/module/plugins/accounts/MegaRapidCz.py @@ -52,7 +52,7 @@ class MegaRapidCz(Account): start = html.index('id="inp_hash" name="hash" value="') html = html[start + 33:] hashes = html[0:32] - html = req.load("http://megarapid.cz/prihlaseni/", + html = req.load("https://megarapid.cz/prihlaseni/", post={"hash": hashes, "login": user, "pass1": data['password'], diff --git a/module/plugins/accounts/MultishareCz.py b/module/plugins/accounts/MultishareCz.py index 3488e3288..8e77a6f32 100644 --- a/module/plugins/accounts/MultishareCz.py +++ b/module/plugins/accounts/MultishareCz.py @@ -34,7 +34,7 @@ class MultishareCz(Account): def login(self, user, data, req): - html = req.load('http://www.multishare.cz/html/prihlaseni_process.php', + html = req.load('https://www.multishare.cz/html/prihlaseni_process.php', post={"akce" : "Přihlásit", "heslo": data['password'], "jmeno": user}, diff --git a/module/plugins/accounts/MyfastfileCom.py b/module/plugins/accounts/MyfastfileCom.py index 9a13e2e42..0c1885316 100644 --- a/module/plugins/accounts/MyfastfileCom.py +++ b/module/plugins/accounts/MyfastfileCom.py @@ -26,7 +26,7 @@ class MyfastfileCom(Account): def login(self, user, data, req): # Password to use is the API-Password written in http://myfastfile.com/myaccount - html = req.load("http://myfastfile.com/api.php", + html = req.load("https://myfastfile.com/api.php", get={"user": user, "pass": data['password']}) self.logDebug("JSON data: " + html) diff --git a/module/plugins/accounts/OverLoadMe.py b/module/plugins/accounts/OverLoadMe.py index 64d04aded..702637d3f 100644 --- a/module/plugins/accounts/OverLoadMe.py +++ b/module/plugins/accounts/OverLoadMe.py @@ -15,9 +15,8 @@ class OverLoadMe(Account): def loadAccountInfo(self, user, req): - https = "https" if self.getConfig('ssl') else "http" data = self.getAccountData(user) - html = req.load(https + "://api.over-load.me/account.php", + html = req.load("https://api.over-load.me/account.php", get={'user': user, 'auth': data['password']}).strip() @@ -32,8 +31,7 @@ class OverLoadMe(Account): def login(self, user, data, req): - https = "https" if self.getConfig('ssl') else "http" - jsondata = req.load(https + "://api.over-load.me/account.php", + jsondata = req.load("https://api.over-load.me/account.php", get={'user': user, 'auth': data['password']}).strip() diff --git a/module/plugins/accounts/PremiumTo.py b/module/plugins/accounts/PremiumTo.py index c8ea2fa26..c5c758ccf 100644 --- a/module/plugins/accounts/PremiumTo.py +++ b/module/plugins/accounts/PremiumTo.py @@ -16,7 +16,7 @@ class PremiumTo(Account): def loadAccountInfo(self, user, req): - traffic = req.load("http://premium.to/api/straffic.php", + traffic = req.load("https://premium.to/api/straffic.php", get={'username': self.username, 'password': self.password}) if "wrong username" not in traffic: @@ -29,7 +29,7 @@ class PremiumTo(Account): def login(self, user, data, req): self.username = user self.password = data['password'] - authcode = req.load("http://premium.to/api/getauthcode.php", + authcode = req.load("https://premium.to/api/getauthcode.php", get={'username': user, 'password': self.password}, decode=True) diff --git a/module/plugins/accounts/RehostTo.py b/module/plugins/accounts/RehostTo.py index 04e71c9ad..e8173d75b 100644 --- a/module/plugins/accounts/RehostTo.py +++ b/module/plugins/accounts/RehostTo.py @@ -19,7 +19,7 @@ class RehostTo(Account): validuntil = -1 session = "" - html = req.load("http://rehost.to/api.php", + html = req.load("https://rehost.to/api.php", get={'cmd' : "login", 'user': user, 'pass': self.getAccountData(user)['password']}) try: @@ -45,7 +45,7 @@ class RehostTo(Account): def login(self, user, data, req): - html = req.load("http://rehost.to/api.php", + html = req.load("https://rehost.to/api.php", get={'cmd': "login", 'user': user, 'pass': data['password']}, decode=True) diff --git a/module/plugins/accounts/SimplyPremiumCom.py b/module/plugins/accounts/SimplyPremiumCom.py index 8caf600f9..fb3eb2163 100644 --- a/module/plugins/accounts/SimplyPremiumCom.py +++ b/module/plugins/accounts/SimplyPremiumCom.py @@ -40,7 +40,7 @@ class SimplyPremiumCom(Account): def login(self, user, data, req): req.cj.setCookie("simply-premium.com", "lang", "EN") - html = req.load("http://www.simply-premium.com/login.php", + html = req.load("https://www.simply-premium.com/login.php", post={'key': user} if not data['password'] else {'login_name': user, 'login_pass': data['password']}, decode=True) diff --git a/module/plugins/accounts/SimplydebridCom.py b/module/plugins/accounts/SimplydebridCom.py index 24108eb0b..f9e8bab02 100644 --- a/module/plugins/accounts/SimplydebridCom.py +++ b/module/plugins/accounts/SimplydebridCom.py @@ -30,6 +30,6 @@ class SimplydebridCom(Account): self.password = data['password'] get_data = {'login': 1, 'u': self.loginname, 'p': self.password} - res = req.load("http://simply-debrid.com/api.php", get=get_data, decode=True) + res = req.load("https://simply-debrid.com/api.php", get=get_data, decode=True) if res != "02: loggin success": self.wrongPassword() diff --git a/module/plugins/accounts/UlozTo.py b/module/plugins/accounts/UlozTo.py index f95c8834b..d0a1ecedf 100644 --- a/module/plugins/accounts/UlozTo.py +++ b/module/plugins/accounts/UlozTo.py @@ -36,7 +36,7 @@ class UlozTo(Account): action = re.findall('