summaryrefslogtreecommitdiffstats
path: root/module/plugins/accounts/StahnuTo.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-09-08 00:29:57 +0200
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-09-14 11:02:23 +0200
commit68d662e689cd42687341c550fb6ebb74e6968d21 (patch)
tree486cef41bd928b8db704894233b2cef94a6e346f /module/plugins/accounts/StahnuTo.py
parentsave_join -> safe_join & save_path -> safe_filename (diff)
downloadpyload-68d662e689cd42687341c550fb6ebb74e6968d21.tar.xz
module -> pyload
Diffstat (limited to 'module/plugins/accounts/StahnuTo.py')
-rw-r--r--module/plugins/accounts/StahnuTo.py34
1 files changed, 0 insertions, 34 deletions
diff --git a/module/plugins/accounts/StahnuTo.py b/module/plugins/accounts/StahnuTo.py
deleted file mode 100644
index 6d9c3e924..000000000
--- a/module/plugins/accounts/StahnuTo.py
+++ /dev/null
@@ -1,34 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-
-from module.plugins.Account import Account
-from module.utils import parseFileSize
-
-
-class StahnuTo(Account):
- __name__ = "StahnuTo"
- __type__ = "account"
- __version__ = "0.02"
-
- __description__ = """StahnuTo account plugin"""
- __author_name__ = "zoidberg"
- __author_mail__ = "zoidberg@mujmail.cz"
-
-
- def loadAccountInfo(self, user, req):
- html = req.load("http://www.stahnu.to/")
-
- m = re.search(r'>VIP: (\d+.*)<', html)
- trafficleft = parseFileSize(m.group(1)) * 1024 if m else 0
-
- return {"premium": trafficleft > (512 * 1024), "trafficleft": trafficleft, "validuntil": -1}
-
- def login(self, user, data, req):
- html = req.load("http://www.stahnu.to/login.php", post={
- "username": user,
- "password": data['password'],
- "submit": "Login"})
-
- if not '<a href="logout.php">' in html:
- self.wrongPassword()