diff options
author | Walter Purcaro <vuolter@gmail.com> | 2014-09-08 00:29:57 +0200 |
---|---|---|
committer | Walter Purcaro <vuolter@gmail.com> | 2014-09-14 11:02:23 +0200 |
commit | 68d662e689cd42687341c550fb6ebb74e6968d21 (patch) | |
tree | 486cef41bd928b8db704894233b2cef94a6e346f /module/plugins/crypter/LixIn.py | |
parent | save_join -> safe_join & save_path -> safe_filename (diff) | |
download | pyload-68d662e689cd42687341c550fb6ebb74e6968d21.tar.xz |
module -> pyload
Diffstat (limited to 'module/plugins/crypter/LixIn.py')
-rw-r--r-- | module/plugins/crypter/LixIn.py | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/module/plugins/crypter/LixIn.py b/module/plugins/crypter/LixIn.py deleted file mode 100644 index cdf87eeb2..000000000 --- a/module/plugins/crypter/LixIn.py +++ /dev/null @@ -1,59 +0,0 @@ -# -*- coding: utf-8 -*- - -import re - -from module.plugins.Crypter import Crypter - - -class LixIn(Crypter): - __name__ = "LixIn" - __type__ = "crypter" - __version__ = "0.22" - - __pattern__ = r'http://(www.)?lix.in/(?P<id>.*)' - - __description__ = """Lix.in decrypter plugin""" - __author_name__ = "spoob" - __author_mail__ = "spoob@pyload.org" - - CAPTCHA_PATTERN = r'<img src="(?P<image>captcha_img.php\?.*?)"' - SUBMIT_PATTERN = r"value='continue.*?'" - LINK_PATTERN = r'name="ifram" src="(?P<link>.*?)"' - - - def decrypt(self, pyfile): - url = pyfile.url - - m = re.match(self.__pattern__, url) - if m is None: - self.fail("couldn't identify file id") - - id = m.group("id") - self.logDebug("File id is %s" % id) - - self.html = self.req.load(url, decode=True) - - m = re.search(self.SUBMIT_PATTERN, self.html) - if m is None: - self.fail("link doesn't seem valid") - - m = re.search(self.CAPTCHA_PATTERN, self.html) - if m: - for _ in xrange(5): - m = re.search(self.CAPTCHA_PATTERN, self.html) - if m: - self.logDebug("trying captcha") - captcharesult = self.decryptCaptcha("http://lix.in/" + m.group("image")) - self.html = self.req.load(url, decode=True, - post={"capt": captcharesult, "submit": "submit", "tiny": id}) - else: - self.logDebug("no captcha/captcha solved") - else: - self.html = self.req.load(url, decode=True, post={"submit": "submit", "tiny": id}) - - m = re.search(self.LINK_PATTERN, self.html) - if m is None: - self.fail("can't find destination url") - else: - self.urls = [m.group("link")] - self.logDebug("Found link %s, adding to package" % self.urls[0]) |