From acc46fc3497a66a427b795b4a22c6e71d69185a1 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 13 Dec 2014 15:56:57 +0100 Subject: Update --- pyload/plugin/account/DepositfilesCom.py | 35 ++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 pyload/plugin/account/DepositfilesCom.py (limited to 'pyload/plugin/account/DepositfilesCom.py') diff --git a/pyload/plugin/account/DepositfilesCom.py b/pyload/plugin/account/DepositfilesCom.py new file mode 100644 index 000000000..ac1da7b0c --- /dev/null +++ b/pyload/plugin/account/DepositfilesCom.py @@ -0,0 +1,35 @@ +# -*- coding: utf-8 -*- + +import re + +from time import strptime, mktime + +from pyload.plugin.Account import Account + + +class DepositfilesCom(Account): + __name = "DepositfilesCom" + __type = "account" + __version = "0.30" + + __description = """Depositfiles.com account plugin""" + __license = "GPLv3" + __authors = [("mkaay", "mkaay@mkaay.de"), + ("stickell", "l.stickell@yahoo.it"), + ("Walter Purcaro", "vuolter@gmail.com")] + + + def loadAccountInfo(self, user, req): + html = req.load("https://dfiles.eu/de/gold/") + validuntil = re.search(r"Sie haben Gold Zugang bis: (.*?)", html).group(1) + + validuntil = int(mktime(strptime(validuntil, "%Y-%m-%d %H:%M:%S"))) + + return {"validuntil": validuntil, "trafficleft": -1} + + + def login(self, user, data, req): + html = req.load("https://dfiles.eu/de/login.php", get={"return": "/de/gold/payment.php"}, + post={"login": user, "password": data['password']}) + if r'
Sie haben eine falsche Benutzername-Passwort-Kombination verwendet.
' in html: + self.wrongPassword() -- cgit v1.2.3