diff options
Diffstat (limited to 'module/plugins/crypter/Dereferer.py')
-rw-r--r-- | module/plugins/crypter/Dereferer.py | 21 |
1 files changed, 6 insertions, 15 deletions
diff --git a/module/plugins/crypter/Dereferer.py b/module/plugins/crypter/Dereferer.py index 398cadce7..8427c1540 100644 --- a/module/plugins/crypter/Dereferer.py +++ b/module/plugins/crypter/Dereferer.py @@ -1,26 +1,17 @@ # -*- coding: utf-8 -*- -import re +from module.plugins.internal.SimpleDereferer import SimpleDereferer -from urllib import unquote -from module.plugins.Crypter import Crypter - - -class Dereferer(Crypter): +class Dereferer(SimpleDereferer): __name__ = "Dereferer" __type__ = "crypter" - __version__ = "0.10" + __version__ = "0.11" - __pattern__ = r'https?://([^/]+)/.*?(?P<URL>(ht|f)tps?(://|%3A%2F%2F).*)' - __config__ = [("use_subfolder", "bool", "Save package to subfolder", True), - ("subfolder_per_package", "bool", "Create a subfolder for each package", True)] + __pattern__ = r'https?://([^/]+)/.*?(?P<LINK>(ht|f)tps?(://|%3A%2F%2F).+)' + __config__ = [("use_subfolder" , "bool", "Save package to subfolder" , True), + ("subfolder_per_pack", "bool", "Create a subfolder for each package", True)] __description__ = """Crypter for dereferers""" __license__ = "GPLv3" __authors__ = [("zoidberg", "zoidberg@mujmail.cz")] - - - def decrypt(self, pyfile): - link = re.match(self.__pattern__, pyfile.url).group('URL') - self.urls = [unquote(link).rstrip('+')] |