summaryrefslogtreecommitdiffstats
path: root/pyload/plugin/hoster/TusfilesNet.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyload/plugin/hoster/TusfilesNet.py')
-rw-r--r--pyload/plugin/hoster/TusfilesNet.py37
1 files changed, 37 insertions, 0 deletions
diff --git a/pyload/plugin/hoster/TusfilesNet.py b/pyload/plugin/hoster/TusfilesNet.py
new file mode 100644
index 000000000..a11e86a40
--- /dev/null
+++ b/pyload/plugin/hoster/TusfilesNet.py
@@ -0,0 +1,37 @@
+# -*- coding: utf-8 -*-
+
+from pyload.network.HTTPRequest import BadHeader
+from pyload.plugin.internal.XFSHoster import XFSHoster
+
+
+class TusfilesNet(XFSHoster):
+ __name__ = "TusfilesNet"
+ __type__ = "hoster"
+ __version__ = "0.10"
+
+ __pattern__ = r'https?://(?:www\.)?tusfiles\.net/\w{12}'
+
+ __description__ = """Tusfiles.net hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Walter Purcaro", "vuolter@gmail.com"),
+ ("guidobelix", "guidobelix@hotmail.it")]
+
+
+ INFO_PATTERN = r'\](?P<N>.+) - (?P<S>[\d.,]+) (?P<U>[\w^_]+)\['
+ OFFLINE_PATTERN = r'>File Not Found|<Title>TusFiles - Fast Sharing Files!|The file you are trying to download is no longer available'
+
+
+ def setup(self):
+ self.chunkLimit = -1
+ self.multiDL = True
+ self.resumeDownload = True
+
+
+ def downloadLink(self, link, disposition=True):
+ try:
+ return super(TusfilesNet, self).downloadLink(link, disposition)
+
+ except BadHeader, e:
+ if e.code is 503:
+ self.multiDL = False
+ raise Retry("503")