diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-12-29 11:44:24 +0100 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-12-29 11:44:24 +0100 |
commit | 31c5e0c1cbb6da955973bdce360eedbe61225688 (patch) | |
tree | 0170556dd7528723c803fb1c299199aca143ab24 /module/plugins/accounts | |
parent | more fixes and chunk+resume debug (diff) | |
download | pyload-31c5e0c1cbb6da955973bdce360eedbe61225688.tar.xz |
fixed accounts
Diffstat (limited to 'module/plugins/accounts')
-rw-r--r-- | module/plugins/accounts/DepositfilesCom.py | 6 | ||||
-rw-r--r-- | module/plugins/accounts/FileserveCom.py | 6 | ||||
-rw-r--r-- | module/plugins/accounts/FreakshareCom.py | 4 | ||||
-rw-r--r-- | module/plugins/accounts/HotfileCom.py | 6 | ||||
-rw-r--r-- | module/plugins/accounts/MegauploadCom.py | 4 | ||||
-rw-r--r-- | module/plugins/accounts/NetloadIn.py | 4 | ||||
-rw-r--r-- | module/plugins/accounts/RapidshareCom.py | 4 | ||||
-rw-r--r-- | module/plugins/accounts/ShareonlineBiz.py | 4 | ||||
-rw-r--r-- | module/plugins/accounts/UploadedTo.py | 4 |
9 files changed, 21 insertions, 21 deletions
diff --git a/module/plugins/accounts/DepositfilesCom.py b/module/plugins/accounts/DepositfilesCom.py index b33083da9..b0730de8e 100644 --- a/module/plugins/accounts/DepositfilesCom.py +++ b/module/plugins/accounts/DepositfilesCom.py @@ -31,7 +31,7 @@ class DepositfilesCom(Account): def loadAccountInfo(self, user, req): - src = req.getPage("http://depositfiles.com/de/gold/") + src = req.load("http://depositfiles.com/de/gold/") validuntil = re.search("noch den Gold-Zugriff: <b>(.*?)</b></div>", src).group(1) validuntil = int(mktime(strptime(validuntil, "%Y-%m-%d %H:%M:%S"))) @@ -41,7 +41,7 @@ class DepositfilesCom(Account): def login(self, user, data, req): - req.getPage("http://depositfiles.com/de/gold/payment.php") - src = req.getPage("http://depositfiles.com/de/login.php", get={"return": "/de/gold/payment.php"}, post={"login": user, "password": data["password"]}) + req.load("http://depositfiles.com/de/gold/payment.php") + src = req.load("http://depositfiles.com/de/login.php", get={"return": "/de/gold/payment.php"}, post={"login": user, "password": data["password"]}) if r'<div class="error_message">Sie haben eine falsche Benutzername-Passwort-Kombination verwendet.</div>' in src: self.wrongPassword() diff --git a/module/plugins/accounts/FileserveCom.py b/module/plugins/accounts/FileserveCom.py index 76fc485ed..7754de253 100644 --- a/module/plugins/accounts/FileserveCom.py +++ b/module/plugins/accounts/FileserveCom.py @@ -31,7 +31,7 @@ class FileserveCom(Account): def loadAccountInfo(self, user, req): - src = req.getPage("http://fileserve.com/dashboard.php", cookies=True) + src = req.load("http://fileserve.com/dashboard.php", cookies=True) m = re.search(r"<td><h4>Premium Until</h4></th> <td><h5>(.*?) E(.)T</h5></td>", src) if m: @@ -44,12 +44,12 @@ class FileserveCom(Account): def login(self, user, data, req): - html = req.getPage("http://fileserve.com/login.php", + html = req.load("http://fileserve.com/login.php", post={"loginUserName": user, "loginUserPassword": data["password"], "autoLogin": "on", "loginFormSubmit": "Login"}, cookies=True) if r'Please Enter a valid user name.' in html: self.wrongPassword() - req.getPage("http://fileserve.com/dashboard.php", cookies=True) + req.load("http://fileserve.com/dashboard.php", cookies=True) diff --git a/module/plugins/accounts/FreakshareCom.py b/module/plugins/accounts/FreakshareCom.py index fcab247cb..732f9e203 100644 --- a/module/plugins/accounts/FreakshareCom.py +++ b/module/plugins/accounts/FreakshareCom.py @@ -30,7 +30,7 @@ class FreakshareCom(Account): __author_mail__ = ("RaNaN@pyload.org") def loadAccountInfo(self, user, req): - page = req.getPage("http://freakshare.com/") + page = req.load("http://freakshare.com/") validuntil = r"ltig bis:</td>\s*<td><b>([0-9 \-:.]+)</b></td>" validuntil = re.search(validuntil, page, re.MULTILINE) @@ -45,7 +45,7 @@ class FreakshareCom(Account): return {"validuntil": validuntil, "trafficleft": traffic} def login(self, user, data, req): - page = req.getPage("http://freakshare.com/login.html", None, { "submit" : "Login", "user" : user, "pass" : data['password']}, cookies=True) + page = req.load("http://freakshare.com/login.html", None, { "submit" : "Login", "user" : user, "pass" : data['password']}, cookies=True) if "Falsche Logindaten!" in page or "Wrong Username or Password!" in page: self.wrongPassword() diff --git a/module/plugins/accounts/HotfileCom.py b/module/plugins/accounts/HotfileCom.py index 579267af3..42b8274b1 100644 --- a/module/plugins/accounts/HotfileCom.py +++ b/module/plugins/accounts/HotfileCom.py @@ -57,7 +57,7 @@ class HotfileCom(Account): req = self.getAccountRequest(user) - digest = req.getPage("http://api.hotfile.com/", post={"action":"getdigest"}) + digest = req.load("http://api.hotfile.com/", post={"action":"getdigest"}) h = hashlib.md5() h.update(data["password"]) hp = h.hexdigest() @@ -68,7 +68,7 @@ class HotfileCom(Account): post.update({"action": method}) post.update({"username":user, "passwordmd5dig":pwhash, "digest":digest}) - resp = req.getPage("http://api.hotfile.com/", post=post) + resp = req.load("http://api.hotfile.com/", post=post) req.clean() return resp @@ -76,7 +76,7 @@ class HotfileCom(Account): cj = self.getAccountCookies(user) cj.setCookie("hotfile.com", "lang", "en") req.load("http://hotfile.com/", cookies=True) - page = req.getPage("http://hotfile.com/login.php", post={"returnto": "/", "user": user, "pass": data["password"]}, cookies=True) + page = req.load("http://hotfile.com/login.php", post={"returnto": "/", "user": user, "pass": data["password"]}, cookies=True) if "Bad username/password" in page: self.wrongPassword() diff --git a/module/plugins/accounts/MegauploadCom.py b/module/plugins/accounts/MegauploadCom.py index d50008b70..3432c299a 100644 --- a/module/plugins/accounts/MegauploadCom.py +++ b/module/plugins/accounts/MegauploadCom.py @@ -31,7 +31,7 @@ class MegauploadCom(Account): __author_mail__ = ("RaNaN@pyload.org") def loadAccountInfo(self, user, req): - page = req.getPage("http://www.megaupload.com/?c=account") + page = req.load("http://www.megaupload.com/?c=account") free = re.findall(r"Account type:</TD>\s*<TD><b>Regular</b>",page,re.IGNORECASE+re.MULTILINE) if free: @@ -47,6 +47,6 @@ class MegauploadCom(Account): def login(self, user, data, req): - page = req.getPage("http://www.megaupload.com/?c=login&next=c%3Dpremium", post={ "username" : user, "password" : data["password"], "login" :"1"}, cookies=True) + page = req.load("http://www.megaupload.com/?c=login&next=c%3Dpremium", post={ "username" : user, "password" : data["password"], "login" :"1"}, cookies=True) if "Username and password do not match" in page: self.wrongPassword() diff --git a/module/plugins/accounts/NetloadIn.py b/module/plugins/accounts/NetloadIn.py index 89e4c0037..4f5b08689 100644 --- a/module/plugins/accounts/NetloadIn.py +++ b/module/plugins/accounts/NetloadIn.py @@ -30,13 +30,13 @@ class NetloadIn(Account): __author_mail__ = ("RaNaN@pyload.org") def loadAccountInfo(self, user, req): - page = req.getPage("http://netload.in/index.php?id=2") + page = req.load("http://netload.in/index.php?id=2") left = r">(\d+) Tage, (\d+) Stunden<" left = re.search(left, page) validuntil = time() + int(left.group(1)) * 24 * 60 * 60 + int(left.group(2)) * 60 * 60 return {"validuntil": validuntil, "trafficleft": -1} def login(self, user, data,req): - page = req.getPage("http://netload.in/index.php", None, { "txtuser" : user, "txtpass" : data['password'], "txtcheck" : "login", "txtlogin" : ""}, cookies=True) + page = req.load("http://netload.in/index.php", None, { "txtuser" : user, "txtpass" : data['password'], "txtcheck" : "login", "txtlogin" : ""}, cookies=True) if "password or it might be invalid!" in page: self.wrongPassword() diff --git a/module/plugins/accounts/RapidshareCom.py b/module/plugins/accounts/RapidshareCom.py index e4472a4db..a2bb30211 100644 --- a/module/plugins/accounts/RapidshareCom.py +++ b/module/plugins/accounts/RapidshareCom.py @@ -31,7 +31,7 @@ class RapidshareCom(Account): data = self.getAccountData(user) api_url_base = "http://api.rapidshare.com/cgi-bin/rsapi.cgi" api_param_prem = {"sub": "getaccountdetails_v1", "type": "prem", "login": user, "password": data["password"], "withcookie": 1} - src = req.getPage(api_url_base, cookies=False, get=api_param_prem) + src = req.load(api_url_base, cookies=False, get=api_param_prem) if src.startswith("ERROR"): raise Exception(src) fields = src.split("\n") @@ -51,7 +51,7 @@ class RapidshareCom(Account): def login(self, user, data, req): api_url_base = "http://api.rapidshare.com/cgi-bin/rsapi.cgi" api_param_prem = {"sub": "getaccountdetails_v1", "type": "prem", "login": user, "password": data["password"], "withcookie": 1} - src = req.getPage(api_url_base, cookies=False, get=api_param_prem) + src = req.load(api_url_base, cookies=False, get=api_param_prem) if src.startswith("ERROR"): raise Exception(src+"### Note you have to use your account number for login, instead of name.") fields = src.split("\n") diff --git a/module/plugins/accounts/ShareonlineBiz.py b/module/plugins/accounts/ShareonlineBiz.py index e868b65b2..3564d489c 100644 --- a/module/plugins/accounts/ShareonlineBiz.py +++ b/module/plugins/accounts/ShareonlineBiz.py @@ -30,7 +30,7 @@ class ShareonlineBiz(Account): __author_mail__ = ("mkaay@mkaay.de") def loadAccountInfo(self, user, req): - src = req.getPage("http://www.share-online.biz/members.php?setlang=en") + src = req.load("http://www.share-online.biz/members.php?setlang=en") validuntil = re.search(r'<td align="left"><b>Package Expire Date:</b></td>\s*<td align="left">(\d+/\d+/\d+)</td>', src).group(1) validuntil = int(mktime(strptime(validuntil, "%m/%d/%y"))) @@ -47,4 +47,4 @@ class ShareonlineBiz(Account): "login": "Login" } req.lastURL = "http://www.share-online.biz/" - req.getPage("https://www.share-online.biz/login.php", cookies=True, post=post_vars) + req.load("https://www.share-online.biz/login.php", cookies=True, post=post_vars) diff --git a/module/plugins/accounts/UploadedTo.py b/module/plugins/accounts/UploadedTo.py index 9b17debf5..b432bf98a 100644 --- a/module/plugins/accounts/UploadedTo.py +++ b/module/plugins/accounts/UploadedTo.py @@ -31,7 +31,7 @@ class UploadedTo(Account): __author_mail__ = ("mkaay@mkaay.de") def loadAccountInfo(self, user, req): - html = req.getPage("http://uploaded.to/", cookies=True) + html = req.load("http://uploaded.to/", cookies=True) raw_traffic = re.search(r"Traffic left: </span><span class=.*?>(.*?)</span>", html).group(1) raw_valid = re.search(r"Valid until: </span> <span class=.*?>(.*?)</span>", html).group(1) traffic = int(self.parseTraffic(raw_traffic)) @@ -42,6 +42,6 @@ class UploadedTo(Account): def login(self, user, data, req): req.cookieJar.set_cookie(Cookie(version=0, name='lang', value='en', port=None, port_specified=False, domain='.uploaded.to', domain_specified=True, domain_initial_dot=True, path='/', path_specified=True, secure=False, expires=None, discard=False, comment=None, comment_url=None, rest={}, rfc2109=False)) - page = req.getPage("http://uploaded.to/login", post={ "email" : user, "password" : data["password"]}) + page = req.load("http://uploaded.to/login", post={ "email" : user, "password" : data["password"]}) if "Login failed!" in page: self.wrongPassword() |