summaryrefslogtreecommitdiffstats
path: root/pyload/plugin/account/UnrestrictLi.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-05-09 23:35:25 +0200
committerGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-05-09 23:35:25 +0200
commitb673872a9360a8f4a58dc1afd19fe0129d82f848 (patch)
tree9e6fe563f36666c4f15b09f45813730333e2242b /pyload/plugin/account/UnrestrictLi.py
parentFix https://github.com/pyload/pyload/issues/1406 (diff)
parent[ClickAndLoad] Version up (diff)
downloadpyload-b673872a9360a8f4a58dc1afd19fe0129d82f848.tar.xz
Merge branch 'stable' into 0.4.10
Conflicts: module/plugins/hoster/BillionuploadsCom.py pyload/plugin/account/ShareonlineBiz.py pyload/plugin/account/UnrestrictLi.py pyload/plugin/addon/ClickNLoad.py pyload/plugin/hook/LinkdecrypterCom.py pyload/plugin/hook/UnrestrictLi.py pyload/plugin/hoster/FilefactoryCom.py pyload/plugin/hoster/UnrestrictLi.py pyload/plugin/internal/MultiHook.py pyload/plugin/internal/XFSCrypter.py
Diffstat (limited to 'pyload/plugin/account/UnrestrictLi.py')
-rw-r--r--pyload/plugin/account/UnrestrictLi.py44
1 files changed, 0 insertions, 44 deletions
diff --git a/pyload/plugin/account/UnrestrictLi.py b/pyload/plugin/account/UnrestrictLi.py
deleted file mode 100644
index d57b998ca..000000000
--- a/pyload/plugin/account/UnrestrictLi.py
+++ /dev/null
@@ -1,44 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from pyload.plugin.Account import Account
-from pyload.utils import json_loads
-
-
-class UnrestrictLi(Account):
- __name = "UnrestrictLi"
- __type = "account"
- __version = "0.05"
-
- __description = """Unrestrict.li account plugin"""
- __license = "GPLv3"
- __authors = [("stickell", "l.stickell@yahoo.it")]
-
-
- def loadAccountInfo(self, user, req):
- json_data = req.load('http://unrestrict.li/api/jdownloader/user.php?format=json')
- self.logDebug("JSON data: " + json_data)
- json_data = json_loads(json_data)
-
- if 'vip' in json_data['result'] and json_data['result']['vip'] == 0:
- return {"premium": False}
-
- validuntil = json_data['result']['expires']
- trafficleft = float(json_data['result']['traffic'])
-
- return {"premium": True, "validuntil": validuntil, "trafficleft": trafficleft}
-
-
- def login(self, user, data, req):
- req.cj.setCookie("unrestrict.li", "lang", "EN")
- html = req.load("https://unrestrict.li/sign_in", decode=True)
-
- if 'solvemedia' in html:
- self.logError(_("A Captcha is required. Go to http://unrestrict.li/sign_in and login, then retry"))
- return
-
- post_data = {"username": user, "password": data['password'],
- "remember_me": "remember", "signin": "Sign in"}
- html = req.load("https://unrestrict.li/sign_in", post=post_data, decode=True)
-
- if 'sign_out' not in html:
- self.wrongPassword()