From 1da646a91a394b60761ef7f9aea8bf7ceb710836 Mon Sep 17 00:00:00 2001 From: z00nx Date: Sun, 20 Jan 2013 12:34:11 +1100 Subject: Added SpeedLoadOrg plugin --- module/plugins/hoster/SpeedLoadOrg.py | 41 +++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 module/plugins/hoster/SpeedLoadOrg.py (limited to 'module/plugins/hoster') diff --git a/module/plugins/hoster/SpeedLoadOrg.py b/module/plugins/hoster/SpeedLoadOrg.py new file mode 100644 index 000000000..d5e89b93f --- /dev/null +++ b/module/plugins/hoster/SpeedLoadOrg.py @@ -0,0 +1,41 @@ +# -*- coding: utf-8 -*- +from module.plugins.internal.SimpleHoster import SimpleHoster, parseFileInfo +from module.network.RequestFactory import getURL +from module.plugins.ReCaptcha import ReCaptcha +import re + + +def getInfo(urls): + for url in urls: + header = getURL(url, just_header=True) + if 'Location: http://speedload.org/index.php' in header: + file_info = (url, 0, 1, url) + else: + file_info = parseFileInfo(SpeedLoadOrg, url, getURL(url, decode=True)) + yield file_info + + +class SpeedLoadOrg(SimpleHoster): + __name__ = "SpeedLoadOrg" + __type__ = "hoster" + __pattern__ = r"http://(www\.)?speedload\.org/(?P\w+).*" + __version__ = "0.01" + __description__ = """Speedload.org hoster plugin""" + __author_name__ = ("z00nx") + __author_mail__ = ("z00nx0@gmail.com") + + FILE_NAME_PATTERN = '