summaryrefslogtreecommitdiffstats
path: root/pyload
diff options
context:
space:
mode:
Diffstat (limited to 'pyload')
-rw-r--r--pyload/plugins/Plugin.py8
-rw-r--r--pyload/plugins/account/AlldebridCom.py2
-rw-r--r--pyload/plugins/account/BayfilesCom.py2
-rw-r--r--pyload/plugins/account/BillionuploadsCom.py2
-rw-r--r--pyload/plugins/account/BitshareCom.py2
-rw-r--r--pyload/plugins/account/CatShareNet.py56
-rw-r--r--pyload/plugins/account/CramitIn.py2
-rw-r--r--pyload/plugins/account/CzshareCom.py2
-rw-r--r--pyload/plugins/account/DebridItaliaCom.py2
-rw-r--r--pyload/plugins/account/DepositfilesCom.py2
-rw-r--r--pyload/plugins/account/EasybytezCom.py2
-rw-r--r--pyload/plugins/account/EuroshareEu.py2
-rw-r--r--pyload/plugins/account/FastixRu.py2
-rw-r--r--pyload/plugins/account/FastshareCz.py4
-rw-r--r--pyload/plugins/account/File4safeCom.py2
-rw-r--r--pyload/plugins/account/FileParadoxIn.py2
-rw-r--r--pyload/plugins/account/FilecloudIo.py2
-rw-r--r--pyload/plugins/account/FilefactoryCom.py2
-rw-r--r--pyload/plugins/account/FilejungleCom.py2
-rw-r--r--pyload/plugins/account/FileomCom.py2
-rw-r--r--pyload/plugins/account/FilerNet.py2
-rw-r--r--pyload/plugins/account/FilerioCom.py2
-rw-r--r--pyload/plugins/account/FilesMailRu.py2
-rw-r--r--pyload/plugins/account/FileserveCom.py2
-rw-r--r--pyload/plugins/account/FourSharedCom.py2
-rw-r--r--pyload/plugins/account/FreakshareCom.py2
-rw-r--r--pyload/plugins/account/FreeWayMe.py2
-rw-r--r--pyload/plugins/account/FshareVn.py2
-rw-r--r--pyload/plugins/account/Ftp.py5
-rw-r--r--pyload/plugins/account/HellshareCz.py2
-rw-r--r--pyload/plugins/account/Http.py5
-rw-r--r--pyload/plugins/account/HugefilesNet.py2
-rw-r--r--pyload/plugins/account/HundredEightyUploadCom.py2
-rw-r--r--pyload/plugins/account/JunocloudMe.py16
-rw-r--r--pyload/plugins/account/Keep2shareCc.py69
-rw-r--r--pyload/plugins/account/LetitbitNet.py2
-rw-r--r--pyload/plugins/account/LinestorageCom.py16
-rw-r--r--pyload/plugins/account/LinksnappyCom.py2
-rw-r--r--pyload/plugins/account/LomafileCom.py2
-rw-r--r--pyload/plugins/account/MegaDebridEu.py2
-rw-r--r--pyload/plugins/account/MegaRapidCz.py59
-rw-r--r--pyload/plugins/account/MegasharesCom.py2
-rw-r--r--pyload/plugins/account/MovReelCom.py2
-rw-r--r--pyload/plugins/account/MultishareCz.py2
-rw-r--r--pyload/plugins/account/MyfastfileCom.py2
-rw-r--r--pyload/plugins/account/NetloadIn.py2
-rw-r--r--pyload/plugins/account/NosuploadCom.py2
-rw-r--r--pyload/plugins/account/NovafileCom.py2
-rw-r--r--pyload/plugins/account/NowVideoAt.py56
-rw-r--r--pyload/plugins/account/OboomCom.py2
-rw-r--r--pyload/plugins/account/OneFichierCom.py2
-rw-r--r--pyload/plugins/account/OverLoadMe.py2
-rw-r--r--pyload/plugins/account/PremiumTo.py2
-rw-r--r--pyload/plugins/account/PremiumizeMe.py2
-rw-r--r--pyload/plugins/account/QuickshareCz.py2
-rw-r--r--pyload/plugins/account/RPNetBiz.py2
-rw-r--r--pyload/plugins/account/RapidfileshareNet.py18
-rw-r--r--pyload/plugins/account/RapidgatorNet.py2
-rw-r--r--pyload/plugins/account/RapidshareCom.py2
-rw-r--r--pyload/plugins/account/RarefileNet.py2
-rw-r--r--pyload/plugins/account/RealdebridCom.py2
-rw-r--r--pyload/plugins/account/RehostTo.py2
-rw-r--r--pyload/plugins/account/RyushareCom.py2
-rw-r--r--pyload/plugins/account/SecureUploadEu.py2
-rw-r--r--pyload/plugins/account/SendmywayCom.py2
-rw-r--r--pyload/plugins/account/ShareonlineBiz.py2
-rw-r--r--pyload/plugins/account/SimplyPremiumCom.py2
-rw-r--r--pyload/plugins/account/SimplydebridCom.py2
-rw-r--r--pyload/plugins/account/StahnuTo.py2
-rw-r--r--pyload/plugins/account/StreamcloudEu.py2
-rw-r--r--pyload/plugins/account/TurbobitNet.py2
-rw-r--r--pyload/plugins/account/TusfilesNet.py2
-rw-r--r--pyload/plugins/account/UlozTo.py2
-rw-r--r--pyload/plugins/account/UnrestrictLi.py2
-rw-r--r--pyload/plugins/account/UploadcCom.py16
-rw-r--r--pyload/plugins/account/UploadedTo.py2
-rw-r--r--pyload/plugins/account/UploadheroCom.py2
-rw-r--r--pyload/plugins/account/UploadingCom.py4
-rw-r--r--pyload/plugins/account/UptoboxCom.py2
-rw-r--r--pyload/plugins/account/VidPlayNet.py2
-rw-r--r--pyload/plugins/account/XFileSharingPro.py30
-rw-r--r--pyload/plugins/account/YibaishiwuCom.py2
-rw-r--r--pyload/plugins/account/ZeveraCom.py2
-rw-r--r--pyload/plugins/addon/Checksum.py2
-rw-r--r--pyload/plugins/addon/ClickAndLoad.py2
-rw-r--r--pyload/plugins/addon/DeleteFinished.py2
-rw-r--r--pyload/plugins/addon/DownloadScheduler.py2
-rw-r--r--pyload/plugins/addon/ExternalScripts.py2
-rw-r--r--pyload/plugins/addon/ExtractArchive.py2
-rw-r--r--pyload/plugins/addon/HotFolder.py6
-rw-r--r--pyload/plugins/addon/IRCInterface.py2
-rw-r--r--pyload/plugins/addon/MergeFiles.py2
-rw-r--r--pyload/plugins/addon/MultiHome.py2
-rw-r--r--pyload/plugins/addon/RestartFailed.py2
-rw-r--r--pyload/plugins/addon/UnSkipOnFail.py2
-rw-r--r--pyload/plugins/addon/WindowsPhoneToastNotify.py2
-rw-r--r--pyload/plugins/base/Hook.py166
-rw-r--r--pyload/plugins/base/__init__.py0
-rw-r--r--pyload/plugins/captcha/AdsCaptcha.py26
-rw-r--r--pyload/plugins/captcha/ReCaptcha.py28
-rw-r--r--pyload/plugins/captcha/SolveMedia.py20
-rw-r--r--pyload/plugins/container/CCF.py2
-rw-r--r--pyload/plugins/container/LinkList.py2
-rw-r--r--pyload/plugins/container/RSDF.py4
-rw-r--r--pyload/plugins/crypter/ChipDe.py2
-rw-r--r--pyload/plugins/crypter/CzshareComFolder.py2
-rw-r--r--pyload/plugins/crypter/DDLMusicOrg.py2
-rw-r--r--pyload/plugins/crypter/DailymotionBatch.py2
-rw-r--r--pyload/plugins/crypter/Dereferer.py2
-rw-r--r--pyload/plugins/crypter/DontKnowMe.py2
-rw-r--r--pyload/plugins/crypter/DuckCryptInfo.py2
-rw-r--r--pyload/plugins/crypter/DuploadOrgFolder.py2
-rw-r--r--pyload/plugins/crypter/EasybytezComFolder.py2
-rw-r--r--pyload/plugins/crypter/EmbeduploadCom.py2
-rw-r--r--pyload/plugins/crypter/FileserveComFolder.py2
-rw-r--r--pyload/plugins/crypter/FilesonicComFolder.py15
-rw-r--r--pyload/plugins/crypter/FiredriveComFolder.py2
-rw-r--r--pyload/plugins/crypter/FourChanOrg.py2
-rw-r--r--pyload/plugins/crypter/GooGl.py2
-rw-r--r--pyload/plugins/crypter/HoerbuchIn.py2
-rw-r--r--pyload/plugins/crypter/HotfileComFolder.py16
-rw-r--r--pyload/plugins/crypter/JunocloudMeFolder.py20
-rw-r--r--pyload/plugins/crypter/LetitbitNetFolder.py2
-rw-r--r--pyload/plugins/crypter/LinkCryptWs.py341
-rw-r--r--pyload/plugins/crypter/LinkSaveIn.py2
-rw-r--r--pyload/plugins/crypter/LinkdecrypterCom.py2
-rw-r--r--pyload/plugins/crypter/LixIn.py2
-rw-r--r--pyload/plugins/crypter/MediafireComFolder.py2
-rw-r--r--pyload/plugins/crypter/MegaRapidCzFolder.py20
-rw-r--r--pyload/plugins/crypter/MegauploadComFolder.py15
-rw-r--r--pyload/plugins/crypter/MultiloadCz.py2
-rw-r--r--pyload/plugins/crypter/NCryptIn.py2
-rw-r--r--pyload/plugins/crypter/OneKhDe.py2
-rw-r--r--pyload/plugins/crypter/QuickshareCzFolder.py2
-rw-r--r--pyload/plugins/crypter/RapidfileshareNetFolder.py20
-rw-r--r--pyload/plugins/crypter/RelinkUs.py2
-rw-r--r--pyload/plugins/crypter/SafelinkingNet.py2
-rw-r--r--pyload/plugins/crypter/SexuriaCom.py94
-rw-r--r--pyload/plugins/crypter/ShareLinksBiz.py2
-rw-r--r--pyload/plugins/crypter/SharingmatrixComFolder.py15
-rw-r--r--pyload/plugins/crypter/TusfilesNetFolder.py2
-rw-r--r--pyload/plugins/crypter/UlozToFolder.py2
-rw-r--r--pyload/plugins/crypter/UploadedToFolder.py2
-rw-r--r--pyload/plugins/crypter/WuploadComFolder.py15
-rw-r--r--pyload/plugins/crypter/XFileSharingProFolder.py (renamed from pyload/plugins/internal/XFSPHoster.py)27
-rw-r--r--pyload/plugins/crypter/XupPl.py2
-rw-r--r--pyload/plugins/crypter/YoutubeBatch.py2
-rw-r--r--pyload/plugins/hook/BypassCaptcha.py2
-rw-r--r--pyload/plugins/hook/Captcha9kw.py2
-rw-r--r--pyload/plugins/hook/CaptchaBrotherhood.py2
-rw-r--r--pyload/plugins/hook/DeathByCaptcha.py2
-rw-r--r--pyload/plugins/hook/ExpertDecoders.py2
-rw-r--r--pyload/plugins/hook/ImageTyperz.py2
-rw-r--r--pyload/plugins/hook/LinkdecrypterCom.py2
-rw-r--r--pyload/plugins/hook/XFileSharingPro.py2
-rw-r--r--pyload/plugins/hoster/AlldebridCom.py2
-rw-r--r--pyload/plugins/hoster/BasePlugin.py2
-rw-r--r--pyload/plugins/hoster/BillionuploadsCom.py2
-rw-r--r--pyload/plugins/hoster/CramitIn.py2
-rw-r--r--pyload/plugins/hoster/DailymotionCom.py2
-rw-r--r--pyload/plugins/hoster/DebridItaliaCom.py2
-rw-r--r--pyload/plugins/hoster/EasybytezCom.py2
-rw-r--r--pyload/plugins/hoster/EnteruploadCom.py18
-rw-r--r--pyload/plugins/hoster/FastixRu.py2
-rw-r--r--pyload/plugins/hoster/FileParadoxIn.py2
-rw-r--r--pyload/plugins/hoster/FileSharkPl.py137
-rw-r--r--pyload/plugins/hoster/FileomCom.py2
-rw-r--r--pyload/plugins/hoster/FilerioCom.py2
-rw-r--r--pyload/plugins/hoster/FilesMailRu.py2
-rw-r--r--pyload/plugins/hoster/FileserveCom.py2
-rw-r--r--pyload/plugins/hoster/FileshareInUa.py2
-rw-r--r--pyload/plugins/hoster/FilesonicCom.py19
-rw-r--r--pyload/plugins/hoster/FiredriveCom.py2
-rw-r--r--pyload/plugins/hoster/FreakshareCom.py2
-rw-r--r--pyload/plugins/hoster/FreeWayMe.py2
-rw-r--r--pyload/plugins/hoster/Ftp.py2
-rw-r--r--pyload/plugins/hoster/GamefrontCom.py2
-rw-r--r--pyload/plugins/hoster/HugefilesNet.py2
-rw-r--r--pyload/plugins/hoster/HundredEightyUploadCom.py2
-rw-r--r--pyload/plugins/hoster/JunocloudMe.py29
-rw-r--r--pyload/plugins/hoster/Keep2shareCc.py118
-rw-r--r--pyload/plugins/hoster/KickloadCom.py18
-rw-r--r--pyload/plugins/hoster/LinksnappyCom.py2
-rw-r--r--pyload/plugins/hoster/LomafileCom.py2
-rw-r--r--pyload/plugins/hoster/MegaCoNz.py144
-rw-r--r--pyload/plugins/hoster/MegaDebridEu.py2
-rw-r--r--pyload/plugins/hoster/MegaRapidCz.py71
-rw-r--r--pyload/plugins/hoster/MegacrypterCom.py2
-rw-r--r--pyload/plugins/hoster/MegauploadCom.py18
-rw-r--r--pyload/plugins/hoster/MegavideoCom.py19
-rw-r--r--pyload/plugins/hoster/MovReelCom.py2
-rw-r--r--pyload/plugins/hoster/MyfastfileCom.py2
-rw-r--r--pyload/plugins/hoster/MyvideoDe.py2
-rw-r--r--pyload/plugins/hoster/NahrajCz.py18
-rw-r--r--pyload/plugins/hoster/NetloadIn.py2
-rw-r--r--pyload/plugins/hoster/NosuploadCom.py2
-rw-r--r--pyload/plugins/hoster/NovafileCom.py2
-rw-r--r--pyload/plugins/hoster/NowVideoAt.py44
-rw-r--r--pyload/plugins/hoster/OboomCom.py2
-rw-r--r--pyload/plugins/hoster/OronCom.py19
-rw-r--r--pyload/plugins/hoster/OverLoadMe.py2
-rw-r--r--pyload/plugins/hoster/PandaplaNet.py18
-rw-r--r--pyload/plugins/hoster/PornhostCom.py2
-rw-r--r--pyload/plugins/hoster/PornhubCom.py2
-rw-r--r--pyload/plugins/hoster/PremiumTo.py2
-rw-r--r--pyload/plugins/hoster/PremiumizeMe.py2
-rw-r--r--pyload/plugins/hoster/PrzeklejPl.py18
-rw-r--r--pyload/plugins/hoster/RPNetBiz.py2
-rw-r--r--pyload/plugins/hoster/RapidfileshareNet.py31
-rw-r--r--pyload/plugins/hoster/RapidshareCom.py2
-rw-r--r--pyload/plugins/hoster/RarefileNet.py2
-rw-r--r--pyload/plugins/hoster/RealdebridCom.py2
-rw-r--r--pyload/plugins/hoster/RedtubeCom.py2
-rw-r--r--pyload/plugins/hoster/RehostTo.py2
-rw-r--r--pyload/plugins/hoster/RyushareCom.py2
-rw-r--r--pyload/plugins/hoster/SecureUploadEu.py2
-rw-r--r--pyload/plugins/hoster/SendmywayCom.py2
-rw-r--r--pyload/plugins/hoster/ShareonlineBiz.py2
-rw-r--r--pyload/plugins/hoster/ShareplaceCom.py2
-rw-r--r--pyload/plugins/hoster/SharingmatrixCom.py19
-rw-r--r--pyload/plugins/hoster/SimplyPremiumCom.py2
-rw-r--r--pyload/plugins/hoster/SimplydebridCom.py2
-rw-r--r--pyload/plugins/hoster/SockshareCom.py2
-rw-r--r--pyload/plugins/hoster/SoundcloudCom.py2
-rw-r--r--pyload/plugins/hoster/StorageTo.py18
-rw-r--r--pyload/plugins/hoster/StreamCz.py2
-rw-r--r--pyload/plugins/hoster/StreamcloudEu.py2
-rw-r--r--pyload/plugins/hoster/TusfilesNet.py2
-rw-r--r--pyload/plugins/hoster/UnrestrictLi.py2
-rw-r--r--pyload/plugins/hoster/UpleaCom.py60
-rw-r--r--pyload/plugins/hoster/UploadboxCom.py18
-rw-r--r--pyload/plugins/hoster/UploadedTo.py2
-rw-r--r--pyload/plugins/hoster/UploadhereCom.py18
-rw-r--r--pyload/plugins/hoster/UploadkingCom.py18
-rw-r--r--pyload/plugins/hoster/UptoboxCom.py2
-rw-r--r--pyload/plugins/hoster/VeehdCom.py2
-rw-r--r--pyload/plugins/hoster/VidPlayNet.py2
-rw-r--r--pyload/plugins/hoster/WebshareCz.py2
-rw-r--r--pyload/plugins/hoster/XHamsterCom.py2
-rw-r--r--pyload/plugins/hoster/XVideosCom.py2
-rw-r--r--pyload/plugins/hoster/Xdcc.py2
-rw-r--r--pyload/plugins/hoster/YoupornCom.py2
-rw-r--r--pyload/plugins/hoster/YourfilesTo.py2
-rw-r--r--pyload/plugins/hoster/YoutubeCom.py2
-rw-r--r--pyload/plugins/hoster/ZDF.py2
-rw-r--r--pyload/plugins/hoster/ZeveraCom.py2
-rw-r--r--pyload/plugins/internal/Account.py (renamed from pyload/plugins/base/Account.py)2
-rw-r--r--pyload/plugins/internal/Addon.py (renamed from pyload/plugins/base/Addon.py)32
-rw-r--r--pyload/plugins/internal/Captcha.py (renamed from pyload/plugins/base/Captcha.py)16
-rw-r--r--pyload/plugins/internal/Container.py (renamed from pyload/plugins/base/Container.py)4
-rw-r--r--pyload/plugins/internal/Crypter.py (renamed from pyload/plugins/base/Crypter.py)6
-rw-r--r--pyload/plugins/internal/DeadCrypter.py2
-rw-r--r--pyload/plugins/internal/DeadHoster.py2
-rw-r--r--pyload/plugins/internal/Hoster.py (renamed from pyload/plugins/base/Hoster.py)2
-rw-r--r--pyload/plugins/internal/MultiHoster.py4
-rw-r--r--pyload/plugins/internal/OCR.py (renamed from pyload/plugins/base/OCR.py)2
-rw-r--r--pyload/plugins/internal/SimpleCrypter.py6
-rw-r--r--pyload/plugins/internal/SimpleHoster.py4
-rw-r--r--pyload/plugins/internal/UpdateManager.py2
-rw-r--r--pyload/plugins/internal/XFSAccount.py122
-rw-r--r--pyload/plugins/internal/XFSCrypter.py29
-rw-r--r--pyload/plugins/internal/XFSHoster.py345
-rw-r--r--pyload/plugins/internal/XFSPAccount.py96
-rw-r--r--pyload/plugins/ocr/GigasizeCom.py2
-rw-r--r--pyload/plugins/ocr/LinksaveIn.py2
-rw-r--r--pyload/plugins/ocr/NetloadIn.py2
-rw-r--r--pyload/plugins/ocr/ShareonlineBiz.py2
267 files changed, 2608 insertions, 560 deletions
diff --git a/pyload/plugins/Plugin.py b/pyload/plugins/Plugin.py
index c59d64911..a4b4cf74e 100644
--- a/pyload/plugins/Plugin.py
+++ b/pyload/plugins/Plugin.py
@@ -16,7 +16,7 @@ from itertools import islice
from traceback import print_exc
from urlparse import urlparse
-from module.utils import fs_decode, fs_encode, html_unescape, save_join, save_path
+from pyload.utils import fs_decode, fs_encode, html_unescape, safe_join
def chunks(iterable, size):
it = iter(iterable)
@@ -100,7 +100,7 @@ class Base(object):
:param value:
:return:
"""
- self.core.config.setPlugin(self.__name__, option, value)
+ self.core.config.setPlugin(self.__name__, option, value)
#: Deprecated method
@@ -154,7 +154,7 @@ class Plugin(Base):
__type__ = "hoster"
__version__ = "0.07"
- __pattern__ = None
+ __pattern__ = r'^unmatchable$'
__config__ = [] #: [("name", "type", "desc", "default")]
__description__ = """Base plugin"""
@@ -541,7 +541,7 @@ class Plugin(Base):
from inspect import currentframe
frame = currentframe()
- framefile = save_join("tmp", self.__name__, "%s_line%s.dump.html" % (frame.f_back.f_code.co_name, frame.f_back.f_lineno))
+ framefile = safe_join("tmp", self.__name__, "%s_line%s.dump.html" % (frame.f_back.f_code.co_name, frame.f_back.f_lineno))
try:
if not exists(join("tmp", self.__name__)):
makedirs(join("tmp", self.__name__))
diff --git a/pyload/plugins/account/AlldebridCom.py b/pyload/plugins/account/AlldebridCom.py
index daf844a40..d4770426b 100644
--- a/pyload/plugins/account/AlldebridCom.py
+++ b/pyload/plugins/account/AlldebridCom.py
@@ -8,7 +8,7 @@ from urllib import urlencode
from BeautifulSoup import BeautifulSoup
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class AlldebridCom(Account):
diff --git a/pyload/plugins/account/BayfilesCom.py b/pyload/plugins/account/BayfilesCom.py
index 85dba44fb..34163d0cc 100644
--- a/pyload/plugins/account/BayfilesCom.py
+++ b/pyload/plugins/account/BayfilesCom.py
@@ -2,7 +2,7 @@
from time import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/BillionuploadsCom.py b/pyload/plugins/account/BillionuploadsCom.py
index 11af36591..b1f621ecb 100644
--- a/pyload/plugins/account/BillionuploadsCom.py
+++ b/pyload/plugins/account/BillionuploadsCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class BillionuploadsCom(XFSAccount):
diff --git a/pyload/plugins/account/BitshareCom.py b/pyload/plugins/account/BitshareCom.py
index d35f3ce29..44b2818cf 100644
--- a/pyload/plugins/account/BitshareCom.py
+++ b/pyload/plugins/account/BitshareCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class BitshareCom(Account):
diff --git a/pyload/plugins/account/CatShareNet.py b/pyload/plugins/account/CatShareNet.py
new file mode 100644
index 000000000..30a2691da
--- /dev/null
+++ b/pyload/plugins/account/CatShareNet.py
@@ -0,0 +1,56 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from time import mktime, strptime
+
+from pyload.plugins.internal.Account import Account
+
+
+class CatShareNet(Account):
+ __name__ = "CatShareNet"
+ __type__ = "account"
+ __version__ = "0.01"
+
+ __description__ = """CatShareNet account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("prOq", None)]
+
+
+ PREMIUM_PATTERN = r'class="nav-collapse collapse pull-right">[\s\w<>=-."/:]*\sz.</a></li>\s*<li><a href="/premium">.*\s*<span style="color: red">(.*?)</span>[\s\w<>/]*href="/logout"'
+ VALID_UNTIL_PATTERN = r'<div class="span6 pull-right">[\s\w<>=-":;]*<span style="font-size:13px;">.*?<strong>(.*?)</strong></span>'
+
+
+ def loadAccountInfo(self, user, req):
+ premium = False
+ validuntil = -1
+
+ html = req.load("http://catshare.net/", decode=True)
+
+ try:
+ m = re.search(self.PREMIUM_PATTERN, html)
+ if "Premium" in m.group(1):
+ premium = True
+ except:
+ pass
+
+ try:
+ m = re.search(self.VALID_UNTIL_PATTERN, html)
+ expiredate = m.group(1)
+ if "-" not in expiredate:
+ validuntil = mktime(strptime(expiredate, "%d.%m.%Y"))
+ except:
+ pass
+
+ return {'premium': premium, 'trafficleft': -1, 'validuntil': validuntil}
+
+
+ def login(self, user, data, req):
+ html = req.load("http://catshare.net/login",
+ post={'user_email': user,
+ 'user_password': data['password'],
+ 'remindPassword': 0,
+ 'user[submit]': "Login"})
+
+ if not '<a href="/logout">Wyloguj</a>' in html:
+ self.wrongPassword()
diff --git a/pyload/plugins/account/CramitIn.py b/pyload/plugins/account/CramitIn.py
index a9e2274a2..42b7cc7b2 100644
--- a/pyload/plugins/account/CramitIn.py
+++ b/pyload/plugins/account/CramitIn.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class CramitIn(XFSAccount):
diff --git a/pyload/plugins/account/CzshareCom.py b/pyload/plugins/account/CzshareCom.py
index 54163c425..786832e8d 100644
--- a/pyload/plugins/account/CzshareCom.py
+++ b/pyload/plugins/account/CzshareCom.py
@@ -3,7 +3,7 @@
from time import mktime, strptime
import re
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class CzshareCom(Account):
diff --git a/pyload/plugins/account/DebridItaliaCom.py b/pyload/plugins/account/DebridItaliaCom.py
index cdeb0a9f1..30ed9fb1c 100644
--- a/pyload/plugins/account/DebridItaliaCom.py
+++ b/pyload/plugins/account/DebridItaliaCom.py
@@ -3,7 +3,7 @@
import re
import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class DebridItaliaCom(Account):
diff --git a/pyload/plugins/account/DepositfilesCom.py b/pyload/plugins/account/DepositfilesCom.py
index 47d720322..df3ebe4f2 100644
--- a/pyload/plugins/account/DepositfilesCom.py
+++ b/pyload/plugins/account/DepositfilesCom.py
@@ -4,7 +4,7 @@ import re
from time import strptime, mktime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class DepositfilesCom(Account):
diff --git a/pyload/plugins/account/EasybytezCom.py b/pyload/plugins/account/EasybytezCom.py
index f368840ef..b1fb6a213 100644
--- a/pyload/plugins/account/EasybytezCom.py
+++ b/pyload/plugins/account/EasybytezCom.py
@@ -4,7 +4,7 @@ import re
from time import mktime, strptime, gmtime
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
from pyload.utils import parseFileSize
diff --git a/pyload/plugins/account/EuroshareEu.py b/pyload/plugins/account/EuroshareEu.py
index e3ed51464..5ec543433 100644
--- a/pyload/plugins/account/EuroshareEu.py
+++ b/pyload/plugins/account/EuroshareEu.py
@@ -3,7 +3,7 @@
from time import mktime, strptime
import re
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class EuroshareEu(Account):
diff --git a/pyload/plugins/account/FastixRu.py b/pyload/plugins/account/FastixRu.py
index 6dacb8b11..96db443b7 100644
--- a/pyload/plugins/account/FastixRu.py
+++ b/pyload/plugins/account/FastixRu.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/FastshareCz.py b/pyload/plugins/account/FastshareCz.py
index 1a7dff4b1..b61d6b23f 100644
--- a/pyload/plugins/account/FastshareCz.py
+++ b/pyload/plugins/account/FastshareCz.py
@@ -2,8 +2,8 @@
import re
-from pyload.plugins.base.Account import Account
-from module.utils import parseFileSize
+from pyload.plugins.internal.Account import Account
+from pyload.utils import parseFileSize
class FastshareCz(Account):
diff --git a/pyload/plugins/account/File4safeCom.py b/pyload/plugins/account/File4safeCom.py
index 20053d895..42b67e08f 100644
--- a/pyload/plugins/account/File4safeCom.py
+++ b/pyload/plugins/account/File4safeCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class File4safeCom(XFSAccount):
diff --git a/pyload/plugins/account/FileParadoxIn.py b/pyload/plugins/account/FileParadoxIn.py
index c12d99d6a..cee7bec2f 100644
--- a/pyload/plugins/account/FileParadoxIn.py
+++ b/pyload/plugins/account/FileParadoxIn.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class FileParadoxIn(XFSAccount):
diff --git a/pyload/plugins/account/FilecloudIo.py b/pyload/plugins/account/FilecloudIo.py
index 0d5126fc0..b52521093 100644
--- a/pyload/plugins/account/FilecloudIo.py
+++ b/pyload/plugins/account/FilecloudIo.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/FilefactoryCom.py b/pyload/plugins/account/FilefactoryCom.py
index 7eedb59a1..0d7c1ff0e 100644
--- a/pyload/plugins/account/FilefactoryCom.py
+++ b/pyload/plugins/account/FilefactoryCom.py
@@ -5,7 +5,7 @@ from time import mktime, strptime
from pycurl import REFERER
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class FilefactoryCom(Account):
diff --git a/pyload/plugins/account/FilejungleCom.py b/pyload/plugins/account/FilejungleCom.py
index c8b7bb655..8abb89788 100644
--- a/pyload/plugins/account/FilejungleCom.py
+++ b/pyload/plugins/account/FilejungleCom.py
@@ -3,7 +3,7 @@
import re
from time import mktime, strptime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class FilejungleCom(Account):
diff --git a/pyload/plugins/account/FileomCom.py b/pyload/plugins/account/FileomCom.py
index 7c743f56a..04f503b3b 100644
--- a/pyload/plugins/account/FileomCom.py
+++ b/pyload/plugins/account/FileomCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class FileomCom(XFSAccount):
diff --git a/pyload/plugins/account/FilerNet.py b/pyload/plugins/account/FilerNet.py
index 193dd6eb3..f9b5efdd3 100644
--- a/pyload/plugins/account/FilerNet.py
+++ b/pyload/plugins/account/FilerNet.py
@@ -3,7 +3,7 @@
import re
import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class FilerNet(Account):
diff --git a/pyload/plugins/account/FilerioCom.py b/pyload/plugins/account/FilerioCom.py
index 4c6755293..27d8df13f 100644
--- a/pyload/plugins/account/FilerioCom.py
+++ b/pyload/plugins/account/FilerioCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class FilerioCom(XFSAccount):
diff --git a/pyload/plugins/account/FilesMailRu.py b/pyload/plugins/account/FilesMailRu.py
index c8d8d9270..bfd9d7ffb 100644
--- a/pyload/plugins/account/FilesMailRu.py
+++ b/pyload/plugins/account/FilesMailRu.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class FilesMailRu(Account):
diff --git a/pyload/plugins/account/FileserveCom.py b/pyload/plugins/account/FileserveCom.py
index 773fc9117..5a014ab03 100644
--- a/pyload/plugins/account/FileserveCom.py
+++ b/pyload/plugins/account/FileserveCom.py
@@ -2,7 +2,7 @@
from time import mktime, strptime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/FourSharedCom.py b/pyload/plugins/account/FourSharedCom.py
index 766998ccc..110572faa 100644
--- a/pyload/plugins/account/FourSharedCom.py
+++ b/pyload/plugins/account/FourSharedCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/FreakshareCom.py b/pyload/plugins/account/FreakshareCom.py
index 742ede902..12c5277a6 100644
--- a/pyload/plugins/account/FreakshareCom.py
+++ b/pyload/plugins/account/FreakshareCom.py
@@ -4,7 +4,7 @@ import re
from time import strptime, mktime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class FreakshareCom(Account):
diff --git a/pyload/plugins/account/FreeWayMe.py b/pyload/plugins/account/FreeWayMe.py
index 2c48d54f4..db879c052 100644
--- a/pyload/plugins/account/FreeWayMe.py
+++ b/pyload/plugins/account/FreeWayMe.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/FshareVn.py b/pyload/plugins/account/FshareVn.py
index b449018bc..ee8aacaf9 100644
--- a/pyload/plugins/account/FshareVn.py
+++ b/pyload/plugins/account/FshareVn.py
@@ -4,7 +4,7 @@ from time import mktime, strptime
from pycurl import REFERER
import re
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class FshareVn(Account):
diff --git a/pyload/plugins/account/Ftp.py b/pyload/plugins/account/Ftp.py
index 90a8a8768..d439512ce 100644
--- a/pyload/plugins/account/Ftp.py
+++ b/pyload/plugins/account/Ftp.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class Ftp(Account):
@@ -13,4 +13,5 @@ class Ftp(Account):
__authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
- login_timeout = info_threshold = -1 #: Unlimited
+ login_timeout = -1 #: Unlimited
+ info_threshold = -1 #: Unlimited
diff --git a/pyload/plugins/account/HellshareCz.py b/pyload/plugins/account/HellshareCz.py
index cd02c8462..1b93cf77d 100644
--- a/pyload/plugins/account/HellshareCz.py
+++ b/pyload/plugins/account/HellshareCz.py
@@ -3,7 +3,7 @@
import re
import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class HellshareCz(Account):
diff --git a/pyload/plugins/account/Http.py b/pyload/plugins/account/Http.py
index 3f3d4d66f..8c0aeb2e4 100644
--- a/pyload/plugins/account/Http.py
+++ b/pyload/plugins/account/Http.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class Http(Account):
@@ -13,4 +13,5 @@ class Http(Account):
__authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
- login_timeout = info_threshold = -1 #: Unlimited
+ login_timeout = -1 #: Unlimited
+ info_threshold = -1 #: Unlimited
diff --git a/pyload/plugins/account/HugefilesNet.py b/pyload/plugins/account/HugefilesNet.py
index 5da3bbc37..242ae118c 100644
--- a/pyload/plugins/account/HugefilesNet.py
+++ b/pyload/plugins/account/HugefilesNet.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class HugefilesNet(XFSAccount):
diff --git a/pyload/plugins/account/HundredEightyUploadCom.py b/pyload/plugins/account/HundredEightyUploadCom.py
index 39f91a8af..89d779e52 100644
--- a/pyload/plugins/account/HundredEightyUploadCom.py
+++ b/pyload/plugins/account/HundredEightyUploadCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class HundredEightyUploadCom(XFSAccount):
diff --git a/pyload/plugins/account/JunocloudMe.py b/pyload/plugins/account/JunocloudMe.py
new file mode 100644
index 000000000..14fe8ddd7
--- /dev/null
+++ b/pyload/plugins/account/JunocloudMe.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSAccount import XFSAccount
+
+
+class JunocloudMe(XFSAccount):
+ __name__ = "JunocloudMe"
+ __type__ = "account"
+ __version__ = "0.02"
+
+ __description__ = """Junocloud.me account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("guidobelix", "guidobelix@hotmail.it")]
+
+
+ HOSTER_DOMAIN = "junocloud.me"
diff --git a/pyload/plugins/account/Keep2shareCc.py b/pyload/plugins/account/Keep2shareCc.py
new file mode 100644
index 000000000..af870cfd0
--- /dev/null
+++ b/pyload/plugins/account/Keep2shareCc.py
@@ -0,0 +1,69 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from time import gmtime, mktime, strptime
+
+from pyload.plugins.internal.Account import Account
+
+
+class Keep2shareCc(Account):
+ __name__ = "Keep2shareCc"
+ __type__ = "account"
+ __version__ = "0.02"
+
+ __description__ = """Keep2share.cc account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("aeronaut", "aeronaut@pianoguy.de")]
+
+
+ VALID_UNTIL_PATTERN = r'Premium expires: <b>(.+?)</b>'
+ TRAFFIC_LEFT_PATTERN = r'Available traffic \(today\):<b><a href="/user/statistic.html">(.+?)</a>'
+
+ LOGIN_FAIL_PATTERN = r'Please fix the following input errors'
+
+
+ def loadAccountInfo(self, user, req):
+ validuntil = None
+ trafficleft = None
+ premium = None
+
+ html = req.load("http://keep2share.cc/site/profile.html", decode=True)
+
+ m = re.search(self.VALID_UNTIL_PATTERN, html)
+ if m:
+ expiredate = m.group(1).strip()
+ self.logDebug("Expire date: " + expiredate)
+
+ try:
+ validuntil = mktime(strptime(expiredate, "%Y.%m.%d"))
+
+ except Exception, e:
+ self.logError(e)
+
+ else:
+ if validuntil > mktime(gmtime()):
+ premium = True
+ else:
+ premium = False
+ validuntil = None
+
+ m = re.search(self.TRAFFIC_LEFT_PATTERN, html)
+ if m:
+ try:
+ trafficleft = self.parseTraffic(m.group(1))
+
+ except Exception, e:
+ self.logError(e)
+
+ return {'validuntil': validuntil, 'trafficleft': trafficleft, 'premium': premium}
+
+
+ def login(self, user, data, req):
+ req.cj.setCookie(".keep2share.cc", "lang", "en")
+
+ html = req.load("http://keep2share.cc/login.html",
+ post={'LoginForm[username]': user, 'LoginForm[password]': data['password']})
+
+ if re.search(self.LOGIN_FAIL_PATTERN, html):
+ self.wrongPassword()
diff --git a/pyload/plugins/account/LetitbitNet.py b/pyload/plugins/account/LetitbitNet.py
index 41823418d..5bf6de00c 100644
--- a/pyload/plugins/account/LetitbitNet.py
+++ b/pyload/plugins/account/LetitbitNet.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
# from pyload.utils import json_loads, json_dumps
diff --git a/pyload/plugins/account/LinestorageCom.py b/pyload/plugins/account/LinestorageCom.py
new file mode 100644
index 000000000..351d66d48
--- /dev/null
+++ b/pyload/plugins/account/LinestorageCom.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSAccount import XFSAccount
+
+
+class LinestorageCom(XFSAccount):
+ __name__ = "LinestorageCom"
+ __type__ = "account"
+ __version__ = "0.02"
+
+ __description__ = """Linestorage.com account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ HOSTER_DOMAIN = "linestorage.com"
diff --git a/pyload/plugins/account/LinksnappyCom.py b/pyload/plugins/account/LinksnappyCom.py
index 912c2b4cb..028465522 100644
--- a/pyload/plugins/account/LinksnappyCom.py
+++ b/pyload/plugins/account/LinksnappyCom.py
@@ -2,7 +2,7 @@
from hashlib import md5
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/LomafileCom.py b/pyload/plugins/account/LomafileCom.py
index cfd21679c..937b24fae 100644
--- a/pyload/plugins/account/LomafileCom.py
+++ b/pyload/plugins/account/LomafileCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class LomafileCom(XFSAccount):
diff --git a/pyload/plugins/account/MegaDebridEu.py b/pyload/plugins/account/MegaDebridEu.py
index 50f24b83d..3db0caa35 100644
--- a/pyload/plugins/account/MegaDebridEu.py
+++ b/pyload/plugins/account/MegaDebridEu.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/MegaRapidCz.py b/pyload/plugins/account/MegaRapidCz.py
new file mode 100644
index 000000000..a75e313ff
--- /dev/null
+++ b/pyload/plugins/account/MegaRapidCz.py
@@ -0,0 +1,59 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from time import mktime, strptime
+from pyload.plugins.internal.Account import Account
+
+
+class MegaRapidCz(Account):
+ __name__ = "MegaRapidCz"
+ __type__ = "account"
+ __version__ = "0.34"
+
+ __description__ = """MegaRapid.cz account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("MikyWoW", "mikywow@seznam.cz"),
+ ("zoidberg", "zoidberg@mujmail.cz")]
+
+
+ login_timeout = 60
+
+ LIMITDL_PATTERN = ur'<td>Max. počet paralelních stahování: </td><td>(\d+)'
+ VALID_UNTIL_PATTERN = ur'<td>Paušální stahování aktivní. Vyprší </td><td><strong>(.*?)</strong>'
+ TRAFFIC_LEFT_PATTERN = r'<tr><td>Kredit</td><td>(.*?) GiB'
+
+
+ def loadAccountInfo(self, user, req):
+ html = req.load("http://megarapid.cz/mujucet/", decode=True)
+
+ m = re.search(self.LIMITDL_PATTERN, html)
+ if m:
+ data = self.getAccountData(user)
+ data['options']['limitDL'] = [int(m.group(1))]
+
+ m = re.search(self.VALID_UNTIL_PATTERN, html)
+ if m:
+ validuntil = mktime(strptime(m.group(1), "%d.%m.%Y - %H:%M"))
+ return {"premium": True, "trafficleft": -1, "validuntil": validuntil}
+
+ m = re.search(self.TRAFFIC_LEFT_PATTERN, html)
+ if m:
+ trafficleft = float(m.group(1)) * (1 << 20)
+ return {"premium": True, "trafficleft": trafficleft, "validuntil": -1}
+
+ return {"premium": False, "trafficleft": None, "validuntil": None}
+
+
+ def login(self, user, data, req):
+ htm = req.load("http://megarapid.cz/prihlaseni/")
+ if "Heslo:" in htm:
+ start = htm.index('id="inp_hash" name="hash" value="')
+ htm = htm[start + 33:]
+ hashes = htm[0:32]
+ htm = req.load("http://megarapid.cz/prihlaseni/",
+ post={"hash": hashes,
+ "login": user,
+ "pass1": data['password'],
+ "remember": 0,
+ "sbmt": u"Přihlásit"})
diff --git a/pyload/plugins/account/MegasharesCom.py b/pyload/plugins/account/MegasharesCom.py
index 5931e4e7e..b2f439b45 100644
--- a/pyload/plugins/account/MegasharesCom.py
+++ b/pyload/plugins/account/MegasharesCom.py
@@ -3,7 +3,7 @@
import re
from time import mktime, strptime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class MegasharesCom(Account):
diff --git a/pyload/plugins/account/MovReelCom.py b/pyload/plugins/account/MovReelCom.py
index 6128cddc8..7a00af5d3 100644
--- a/pyload/plugins/account/MovReelCom.py
+++ b/pyload/plugins/account/MovReelCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class MovReelCom(XFSAccount):
diff --git a/pyload/plugins/account/MultishareCz.py b/pyload/plugins/account/MultishareCz.py
index 9eb0b50b2..9dc5b1ff0 100644
--- a/pyload/plugins/account/MultishareCz.py
+++ b/pyload/plugins/account/MultishareCz.py
@@ -2,7 +2,7 @@
import re
-from module.plugins.Account import Account
+from pyload.plugins.internal.Account import Account
class MultishareCz(Account):
diff --git a/pyload/plugins/account/MyfastfileCom.py b/pyload/plugins/account/MyfastfileCom.py
index 33cc3a694..acc09ad8b 100644
--- a/pyload/plugins/account/MyfastfileCom.py
+++ b/pyload/plugins/account/MyfastfileCom.py
@@ -2,7 +2,7 @@
from time import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/NetloadIn.py b/pyload/plugins/account/NetloadIn.py
index 2d6ae6eea..6e780225a 100644
--- a/pyload/plugins/account/NetloadIn.py
+++ b/pyload/plugins/account/NetloadIn.py
@@ -3,7 +3,7 @@
import re
from time import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class NetloadIn(Account):
diff --git a/pyload/plugins/account/NosuploadCom.py b/pyload/plugins/account/NosuploadCom.py
index e523ee2f4..9c11699ec 100644
--- a/pyload/plugins/account/NosuploadCom.py
+++ b/pyload/plugins/account/NosuploadCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class NosuploadCom(XFSAccount):
diff --git a/pyload/plugins/account/NovafileCom.py b/pyload/plugins/account/NovafileCom.py
index ab61bf0fc..cb3a639f5 100644
--- a/pyload/plugins/account/NovafileCom.py
+++ b/pyload/plugins/account/NovafileCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class NovafileCom(XFSAccount):
diff --git a/pyload/plugins/account/NowVideoAt.py b/pyload/plugins/account/NowVideoAt.py
new file mode 100644
index 000000000..7af8bc4bc
--- /dev/null
+++ b/pyload/plugins/account/NowVideoAt.py
@@ -0,0 +1,56 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from time import gmtime, mktime, strptime
+
+from pyload.plugins.internal.Account import Account
+
+
+class NowVideoAt(Account):
+ __name__ = "NowVideoAt"
+ __type__ = "account"
+ __version__ = "0.01"
+
+ __description__ = """NowVideo.at account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ VALID_UNTIL_PATTERN = r'>Your premium membership expires on: (.+?)<'
+
+
+ def loadAccountInfo(self, user, req):
+ validuntil = None
+ trafficleft = -1
+ premium = None
+
+ html = req.load("http://www.nowvideo.at/premium.php")
+
+ m = re.search(self.VALID_UNTIL_PATTERN, html)
+ if m:
+ expiredate = m.group(1).strip()
+ self.logDebug("Expire date: " + expiredate)
+
+ try:
+ validuntil = mktime(strptime(expiredate, "%Y-%b-%d"))
+
+ except Exception, e:
+ self.logError(e)
+
+ else:
+ if validuntil > mktime(gmtime()):
+ premium = True
+ else:
+ premium = False
+ validuntil = -1
+
+ return {"validuntil": validuntil, "trafficleft": trafficleft, "premium": premium}
+
+
+ def login(self, user, data, req):
+ html = req.load("http://www.nowvideo.at/login.php",
+ post={'user': user, 'pass': data['password']})
+
+ if ">Invalid login details" is html:
+ self.wrongPassword()
diff --git a/pyload/plugins/account/OboomCom.py b/pyload/plugins/account/OboomCom.py
index 71663bc3f..4f7f476e2 100644
--- a/pyload/plugins/account/OboomCom.py
+++ b/pyload/plugins/account/OboomCom.py
@@ -5,7 +5,7 @@ import time
from beaker.crypto.pbkdf2 import PBKDF2
from pyload.utils import json_loads
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class OboomCom(Account):
diff --git a/pyload/plugins/account/OneFichierCom.py b/pyload/plugins/account/OneFichierCom.py
index 857fd20b5..7f1140e67 100644
--- a/pyload/plugins/account/OneFichierCom.py
+++ b/pyload/plugins/account/OneFichierCom.py
@@ -6,7 +6,7 @@ from time import strptime, mktime
from pycurl import REFERER
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class OneFichierCom(Account):
diff --git a/pyload/plugins/account/OverLoadMe.py b/pyload/plugins/account/OverLoadMe.py
index d011cf063..cda4bc82f 100644
--- a/pyload/plugins/account/OverLoadMe.py
+++ b/pyload/plugins/account/OverLoadMe.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/PremiumTo.py b/pyload/plugins/account/PremiumTo.py
index 2943ba41c..f7a00e194 100644
--- a/pyload/plugins/account/PremiumTo.py
+++ b/pyload/plugins/account/PremiumTo.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class PremiumTo(Account):
diff --git a/pyload/plugins/account/PremiumizeMe.py b/pyload/plugins/account/PremiumizeMe.py
index 4071e0ad2..5f972ca8b 100644
--- a/pyload/plugins/account/PremiumizeMe.py
+++ b/pyload/plugins/account/PremiumizeMe.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/QuickshareCz.py b/pyload/plugins/account/QuickshareCz.py
index 18af5f736..40bf9d06d 100644
--- a/pyload/plugins/account/QuickshareCz.py
+++ b/pyload/plugins/account/QuickshareCz.py
@@ -2,7 +2,7 @@
import re
-from module.plugins.Account import Account
+from pyload.plugins.internal.Account import Account
class QuickshareCz(Account):
diff --git a/pyload/plugins/account/RPNetBiz.py b/pyload/plugins/account/RPNetBiz.py
index 442355a8c..417ca14a4 100644
--- a/pyload/plugins/account/RPNetBiz.py
+++ b/pyload/plugins/account/RPNetBiz.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/RapidfileshareNet.py b/pyload/plugins/account/RapidfileshareNet.py
new file mode 100644
index 000000000..503c731fe
--- /dev/null
+++ b/pyload/plugins/account/RapidfileshareNet.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSAccount import XFSAccount
+
+
+class RapidfileshareNet(XFSAccount):
+ __name__ = "RapidfileshareNet"
+ __type__ = "account"
+ __version__ = "0.05"
+
+ __description__ = """Rapidfileshare.net account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("guidobelix", "guidobelix@hotmail.it")]
+
+
+ HOSTER_DOMAIN = "rapidfileshare.net"
+
+ TRAFFIC_LEFT_PATTERN = r'>Traffic available today:</TD><TD><label for="name">\s*(?P<S>[\d.,]+)\s*(?:(?P<U>[\w^_]+))?'
diff --git a/pyload/plugins/account/RapidgatorNet.py b/pyload/plugins/account/RapidgatorNet.py
index ec308e63c..72a46a928 100644
--- a/pyload/plugins/account/RapidgatorNet.py
+++ b/pyload/plugins/account/RapidgatorNet.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/RapidshareCom.py b/pyload/plugins/account/RapidshareCom.py
index 9ebb9a568..778b0c55d 100644
--- a/pyload/plugins/account/RapidshareCom.py
+++ b/pyload/plugins/account/RapidshareCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class RapidshareCom(Account):
diff --git a/pyload/plugins/account/RarefileNet.py b/pyload/plugins/account/RarefileNet.py
index 577a6c8f6..0d5547e57 100644
--- a/pyload/plugins/account/RarefileNet.py
+++ b/pyload/plugins/account/RarefileNet.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class RarefileNet(XFSAccount):
diff --git a/pyload/plugins/account/RealdebridCom.py b/pyload/plugins/account/RealdebridCom.py
index ef96cca89..b7773d9a0 100644
--- a/pyload/plugins/account/RealdebridCom.py
+++ b/pyload/plugins/account/RealdebridCom.py
@@ -2,7 +2,7 @@
import xml.dom.minidom as dom
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class RealdebridCom(Account):
diff --git a/pyload/plugins/account/RehostTo.py b/pyload/plugins/account/RehostTo.py
index 6896555bf..e8ee3ba15 100644
--- a/pyload/plugins/account/RehostTo.py
+++ b/pyload/plugins/account/RehostTo.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class RehostTo(Account):
diff --git a/pyload/plugins/account/RyushareCom.py b/pyload/plugins/account/RyushareCom.py
index ca476366b..47ec32c76 100644
--- a/pyload/plugins/account/RyushareCom.py
+++ b/pyload/plugins/account/RyushareCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class RyushareCom(XFSAccount):
diff --git a/pyload/plugins/account/SecureUploadEu.py b/pyload/plugins/account/SecureUploadEu.py
index b335c94da..c98ab2de9 100644
--- a/pyload/plugins/account/SecureUploadEu.py
+++ b/pyload/plugins/account/SecureUploadEu.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class SecureUploadEu(XFSAccount):
diff --git a/pyload/plugins/account/SendmywayCom.py b/pyload/plugins/account/SendmywayCom.py
index 4fcbe0b7a..6749e6215 100644
--- a/pyload/plugins/account/SendmywayCom.py
+++ b/pyload/plugins/account/SendmywayCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class SendmywayCom(XFSAccount):
diff --git a/pyload/plugins/account/ShareonlineBiz.py b/pyload/plugins/account/ShareonlineBiz.py
index 31242e563..cc411ad72 100644
--- a/pyload/plugins/account/ShareonlineBiz.py
+++ b/pyload/plugins/account/ShareonlineBiz.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class ShareonlineBiz(Account):
diff --git a/pyload/plugins/account/SimplyPremiumCom.py b/pyload/plugins/account/SimplyPremiumCom.py
index fd626b43c..45b4263ae 100644
--- a/pyload/plugins/account/SimplyPremiumCom.py
+++ b/pyload/plugins/account/SimplyPremiumCom.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
from pyload.utils import json_loads
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class SimplyPremiumCom(Account):
diff --git a/pyload/plugins/account/SimplydebridCom.py b/pyload/plugins/account/SimplydebridCom.py
index a92e6ca95..636828146 100644
--- a/pyload/plugins/account/SimplydebridCom.py
+++ b/pyload/plugins/account/SimplydebridCom.py
@@ -2,7 +2,7 @@
from time import mktime, strptime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class SimplydebridCom(Account):
diff --git a/pyload/plugins/account/StahnuTo.py b/pyload/plugins/account/StahnuTo.py
index 44884f835..70ef292e7 100644
--- a/pyload/plugins/account/StahnuTo.py
+++ b/pyload/plugins/account/StahnuTo.py
@@ -2,7 +2,7 @@
import re
-from module.plugins.Account import Account
+from pyload.plugins.internal.Account import Account
class StahnuTo(Account):
diff --git a/pyload/plugins/account/StreamcloudEu.py b/pyload/plugins/account/StreamcloudEu.py
index aa1eafcbd..a2a333dd5 100644
--- a/pyload/plugins/account/StreamcloudEu.py
+++ b/pyload/plugins/account/StreamcloudEu.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class StreamcloudEu(XFSAccount):
diff --git a/pyload/plugins/account/TurbobitNet.py b/pyload/plugins/account/TurbobitNet.py
index cb8975158..cb6f36613 100644
--- a/pyload/plugins/account/TurbobitNet.py
+++ b/pyload/plugins/account/TurbobitNet.py
@@ -3,7 +3,7 @@
import re
from time import mktime, strptime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class TurbobitNet(Account):
diff --git a/pyload/plugins/account/TusfilesNet.py b/pyload/plugins/account/TusfilesNet.py
index 552047a64..9aa8ed543 100644
--- a/pyload/plugins/account/TusfilesNet.py
+++ b/pyload/plugins/account/TusfilesNet.py
@@ -4,7 +4,7 @@ import re
from time import mktime, strptime, gmtime
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class TusfilesNet(XFSAccount):
diff --git a/pyload/plugins/account/UlozTo.py b/pyload/plugins/account/UlozTo.py
index fefc334e9..4e663efa9 100644
--- a/pyload/plugins/account/UlozTo.py
+++ b/pyload/plugins/account/UlozTo.py
@@ -4,7 +4,7 @@ import re
from urlparse import urljoin
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class UlozTo(Account):
diff --git a/pyload/plugins/account/UnrestrictLi.py b/pyload/plugins/account/UnrestrictLi.py
index b5ae43d72..88f4841f7 100644
--- a/pyload/plugins/account/UnrestrictLi.py
+++ b/pyload/plugins/account/UnrestrictLi.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
from pyload.utils import json_loads
diff --git a/pyload/plugins/account/UploadcCom.py b/pyload/plugins/account/UploadcCom.py
new file mode 100644
index 000000000..8f437eb01
--- /dev/null
+++ b/pyload/plugins/account/UploadcCom.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSAccount import XFSAccount
+
+
+class UploadcCom(XFSAccount):
+ __name__ = "UploadcCom"
+ __type__ = "account"
+ __version__ = "0.02"
+
+ __description__ = """Uploadc.com account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ HOSTER_DOMAIN = "uploadc.com"
diff --git a/pyload/plugins/account/UploadedTo.py b/pyload/plugins/account/UploadedTo.py
index 0054b60bf..310e23730 100644
--- a/pyload/plugins/account/UploadedTo.py
+++ b/pyload/plugins/account/UploadedTo.py
@@ -3,7 +3,7 @@
import re
from time import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class UploadedTo(Account):
diff --git a/pyload/plugins/account/UploadheroCom.py b/pyload/plugins/account/UploadheroCom.py
index c3a39e5dc..be1d444be 100644
--- a/pyload/plugins/account/UploadheroCom.py
+++ b/pyload/plugins/account/UploadheroCom.py
@@ -4,7 +4,7 @@ import re
import datetime
import time
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class UploadheroCom(Account):
diff --git a/pyload/plugins/account/UploadingCom.py b/pyload/plugins/account/UploadingCom.py
index b5ea91119..dd7ab26cf 100644
--- a/pyload/plugins/account/UploadingCom.py
+++ b/pyload/plugins/account/UploadingCom.py
@@ -4,8 +4,8 @@ import re
from time import time, strptime, mktime
-from pyload.plugins.base.Account import Account
-from module.plugins.internal.SimpleHoster import set_cookies
+from pyload.plugins.internal.Account import Account
+from pyload.plugins.internal.SimpleHoster import set_cookies
class UploadingCom(Account):
diff --git a/pyload/plugins/account/UptoboxCom.py b/pyload/plugins/account/UptoboxCom.py
index d3fb4e559..36f541e96 100644
--- a/pyload/plugins/account/UptoboxCom.py
+++ b/pyload/plugins/account/UptoboxCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class UptoboxCom(XFSAccount):
diff --git a/pyload/plugins/account/VidPlayNet.py b/pyload/plugins/account/VidPlayNet.py
index 5bfc24963..4393b3a82 100644
--- a/pyload/plugins/account/VidPlayNet.py
+++ b/pyload/plugins/account/VidPlayNet.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSAccount import XFSAccount
+from pyload.plugins.internal.XFSAccount import XFSAccount
class VidPlayNet(XFSAccount):
diff --git a/pyload/plugins/account/XFileSharingPro.py b/pyload/plugins/account/XFileSharingPro.py
new file mode 100644
index 000000000..aa16d5045
--- /dev/null
+++ b/pyload/plugins/account/XFileSharingPro.py
@@ -0,0 +1,30 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSAccount import XFSAccount
+
+
+class XFileSharingPro(XFSAccount):
+ __name__ = "XFileSharingPro"
+ __type__ = "account"
+ __version__ = "0.05"
+
+ __description__ = """XFileSharingPro multi-purpose account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ HOSTER_DOMAIN = None
+
+
+ def init(self):
+ if self.HOSTER_DOMAIN:
+ return super(XFileSharingPro, self).init()
+
+
+ def loadAccountInfo(self, user, req):
+ return super(XFileSharingPro if self.HOSTER_DOMAIN else XFSAccount, self).loadAccountInfo(user, req)
+
+
+ def login(self, user, data, req):
+ if self.HOSTER_DOMAIN:
+ return super(XFileSharingPro, self).login(user, data, req)
diff --git a/pyload/plugins/account/YibaishiwuCom.py b/pyload/plugins/account/YibaishiwuCom.py
index d9a9f37ca..06a606bc4 100644
--- a/pyload/plugins/account/YibaishiwuCom.py
+++ b/pyload/plugins/account/YibaishiwuCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class YibaishiwuCom(Account):
diff --git a/pyload/plugins/account/ZeveraCom.py b/pyload/plugins/account/ZeveraCom.py
index 701198c84..dfd4f29f5 100644
--- a/pyload/plugins/account/ZeveraCom.py
+++ b/pyload/plugins/account/ZeveraCom.py
@@ -2,7 +2,7 @@
from time import mktime, strptime
-from pyload.plugins.base.Account import Account
+from pyload.plugins.internal.Account import Account
class ZeveraCom(Account):
diff --git a/pyload/plugins/addon/Checksum.py b/pyload/plugins/addon/Checksum.py
index 00c3d9cfd..4c5bb39ef 100644
--- a/pyload/plugins/addon/Checksum.py
+++ b/pyload/plugins/addon/Checksum.py
@@ -9,7 +9,7 @@ import zlib
from os import remove
from os.path import getsize, isfile, splitext
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
from pyload.utils import safe_join, fs_encode
diff --git a/pyload/plugins/addon/ClickAndLoad.py b/pyload/plugins/addon/ClickAndLoad.py
index c45a1ef2d..63f82ad9b 100644
--- a/pyload/plugins/addon/ClickAndLoad.py
+++ b/pyload/plugins/addon/ClickAndLoad.py
@@ -3,7 +3,7 @@
import socket
import thread
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
def proxy(self, *settings):
diff --git a/pyload/plugins/addon/DeleteFinished.py b/pyload/plugins/addon/DeleteFinished.py
index 719de143a..c21b0a589 100644
--- a/pyload/plugins/addon/DeleteFinished.py
+++ b/pyload/plugins/addon/DeleteFinished.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
from pyload.database import style
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
class DeleteFinished(Addon):
diff --git a/pyload/plugins/addon/DownloadScheduler.py b/pyload/plugins/addon/DownloadScheduler.py
index ef15a859f..9ca4609a6 100644
--- a/pyload/plugins/addon/DownloadScheduler.py
+++ b/pyload/plugins/addon/DownloadScheduler.py
@@ -4,7 +4,7 @@ import re
from time import localtime
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
class DownloadScheduler(Addon):
diff --git a/pyload/plugins/addon/ExternalScripts.py b/pyload/plugins/addon/ExternalScripts.py
index 122de00c5..5aff0f11f 100644
--- a/pyload/plugins/addon/ExternalScripts.py
+++ b/pyload/plugins/addon/ExternalScripts.py
@@ -6,7 +6,7 @@ from itertools import chain
from os import listdir, access, X_OK, makedirs
from os.path import join, exists, basename, abspath
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
from pyload.utils import safe_join
diff --git a/pyload/plugins/addon/ExtractArchive.py b/pyload/plugins/addon/ExtractArchive.py
index a53d2f951..6946190ed 100644
--- a/pyload/plugins/addon/ExtractArchive.py
+++ b/pyload/plugins/addon/ExtractArchive.py
@@ -49,7 +49,7 @@ if os.name != "nt":
from os import chown
from pwd import getpwnam
-from pyload.plugins.base.Addon import Addon, threaded, Expose
+from pyload.plugins.internal.Addon import Addon, threaded, Expose
from pyload.plugins.internal.AbstractExtractor import ArchiveError, CRCError, WrongPassword
from pyload.utils import safe_join, fs_encode
diff --git a/pyload/plugins/addon/HotFolder.py b/pyload/plugins/addon/HotFolder.py
index 0bce193ce..491b9e2da 100644
--- a/pyload/plugins/addon/HotFolder.py
+++ b/pyload/plugins/addon/HotFolder.py
@@ -6,8 +6,8 @@ from os import listdir, makedirs
from os.path import exists, isfile, join
from shutil import move
-from pyload.plugins.base.Addon import Addon
-from module.utils import fs_encode, save_join
+from pyload.plugins.internal.Addon import Addon
+from pyload.utils import fs_encode, safe_join
class HotFolder(Addon):
@@ -43,7 +43,7 @@ class HotFolder(Addon):
if content:
name = "%s_%s.txt" % (self.getConfig("file"), time.strftime("%H-%M-%S_%d%b%Y"))
- with open(save_join(folder, "finished", name), "wb") as f:
+ with open(safe_join(folder, "finished", name), "wb") as f:
f.write(content)
self.core.api.addPackage(f.name, [f.name], 1)
diff --git a/pyload/plugins/addon/IRCInterface.py b/pyload/plugins/addon/IRCInterface.py
index 041c8b07b..d06dad07f 100644
--- a/pyload/plugins/addon/IRCInterface.py
+++ b/pyload/plugins/addon/IRCInterface.py
@@ -13,7 +13,7 @@ from traceback import print_exc
from pyload.api import PackageDoesNotExists, FileDoesNotExists
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
from pyload.utils import formatSize
diff --git a/pyload/plugins/addon/MergeFiles.py b/pyload/plugins/addon/MergeFiles.py
index e67f87f56..2483135f4 100644
--- a/pyload/plugins/addon/MergeFiles.py
+++ b/pyload/plugins/addon/MergeFiles.py
@@ -5,7 +5,7 @@ import re
from traceback import print_exc
-from pyload.plugins.base.Addon import Addon, threaded
+from pyload.plugins.internal.Addon import Addon, threaded
from pyload.utils import safe_join, fs_encode
diff --git a/pyload/plugins/addon/MultiHome.py b/pyload/plugins/addon/MultiHome.py
index a808802ba..e7ae5168c 100644
--- a/pyload/plugins/addon/MultiHome.py
+++ b/pyload/plugins/addon/MultiHome.py
@@ -2,7 +2,7 @@
from time import time
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
class MultiHome(Addon):
diff --git a/pyload/plugins/addon/RestartFailed.py b/pyload/plugins/addon/RestartFailed.py
index 879836bcf..7405e2f75 100644
--- a/pyload/plugins/addon/RestartFailed.py
+++ b/pyload/plugins/addon/RestartFailed.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
class RestartFailed(Addon):
diff --git a/pyload/plugins/addon/UnSkipOnFail.py b/pyload/plugins/addon/UnSkipOnFail.py
index 5122e21eb..1a064562f 100644
--- a/pyload/plugins/addon/UnSkipOnFail.py
+++ b/pyload/plugins/addon/UnSkipOnFail.py
@@ -3,7 +3,7 @@
from os.path import basename
from pyload.datatypes.PyFile import PyFile
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
from pyload.utils import fs_encode
diff --git a/pyload/plugins/addon/WindowsPhoneToastNotify.py b/pyload/plugins/addon/WindowsPhoneToastNotify.py
index e35f74e84..abcd6c55c 100644
--- a/pyload/plugins/addon/WindowsPhoneToastNotify.py
+++ b/pyload/plugins/addon/WindowsPhoneToastNotify.py
@@ -3,7 +3,7 @@
import httplib
import time
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
class WindowsPhoneToastNotify(Addon):
diff --git a/pyload/plugins/base/Hook.py b/pyload/plugins/base/Hook.py
deleted file mode 100644
index 5cd528b7e..000000000
--- a/pyload/plugins/base/Hook.py
+++ /dev/null
@@ -1,166 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from traceback import print_exc
-
-from pyload.plugins.Plugin import Base
-
-
-class Expose(object):
- """ used for decoration to declare rpc services """
-
- def __new__(cls, f, *args, **kwargs):
- addonManager.addRPC(f.__module__, f.func_name, f.func_doc)
- return f
-
-
-def threaded(f):
-
- def run(*args,**kwargs):
- addonManager.startThread(f, *args, **kwargs)
- return run
-
-
-class Hook(Base):
- """
- Base class for hook plugins.
- """
- __name__ = "Hook"
- __type__ = "hook"
- __version__ = "0.03"
-
- __config__ = [] #: [("name", "type", "desc", "default")]
-
- __description__ = """Interface for hook"""
- __license__ = "GPLv3"
- __authors__ = [("mkaay", "mkaay@mkaay.de"),
- ("RaNaN", "RaNaN@pyload.org")]
-
-
- #: automatically register event listeners for functions, attribute will be deleted dont use it yourself
- event_map = None
-
- # Alternative to event_map
- #: List of events the plugin can handle, name the functions exactly like eventname.
- event_list = None # dont make duplicate entries in event_map
-
- #: periodic call interval in secondc
- interval = 60
-
-
- def __init__(self, core, manager):
- Base.__init__(self, core)
-
- #: Provide information in dict here, usable by API `getInfo`
- self.info = {}
-
- #: Callback of periodical job task, used by AddonManager
- self.cb = None
-
- #: `AddonManager`
- self.manager = manager
-
- #register events
- if self.event_map:
- for event, funcs in self.event_map.iteritems():
- if type(funcs) in (list, tuple):
- for f in funcs:
- self.manager.addEvent(event, getattr(self,f))
- else:
- self.manager.addEvent(event, getattr(self,funcs))
-
- #delete for various reasons
- self.event_map = None
-
- if self.event_list:
- for f in self.event_list:
- self.manager.addEvent(f, getattr(self,f))
-
- self.event_list = None
-
- self.setup()
- self.initPeriodical()
-
-
- def initPeriodical(self):
- if self.interval >=1:
- self.cb = self.core.scheduler.addJob(0, self._periodical, threaded=False)
-
-
- def _periodical(self):
- try:
- if self.isActivated(): self.periodical()
- except Exception, e:
- self.logError(_("Error executing hook: %s") % e)
- if self.core.debug:
- print_exc()
-
- self.cb = self.core.scheduler.addJob(self.interval, self._periodical, threaded=False)
-
-
- def __repr__(self):
- return "<Hook %s>" % self.__name__
-
-
- def setup(self):
- """ more init stuff if needed """
- pass
-
-
- def unload(self):
- """ called when hook was deactivated """
- pass
-
-
- def isActivated(self):
- """ checks if hook is activated"""
- return self.config.getPlugin(self.__name__, "activated")
-
-
- #event methods - overwrite these if needed
- def coreReady(self):
- pass
-
-
- def coreExiting(self):
- pass
-
-
- def downloadPreparing(self, pyfile):
- pass
-
-
- def downloadFinished(self, pyfile):
- pass
-
-
- def downloadFailed(self, pyfile):
- pass
-
-
- def packageFinished(self, pypack):
- pass
-
-
- def beforeReconnecting(self, ip):
- pass
-
-
- def afterReconnecting(self, ip):
- pass
-
-
- def periodical(self):
- pass
-
-
- def newCaptchaTask(self, task):
- """ new captcha task for the plugin, it MUST set the handler and timeout or will be ignored """
- pass
-
-
- def captchaCorrect(self, task):
- pass
-
-
- def captchaInvalid(self, task):
- pass
diff --git a/pyload/plugins/base/__init__.py b/pyload/plugins/base/__init__.py
deleted file mode 100644
index e69de29bb..000000000
--- a/pyload/plugins/base/__init__.py
+++ /dev/null
diff --git a/pyload/plugins/captcha/AdsCaptcha.py b/pyload/plugins/captcha/AdsCaptcha.py
index 8d4e12e28..4eabfbf9b 100644
--- a/pyload/plugins/captcha/AdsCaptcha.py
+++ b/pyload/plugins/captcha/AdsCaptcha.py
@@ -4,19 +4,21 @@ import re
from random import random
-from pyload.plugins.base.Captcha import Captcha
+from pyload.plugins.internal.Captcha import Captcha
class AdsCaptcha(Captcha):
- __name__ = "AdsCaptcha"
- __version__ = "0.02"
+ __name__ = "AdsCaptcha"
+ __type__ = "captcha"
+ __version__ = "0.04"
__description__ = """AdsCaptcha captcha service plugin"""
- __authors__ = [("pyLoad Team", "admin@pyload.org")]
+ __license__ = "GPLv3"
+ __authors__ = [("pyLoad Team", "admin@pyload.org")]
- ID_PATTERN = r'http://api\.adscaptcha\.com/Get\.aspx\?[^"\']*CaptchaId=(?P<ID>\d+)'
- KEY_PATTERN = r'http://api\.adscaptcha\.com/Get\.aspx\?[^"\']*PublicKey=(?P<KEY>[\w-]+)'
+ ID_PATTERN = r'api\.adscaptcha\.com/Get\.aspx\?[^"\']*CaptchaId=(?P<ID>\d+)'
+ KEY_PATTERN = r'api\.adscaptcha\.com/Get\.aspx\?[^"\']*PublicKey=(?P<KEY>[\w-]+)'
def detect_key(self, html=None):
@@ -24,7 +26,7 @@ class AdsCaptcha(Captcha):
if hasattr(self.plugin, "html") and self.plugin.html:
html = self.plugin.html
else:
- errmsg = "AdsCaptcha html missing"
+ errmsg = _("AdsCaptcha html not found")
self.plugin.fail(errmsg)
raise TypeError(errmsg)
@@ -39,24 +41,24 @@ class AdsCaptcha(Captcha):
return None
- def challenge(self, key=None): #: key is tuple(CaptchaId, PublicKey)
+ def challenge(self, key=None): #: key is a tuple(CaptchaId, PublicKey)
if not key:
- if self.key:
+ if self.detect_key():
key = self.key
else:
- errmsg = "AdsCaptcha key missing"
+ errmsg = _("AdsCaptcha key not found")
self.plugin.fail(errmsg)
raise TypeError(errmsg)
CaptchaId, PublicKey = key
- js = self.plugin.req.load("http://api.adscaptcha.com/Get.aspx", get={'CaptchaId': CaptchaId, 'PublicKey': PublicKey}, cookies=True)
+ js = self.plugin.req.load("http://api.adscaptcha.com/Get.aspx", get={'CaptchaId': CaptchaId, 'PublicKey': PublicKey})
try:
challenge = re.search("challenge: '(.+?)',", js).group(1)
server = re.search("server: '(.+?)',", js).group(1)
except:
- self.plugin.parseError("AdsCaptcha challenge pattern not found")
+ self.plugin.error("AdsCaptcha challenge pattern not found")
result = self.result(server, challenge)
diff --git a/pyload/plugins/captcha/ReCaptcha.py b/pyload/plugins/captcha/ReCaptcha.py
index 445f6b361..d68584c9d 100644
--- a/pyload/plugins/captcha/ReCaptcha.py
+++ b/pyload/plugins/captcha/ReCaptcha.py
@@ -2,19 +2,21 @@
import re
-from pyload.plugins.base.Captcha import Captcha
+from pyload.plugins.internal.Captcha import Captcha
class ReCaptcha(Captcha):
- __name__ = "ReCaptcha"
- __version__ = "0.02"
+ __name__ = "ReCaptcha"
+ __type__ = "captcha"
+ __version__ = "0.07"
__description__ = """ReCaptcha captcha service plugin"""
- __authors__ = [("pyLoad Team", "admin@pyload.org")]
+ __license__ = "GPLv3"
+ __authors__ = [("pyLoad Team", "admin@pyload.org")]
- KEY_PATTERN = r"https?://(?:www\.)?google\.com/recaptcha/api/challenge\?k=(?P<KEY>\w+?)"
- KEY_AJAX_PATTERN = r"Recaptcha\.create\s*\(\s*[\"'](?P<KEY>\w+)[\"']\s*,"
+ KEY_PATTERN = r'recaptcha(/api|\.net)/(challenge|noscript)\?k=(?P<KEY>[\w-]+)'
+ KEY_AJAX_PATTERN = r'Recaptcha\.create\s*\(\s*["\'](?P<KEY>[\w-]+)'
def detect_key(self, html=None):
@@ -22,13 +24,11 @@ class ReCaptcha(Captcha):
if hasattr(self.plugin, "html") and self.plugin.html:
html = self.plugin.html
else:
- errmsg = "ReCaptcha html missing"
+ errmsg = _("ReCaptcha html not found")
self.plugin.fail(errmsg)
raise TypeError(errmsg)
- m = re.search(self.KEY_PATTERN, html)
- if m is None:
- m = re.search(self.KEY_AJAX_PATTERN, html)
+ m = re.search(self.KEY_PATTERN, html) or re.search(self.KEY_AJAX_PATTERN, html)
if m:
self.key = m.group("KEY")
self.plugin.logDebug("ReCaptcha key: %s" % self.key)
@@ -40,20 +40,20 @@ class ReCaptcha(Captcha):
def challenge(self, key=None):
if not key:
- if self.key:
+ if self.detect_key():
key = self.key
else:
- errmsg = "ReCaptcha key missing"
+ errmsg = _("ReCaptcha key not found")
self.plugin.fail(errmsg)
raise TypeError(errmsg)
- js = self.plugin.req.load("http://www.google.com/recaptcha/api/challenge", get={'k': key}, cookies=True)
+ js = self.plugin.req.load("http://www.google.com/recaptcha/api/challenge", get={'k': key})
try:
challenge = re.search("challenge : '(.+?)',", js).group(1)
server = re.search("server : '(.+?)',", js).group(1)
except:
- self.plugin.parseError("ReCaptcha challenge pattern not found")
+ self.plugin.error("ReCaptcha challenge pattern not found")
result = self.result(server, challenge)
diff --git a/pyload/plugins/captcha/SolveMedia.py b/pyload/plugins/captcha/SolveMedia.py
index c8e87bb7a..d1b9eba6a 100644
--- a/pyload/plugins/captcha/SolveMedia.py
+++ b/pyload/plugins/captcha/SolveMedia.py
@@ -2,36 +2,38 @@
import re
-from pyload.plugins.base.Captcha import Captcha
+from pyload.plugins.internal.Captcha import Captcha
class SolveMedia(Captcha):
- __name__ = "SolveMedia"
- __version__ = "0.02"
+ __name__ = "SolveMedia"
+ __type__ = "captcha"
+ __version__ = "0.05"
__description__ = """SolveMedia captcha service plugin"""
- __authors__ = [("pyLoad Team", "admin@pyload.org")]
+ __license__ = "GPLv3"
+ __authors__ = [("pyLoad Team", "admin@pyload.org")]
- KEY_PATTERN = r'http://api\.solvemedia\.com/papi/challenge\.(no)?script\?k=(?P<KEY>.+?)"'
+ KEY_PATTERN = r'api\.solvemedia\.com/papi/challenge\.(no)?script\?k=(?P<KEY>.+?)["\']'
def challenge(self, key=None):
if not key:
- if self.key:
+ if self.detect_key():
key = self.key
else:
- errmsg = "SolveMedia key missing"
+ errmsg = _("SolveMedia key not found")
self.plugin.fail(errmsg)
raise TypeError(errmsg)
- html = self.plugin.req.load("http://api.solvemedia.com/papi/challenge.noscript", get={'k': key}, cookies=True)
+ html = self.plugin.req.load("http://api.solvemedia.com/papi/challenge.noscript", get={'k': key})
try:
challenge = re.search(r'<input type=hidden name="adcopy_challenge" id="adcopy_challenge" value="([^"]+)">',
html).group(1)
server = "http://api.solvemedia.com/papi/media"
except:
- self.plugin.parseError("SolveMedia challenge pattern not found")
+ self.plugin.error("SolveMedia challenge pattern not found")
result = self.result(server, challenge)
diff --git a/pyload/plugins/container/CCF.py b/pyload/plugins/container/CCF.py
index b21339bec..98533cbd8 100644
--- a/pyload/plugins/container/CCF.py
+++ b/pyload/plugins/container/CCF.py
@@ -8,7 +8,7 @@ from urllib2 import build_opener
from MultipartPostHandler import MultipartPostHandler
-from pyload.plugins.base.Container import Container
+from pyload.plugins.internal.Container import Container
from pyload.utils import safe_join
diff --git a/pyload/plugins/container/LinkList.py b/pyload/plugins/container/LinkList.py
index 621574ab1..b66e44558 100644
--- a/pyload/plugins/container/LinkList.py
+++ b/pyload/plugins/container/LinkList.py
@@ -2,7 +2,7 @@
import codecs
-from pyload.plugins.base.Container import Container
+from pyload.plugins.internal.Container import Container
from pyload.utils import fs_encode
diff --git a/pyload/plugins/container/RSDF.py b/pyload/plugins/container/RSDF.py
index 14f355e85..67325f20d 100644
--- a/pyload/plugins/container/RSDF.py
+++ b/pyload/plugins/container/RSDF.py
@@ -4,8 +4,8 @@ import base64
import binascii
import re
-from pyload.plugins.base.Container import Container
-from module.utils import fs_encode
+from pyload.plugins.internal.Container import Container
+from pyload.utils import fs_encode
class RSDF(Container):
diff --git a/pyload/plugins/crypter/ChipDe.py b/pyload/plugins/crypter/ChipDe.py
index 97a39f6d2..96892bace 100644
--- a/pyload/plugins/crypter/ChipDe.py
+++ b/pyload/plugins/crypter/ChipDe.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class ChipDe(Crypter):
diff --git a/pyload/plugins/crypter/CzshareComFolder.py b/pyload/plugins/crypter/CzshareComFolder.py
index 23c17e64a..bfca84360 100644
--- a/pyload/plugins/crypter/CzshareComFolder.py
+++ b/pyload/plugins/crypter/CzshareComFolder.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class CzshareComFolder(Crypter):
diff --git a/pyload/plugins/crypter/DDLMusicOrg.py b/pyload/plugins/crypter/DDLMusicOrg.py
index ff2faef2c..348c2db51 100644
--- a/pyload/plugins/crypter/DDLMusicOrg.py
+++ b/pyload/plugins/crypter/DDLMusicOrg.py
@@ -4,7 +4,7 @@ import re
from time import sleep
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class DDLMusicOrg(Crypter):
diff --git a/pyload/plugins/crypter/DailymotionBatch.py b/pyload/plugins/crypter/DailymotionBatch.py
index fd43cd49a..4ea26a830 100644
--- a/pyload/plugins/crypter/DailymotionBatch.py
+++ b/pyload/plugins/crypter/DailymotionBatch.py
@@ -5,7 +5,7 @@ import re
from urlparse import urljoin
from pyload.utils import json_loads
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.utils import safe_join
diff --git a/pyload/plugins/crypter/Dereferer.py b/pyload/plugins/crypter/Dereferer.py
index 41da3dc1e..4a647a952 100644
--- a/pyload/plugins/crypter/Dereferer.py
+++ b/pyload/plugins/crypter/Dereferer.py
@@ -4,7 +4,7 @@ import re
from urllib import unquote
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class Dereferer(Crypter):
diff --git a/pyload/plugins/crypter/DontKnowMe.py b/pyload/plugins/crypter/DontKnowMe.py
index 53a1b3997..0e63233e8 100644
--- a/pyload/plugins/crypter/DontKnowMe.py
+++ b/pyload/plugins/crypter/DontKnowMe.py
@@ -4,7 +4,7 @@ import re
from urllib import unquote
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class DontKnowMe(Crypter):
diff --git a/pyload/plugins/crypter/DuckCryptInfo.py b/pyload/plugins/crypter/DuckCryptInfo.py
index 6873fd5d3..054783f3c 100644
--- a/pyload/plugins/crypter/DuckCryptInfo.py
+++ b/pyload/plugins/crypter/DuckCryptInfo.py
@@ -4,7 +4,7 @@ import re
from BeautifulSoup import BeautifulSoup
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class DuckCryptInfo(Crypter):
diff --git a/pyload/plugins/crypter/DuploadOrgFolder.py b/pyload/plugins/crypter/DuploadOrgFolder.py
index af83dffd0..138db9f03 100644
--- a/pyload/plugins/crypter/DuploadOrgFolder.py
+++ b/pyload/plugins/crypter/DuploadOrgFolder.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.DeadCrypter import DeadCrypter
+from pyload.plugins.internal.DeadCrypter import DeadCrypter
class DuploadOrgFolder(DeadCrypter):
diff --git a/pyload/plugins/crypter/EasybytezComFolder.py b/pyload/plugins/crypter/EasybytezComFolder.py
index fa3e6165c..482ce594b 100644
--- a/pyload/plugins/crypter/EasybytezComFolder.py
+++ b/pyload/plugins/crypter/EasybytezComFolder.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSCrypter import XFSCrypter
+from pyload.plugins.internal.XFSCrypter import XFSCrypter
class EasybytezComFolder(XFSCrypter):
diff --git a/pyload/plugins/crypter/EmbeduploadCom.py b/pyload/plugins/crypter/EmbeduploadCom.py
index 136d99f9e..c6649890f 100644
--- a/pyload/plugins/crypter/EmbeduploadCom.py
+++ b/pyload/plugins/crypter/EmbeduploadCom.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.network.HTTPRequest import BadHeader
diff --git a/pyload/plugins/crypter/FileserveComFolder.py b/pyload/plugins/crypter/FileserveComFolder.py
index d601e2365..c08e174ed 100644
--- a/pyload/plugins/crypter/FileserveComFolder.py
+++ b/pyload/plugins/crypter/FileserveComFolder.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class FileserveComFolder(Crypter):
diff --git a/pyload/plugins/crypter/FilesonicComFolder.py b/pyload/plugins/crypter/FilesonicComFolder.py
new file mode 100644
index 000000000..992915ab5
--- /dev/null
+++ b/pyload/plugins/crypter/FilesonicComFolder.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadCrypter import DeadCrypter
+
+
+class FilesonicComFolder(DeadCrypter):
+ __name__ = "FilesonicComFolder"
+ __type__ = "crypter"
+ __version__ = "0.12"
+
+ __pattern__ = r'http://(?:www\.)?filesonic\.com/folder/\w+'
+
+ __description__ = """Filesonic.com folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
diff --git a/pyload/plugins/crypter/FiredriveComFolder.py b/pyload/plugins/crypter/FiredriveComFolder.py
index b6b22a4e1..f6e6b8670 100644
--- a/pyload/plugins/crypter/FiredriveComFolder.py
+++ b/pyload/plugins/crypter/FiredriveComFolder.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.DeadCrypter import DeadCrypter
+from pyload.plugins.internal.DeadCrypter import DeadCrypter
class FiredriveComFolder(DeadCrypter):
diff --git a/pyload/plugins/crypter/FourChanOrg.py b/pyload/plugins/crypter/FourChanOrg.py
index c418d20b0..37d205f73 100644
--- a/pyload/plugins/crypter/FourChanOrg.py
+++ b/pyload/plugins/crypter/FourChanOrg.py
@@ -4,7 +4,7 @@
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class FourChanOrg(Crypter):
diff --git a/pyload/plugins/crypter/GooGl.py b/pyload/plugins/crypter/GooGl.py
index b3e55688e..b5fb40f34 100644
--- a/pyload/plugins/crypter/GooGl.py
+++ b/pyload/plugins/crypter/GooGl.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.utils import json_loads
diff --git a/pyload/plugins/crypter/HoerbuchIn.py b/pyload/plugins/crypter/HoerbuchIn.py
index f8185275a..fa409a94c 100644
--- a/pyload/plugins/crypter/HoerbuchIn.py
+++ b/pyload/plugins/crypter/HoerbuchIn.py
@@ -4,7 +4,7 @@ import re
from BeautifulSoup import BeautifulSoup, BeautifulStoneSoup
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class HoerbuchIn(Crypter):
diff --git a/pyload/plugins/crypter/HotfileComFolder.py b/pyload/plugins/crypter/HotfileComFolder.py
new file mode 100644
index 000000000..1ce901866
--- /dev/null
+++ b/pyload/plugins/crypter/HotfileComFolder.py
@@ -0,0 +1,16 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadCrypter import DeadCrypter
+
+
+class HotfileComFolder(DeadCrypter):
+ __name__ = "HotfileComFolder"
+ __type__ = "crypter"
+ __version__ = "0.3"
+
+ __pattern__ = r'https?://(?:www\.)?hotfile\.com/list/\w+/\w+'
+ __config__ = []
+
+ __description__ = """Hotfile.com folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("RaNaN", "RaNaN@pyload.org")]
diff --git a/pyload/plugins/crypter/JunocloudMeFolder.py b/pyload/plugins/crypter/JunocloudMeFolder.py
new file mode 100644
index 000000000..2e529169f
--- /dev/null
+++ b/pyload/plugins/crypter/JunocloudMeFolder.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSCrypter import XFSCrypter
+
+
+class JunocloudMeFolder(XFSCrypter):
+ __name__ = "JunocloudMeFolder"
+ __type__ = "crypter"
+ __version__ = "0.03"
+
+ __pattern__ = r'http://(?:www\.)?junocloud\.me/folders/(?P<ID>\d+/\w+)'
+ __config__ = [("use_subfolder", "bool", "Save package to subfolder", True),
+ ("subfolder_per_package", "bool", "Create a subfolder for each package", True)]
+
+ __description__ = """Junocloud.me folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("guidobelix", "guidobelix@hotmail.it")]
+
+
+ HOSTER_DOMAIN = "junocloud.me"
diff --git a/pyload/plugins/crypter/LetitbitNetFolder.py b/pyload/plugins/crypter/LetitbitNetFolder.py
index b2e1d7f7b..09e6c398d 100644
--- a/pyload/plugins/crypter/LetitbitNetFolder.py
+++ b/pyload/plugins/crypter/LetitbitNetFolder.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class LetitbitNetFolder(Crypter):
diff --git a/pyload/plugins/crypter/LinkCryptWs.py b/pyload/plugins/crypter/LinkCryptWs.py
new file mode 100644
index 000000000..bbcef02fd
--- /dev/null
+++ b/pyload/plugins/crypter/LinkCryptWs.py
@@ -0,0 +1,341 @@
+# -*- coding: utf-8 -*-
+
+import base64
+import binascii
+import re
+
+import pycurl
+
+from Crypto.Cipher import AES
+
+from pyload.plugins.internal.Crypter import Crypter
+from pyload.utils import html_unescape
+
+
+class LinkCryptWs(Crypter):
+ __name__ = "LinkCryptWs"
+ __type__ = "crypter"
+ __version__ = "0.05"
+
+ __pattern__ = r'http://(?:www\.)?linkcrypt\.ws/(dir|container)/(?P<ID>\w+)'
+
+ __description__ = """LinkCrypt.ws decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("kagenoshin", "kagenoshin[AT]gmx[DOT]ch"),
+ ("glukgluk", None)]
+
+
+ JK_KEY = "jk"
+ CRYPTED_KEY = "crypted"
+
+
+ def setup(self):
+ self.html = None
+ self.fileid = None
+ self.captcha = False
+ self.package = None
+
+ self.preferred_sources = ['cnl', 'web', 'dlc', 'rsdf', 'ccf', ] #['cnl', 'rsdf', 'ccf', 'dlc', 'web']
+
+
+ def prepare(self):
+ # Init
+ self.package = pyfile.package()
+ self.fileid = re.match(self.__pattern__, pyfile.url).group('ID')
+
+ self.req.cj.setCookie(".linkcrypt.ws", "language", "en")
+
+ # Request package
+ self.req.http.c.setopt(pycurl.USERAGENT, "Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; rv:11.0) like Gecko") #: better chance to not get those key-captchas
+ self.html = self.load(self.pyfile.url)
+
+
+ def decrypt(self, pyfile):
+ #check if we have js
+ if not self.js:
+ self.fail(_("Missing JS Engine"))
+
+ package_found = None
+
+ self.prepare()
+
+ if not self.isOnline():
+ self.offline()
+
+ if self.isKeyCaptchaProtected():
+ self.retry(4, 30, _("Can't handle Key-Captcha"))
+
+ if self.isCaptchaProtected():
+ self.captcha = True
+ self.unlockCaptchaProtection()
+ self.handleCaptchaErrors()
+
+ # Check for protection
+ if self.isPasswordProtected():
+ self.unlockPasswordProtection()
+ self.handleErrors()
+
+ # get unrar password
+ self.getunrarpw()
+
+ # Get package name and folder
+ package_name, folder_name = self.getPackageInfo()
+
+ #get the container definitions from script section
+ self.get_container_html()
+
+ # Extract package links
+ package_links = []
+
+ for type_ in self.preferred_sources:
+ links = self.handleLinkSource(type_)
+ if links:
+ if isinstance(links, list):
+ package_links.extend(links)
+ else:
+ package_found = True
+ break
+
+ # Pack
+ if package_links:
+ self.packages = [(package_name, package_links, folder_name)]
+
+ elif package_found:
+ self.core.api.deletePackages([self.package.id])
+
+
+ def isOnline(self):
+ if "<title>Linkcrypt.ws // Error 404</title>" in self.html:
+ self.logDebug("folder doesen't exist anymore")
+ return False
+ else:
+ return True
+
+
+ def isPasswordProtected(self):
+ if "Authorizing" in self.html:
+ self.logDebug("Links are password protected")
+ return True
+ else:
+ return False
+
+
+ def isCaptchaProtected(self):
+ if 'id="captcha">' in self.html:
+ self.logDebug("Links are captcha protected")
+ return True
+ else:
+ return False
+
+
+ def isKeyCaptchaProtected(self):
+ if re.search(r'Key[ -]', self.html, re.I):
+ return True
+ else:
+ return False
+
+
+ def unlockPasswordProtection(self):
+ password = self.getPassword()
+
+ if password:
+ self.logDebug("Submitting password [%s] for protected links" % password)
+ self.html = self.load(self.pyfile.url, post={"password": password, 'x': "0", 'y': "0"})
+ else:
+ self.fail(_("Folder is password protected"))
+
+
+ def unlockCaptchaProtection(self):
+ captcha_url = re.search(r'<form.*?id\s*?=\s*?"captcha"[^>]*?>.*?<\s*?input.*?src="([^"]*?)"', self.html, re.I | re.S).group(1)
+ captcha_code = self.decryptCaptcha(captcha_url, forceUser=True, imgtype="gif", result_type='positional')
+
+ self.html = self.load(self.pyfile.url, post={"x": captcha_code[0], "y": captcha_code[1]})
+
+
+ def getPackageInfo(self):
+ name = self.pyfile.package().name
+ folder = self.pyfile.package().folder
+
+ self.logDebug("Defaulting to pyfile name [%s] and folder [%s] for package" % (name, folder))
+
+ return name, folder
+
+
+ def getunrarpw(self):
+ sitein = self.html
+ indexi = sitein.find("|source|") + 8
+ indexe = sitein.find("|",indexi)
+
+ unrarpw = sitein[indexi:indexe]
+
+ if not (unrarpw == "Password" or "Dateipasswort") :
+ self.logDebug("File password set to: [%s]"% unrarpw)
+ self.pyfile.package().password = unrarpw
+
+
+ def handleErrors(self):
+ if self.isPasswordProtected():
+ self.fail(_("Incorrect password"))
+
+
+ def handleCaptchaErrors(self):
+ if self.captcha:
+ if "Your choice was wrong!" in self.html:
+ self.invalidCaptcha()
+ self.retry()
+ else:
+ self.correctCaptcha()
+
+
+ def handleLinkSource(self, type_):
+ if type_ is 'cnl':
+ return self.handleCNL2()
+
+ elif type_ is 'web':
+ return self.handleWebLinks()
+
+ elif type_ in ('rsdf', 'ccf', 'dlc'):
+ return self.handleContainer(type_)
+
+ else:
+ self.error(_("Unknown source type: %s") % type_)
+
+
+ def handleWebLinks(self):
+ self.logDebug("Search for Web links ")
+
+ package_links = []
+ pattern = r'<form action="http://linkcrypt.ws/out.html"[^>]*?>.*?<input[^>]*?value="([^"]*?)"[^>]*?name="file"'
+ ids = re.findall(pattern, self.html, re.I | re.S)
+
+ self.logDebug("Decrypting %d Web links" % len(ids))
+
+ for idx, weblink_id in enumerate(ids):
+ try:
+ self.logDebug("Decrypting Web link %d, %s" % (idx + 1, weblink_id))
+
+ res = self.load("http://linkcrypt.ws/out.html", post = {'file':weblink_id})
+
+ indexs = res.find("window.location =") + 19
+ indexe = res.find('"', indexs)
+
+ link2 = res[indexs:indexe]
+
+ self.logDebug(link2)
+
+ link2 = html_unescape(link2)
+ package_links.append(link2)
+
+ except Exception, detail:
+ self.logDebug("Error decrypting Web link %s, %s" % (weblink_id, detail))
+
+ return package_links
+
+
+ def get_container_html(self):
+ self.container_html = []
+
+ script = re.search(r'<div.*?id="ad_cont".*?<script.*?javascrip[^>]*?>(.*?)</script', self.html, re.I | re.S)
+
+ if script:
+ container_html_text = script.group(1)
+ container_html_text.strip()
+ self.container_html = container_html_text.splitlines()
+
+
+ def handle_javascript(self, line):
+ return self.js.eval(line.replace('{}))',"{}).replace('document.open();document.write','').replace(';document.close();',''))"))
+
+
+ def handleContainer(self, type_):
+ package_links = []
+ type_ = type_.lower()
+
+ self.logDebug('Search for %s Container links' % type_.upper())
+
+ if not type_.isalnum(): # check to prevent broken re-pattern (cnl2,rsdf,ccf,dlc,web are all alpha-numeric)
+ self.error(_("unknown container type: %s") % type_)
+
+ for line in self.container_html:
+ if(type_ in line):
+ jseval = self.handle_javascript(line)
+ clink = re.search(r'href=["\']([^"\']*?)["\']',jseval,re.I)
+
+ if not clink:
+ continue
+
+ self.logDebug("clink avaible")
+
+ package_name, folder_name = self.getPackageInfo()
+ self.logDebug("Added package with name %s.%s and container link %s" %( package_name, type_, clink.group(1)))
+ self.core.api.uploadContainer( "%s.%s" %(package_name, type_), self.load(clink.group(1)))
+ return "Found it"
+
+ return package_links
+
+
+ def handleCNL2(self):
+ self.logDebug("Search for CNL links")
+
+ package_links = []
+ cnl_line = None
+
+ for line in self.container_html:
+ if("cnl" in line):
+ cnl_line = line
+ break
+
+ if cnl_line:
+ self.logDebug("cnl_line gefunden")
+
+ try:
+ cnl_section = self.handle_javascript(cnl_line)
+ (vcrypted, vjk) = self._getCipherParams(cnl_section)
+ for (crypted, jk) in zip(vcrypted, vjk):
+ package_links.extend(self._getLinks(crypted, jk))
+ except:
+ self.logError(_("Unable to decrypt CNL links (JS Error) try to get over links"))
+ return self.handleWebLinks()
+
+ return package_links
+
+
+ def _getCipherParams(self, cnl_section):
+ # Get jk
+ jk_re = r'<INPUT.*?NAME="%s".*?VALUE="(.*?)"' % LinkCryptWs.JK_KEY
+ vjk = re.findall(jk_re, cnl_section)
+
+ # Get crypted
+ crypted_re = r'<INPUT.*?NAME="%s".*?VALUE="(.*?)"' % LinkCryptWs.CRYPTED_KEY
+ vcrypted = re.findall(crypted_re, cnl_section)
+
+ # Log and return
+ self.logDebug("Detected %d crypted blocks" % len(vcrypted))
+ return vcrypted, vjk
+
+
+ def _getLinks(self, crypted, jk):
+ # Get key
+ jreturn = self.js.eval("%s f()" % jk)
+ key = binascii.unhexlify(jreturn)
+
+ self.logDebug("JsEngine returns value [%s]" % jreturn)
+
+ # Decode crypted
+ crypted = base64.standard_b64decode(crypted)
+
+ # Decrypt
+ Key = key
+ IV = key
+ obj = AES.new(Key, AES.MODE_CBC, IV)
+ text = obj.decrypt(crypted)
+
+ # Extract links
+ text = text.replace("\x00", "").replace("\r", "")
+ links = text.split("\n")
+ links = filter(lambda x: x != "", links)
+
+ # Log and return
+ self.logDebug("Package has %d links" % len(links))
+
+ return links
diff --git a/pyload/plugins/crypter/LinkSaveIn.py b/pyload/plugins/crypter/LinkSaveIn.py
index d6ad6abb7..44a31a1b1 100644
--- a/pyload/plugins/crypter/LinkSaveIn.py
+++ b/pyload/plugins/crypter/LinkSaveIn.py
@@ -9,7 +9,7 @@ import re
from Crypto.Cipher import AES
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
+from pyload.plugins.internal.SimpleCrypter import SimpleCrypter
from pyload.utils import html_unescape
diff --git a/pyload/plugins/crypter/LinkdecrypterCom.py b/pyload/plugins/crypter/LinkdecrypterCom.py
index 9c0d364e6..57045c9d0 100644
--- a/pyload/plugins/crypter/LinkdecrypterCom.py
+++ b/pyload/plugins/crypter/LinkdecrypterCom.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class LinkdecrypterCom(Crypter):
diff --git a/pyload/plugins/crypter/LixIn.py b/pyload/plugins/crypter/LixIn.py
index 6d0494c57..2394a17b8 100644
--- a/pyload/plugins/crypter/LixIn.py
+++ b/pyload/plugins/crypter/LixIn.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class LixIn(Crypter):
diff --git a/pyload/plugins/crypter/MediafireComFolder.py b/pyload/plugins/crypter/MediafireComFolder.py
index 43f87b821..a1cd84fa0 100644
--- a/pyload/plugins/crypter/MediafireComFolder.py
+++ b/pyload/plugins/crypter/MediafireComFolder.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.plugins.hoster.MediafireCom import checkHTMLHeader
from pyload.utils import json_loads
diff --git a/pyload/plugins/crypter/MegaRapidCzFolder.py b/pyload/plugins/crypter/MegaRapidCzFolder.py
new file mode 100644
index 000000000..4a2344051
--- /dev/null
+++ b/pyload/plugins/crypter/MegaRapidCzFolder.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.SimpleCrypter import SimpleCrypter
+
+
+class MegaRapidCzFolder(SimpleCrypter):
+ __name__ = "MegaRapidCzFolder"
+ __type__ = "crypter"
+ __version__ = "0.02"
+
+ __pattern__ = r'http://(?:www\.)?(share|mega)rapid\.cz/slozka/\d+/\w+'
+ __config__ = [("use_subfolder", "bool", "Save package to subfolder", True),
+ ("subfolder_per_package", "bool", "Create a subfolder for each package", True)]
+
+ __description__ = """Share-Rapid.com folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+
+
+ LINK_PATTERN = r'<td class="soubor"[^>]*><a href="([^"]+)">'
diff --git a/pyload/plugins/crypter/MegauploadComFolder.py b/pyload/plugins/crypter/MegauploadComFolder.py
new file mode 100644
index 000000000..7e79863d2
--- /dev/null
+++ b/pyload/plugins/crypter/MegauploadComFolder.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadCrypter import DeadCrypter
+
+
+class MegauploadComFolder(DeadCrypter):
+ __name__ = "MegauploadComFolder"
+ __type__ = "crypter"
+ __version__ = "0.02"
+
+ __pattern__ = r'http://(?:www\.)?megaupload\.com/(\?f|xml/folderfiles\.php\?.*&?folderid)=\w+'
+
+ __description__ = """Megaupload.com folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
diff --git a/pyload/plugins/crypter/MultiloadCz.py b/pyload/plugins/crypter/MultiloadCz.py
index e233dce99..02b60876e 100644
--- a/pyload/plugins/crypter/MultiloadCz.py
+++ b/pyload/plugins/crypter/MultiloadCz.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class MultiloadCz(Crypter):
diff --git a/pyload/plugins/crypter/NCryptIn.py b/pyload/plugins/crypter/NCryptIn.py
index 28eb40a63..edb664d32 100644
--- a/pyload/plugins/crypter/NCryptIn.py
+++ b/pyload/plugins/crypter/NCryptIn.py
@@ -6,7 +6,7 @@ import re
from Crypto.Cipher import AES
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.plugins.internal.CaptchaService import ReCaptcha
diff --git a/pyload/plugins/crypter/OneKhDe.py b/pyload/plugins/crypter/OneKhDe.py
index d980f9bad..ff15b0baa 100644
--- a/pyload/plugins/crypter/OneKhDe.py
+++ b/pyload/plugins/crypter/OneKhDe.py
@@ -3,7 +3,7 @@
import re
from pyload.utils import html_unescape
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class OneKhDe(Crypter):
diff --git a/pyload/plugins/crypter/QuickshareCzFolder.py b/pyload/plugins/crypter/QuickshareCzFolder.py
index 7a4a7fb03..b3f3f2335 100644
--- a/pyload/plugins/crypter/QuickshareCzFolder.py
+++ b/pyload/plugins/crypter/QuickshareCzFolder.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class QuickshareCzFolder(Crypter):
diff --git a/pyload/plugins/crypter/RapidfileshareNetFolder.py b/pyload/plugins/crypter/RapidfileshareNetFolder.py
new file mode 100644
index 000000000..daf4c1311
--- /dev/null
+++ b/pyload/plugins/crypter/RapidfileshareNetFolder.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSCrypter import XFSCrypter
+
+
+class RapidfileshareNetFolder(XFSCrypter):
+ __name__ = "RapidfileshareNetFolder"
+ __type__ = "crypter"
+ __version__ = "0.03"
+
+ __pattern__ = r'http://(?:www\.)?rapidfileshare\.net/users/\w+/\d+/\w+'
+ __config__ = [("use_subfolder", "bool", "Save package to subfolder", True),
+ ("subfolder_per_package", "bool", "Create a subfolder for each package", True)]
+
+ __description__ = """Rapidfileshare.net folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("guidobelix", "guidobelix@hotmail.it")]
+
+
+ HOSTER_DOMAIN = "rapidfileshare.net"
diff --git a/pyload/plugins/crypter/RelinkUs.py b/pyload/plugins/crypter/RelinkUs.py
index 8a31d2acd..c27d790b8 100644
--- a/pyload/plugins/crypter/RelinkUs.py
+++ b/pyload/plugins/crypter/RelinkUs.py
@@ -6,7 +6,7 @@ import re
import os
from Crypto.Cipher import AES
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class RelinkUs(Crypter):
diff --git a/pyload/plugins/crypter/SafelinkingNet.py b/pyload/plugins/crypter/SafelinkingNet.py
index 1d8ad7cf6..38eb36ea5 100644
--- a/pyload/plugins/crypter/SafelinkingNet.py
+++ b/pyload/plugins/crypter/SafelinkingNet.py
@@ -7,7 +7,7 @@ from pycurl import FOLLOWLOCATION
from BeautifulSoup import BeautifulSoup
from pyload.utils import json_loads
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.plugins.internal.CaptchaService import SolveMedia
diff --git a/pyload/plugins/crypter/SexuriaCom.py b/pyload/plugins/crypter/SexuriaCom.py
new file mode 100644
index 000000000..dd9b01bcd
--- /dev/null
+++ b/pyload/plugins/crypter/SexuriaCom.py
@@ -0,0 +1,94 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from pyload.plugins.internal.Crypter import Crypter
+
+
+class SexuriaCom(Crypter):
+ __name__ = "SexuriaCom"
+ __type__ = "crypter"
+ __version__ = "0.01"
+
+ __pattern__ = r'http://(?:www\.)?sexuria\.com/(v1/)?(Pornos_Kostenlos_.+?_(\d+)\.html|dl_links_\d+_\d+\.html|id=\d+\&part=\d+\&link=\d+)'
+ __config__ = [("use_subfolder", "bool", "Save package to subfolder", True),
+ ("subfolder_per_package", "bool", "Create a subfolder for each package", True)]
+
+ __description__ = """Sexuria.com decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("NETHead", "NETHead.AT.gmx.DOT.net")]
+
+
+ PATTERN_SUPPORTED_MAIN = re.compile(r'http://(www\.)?sexuria\.com/(v1/)?Pornos_Kostenlos_.+?_(\d+)\.html', flags=re.I)
+ PATTERN_SUPPORTED_CRYPT = re.compile(r'http://(www\.)?sexuria\.com/(v1/)?dl_links_\d+_(?P<ID>\d+)\.html', flags=re.I)
+ PATTERN_SUPPORTED_REDIRECT = re.compile(r'http://(www\.)?sexuria\.com/out\.php\?id=(?P<ID>\d+)\&part=\d+\&link=\d+', flags=re.I)
+ PATTERN_TITLE = re.compile(r'<title> - (?P<TITLE>.*) Sexuria - Kostenlose Pornos - Rapidshare XXX Porn</title>', flags=re.I)
+ PATTERN_PASSWORD = re.compile(r'<strong>Passwort: </strong></div></td>.*?bgcolor="#EFEFEF">(?P<PWD>.*?)</td>', flags=re.I | re.S)
+ PATTERN_DL_LINK_PAGE = re.compile(r'"(dl_links_\d+_\d+\.html)"', flags=re.I)
+ PATTERN_REDIRECT_LINKS = re.compile(r'value="(http://sexuria\.com/out\.php\?id=\d+\&part=\d+\&link=\d+)" readonly', flags=re.I)
+
+
+ def decrypt(self, pyfile):
+ # Init
+ self.pyfile = pyfile
+ self.package = pyfile.package()
+
+ # Get package links
+ package_name, self.links, folder_name, package_pwd = self.decryptLinks(self.pyfile.url)
+ self.packages = [(package_name, self.links, folder_name)]
+
+
+ def decryptLinks(self, url):
+ linklist = []
+ name = self.package.name
+ folder = self.package.folder
+ password = None
+
+ if re.match(self.PATTERN_SUPPORTED_MAIN, url):
+ # Processing main page
+ html = self.load(url)
+ links = re.findall(self.PATTERN_DL_LINK_PAGE, html)
+ for link in links:
+ linklist.append("http://sexuria.com/v1/" + link)
+
+ elif re.match(self.PATTERN_SUPPORTED_REDIRECT, url):
+ # Processing direct redirect link (out.php), redirecting to main page
+ id = re.search(self.PATTERN_SUPPORTED_REDIRECT, url).group('ID')
+ if id:
+ linklist.append("http://sexuria.com/v1/Pornos_Kostenlos_liebe_%s.html" % id)
+
+ elif re.match(self.PATTERN_SUPPORTED_CRYPT, url):
+ # Extract info from main file
+ id = re.search(self.PATTERN_SUPPORTED_CRYPT, url).group('ID')
+ html = self.load("http://sexuria.com/v1/Pornos_Kostenlos_info_%s.html" % id, decode=True)
+
+ title = re.search(self.PATTERN_TITLE, html).group('TITLE').strip()
+ if title:
+ name = folder = title
+ self.logDebug("Package info found, name [%s] and folder [%s]" % (name, folder))
+
+ pwd = re.search(self.PATTERN_PASSWORD, html).group('PWD')
+ if pwd:
+ password = pwd.strip()
+ self.logDebug("Password info [%s] found" % password)
+
+ # Process link (dl_link)
+ html = self.load(url)
+ links = re.findall(self.PATTERN_REDIRECT_LINKS, html)
+ if len(links) == 0:
+ self.LogError("Broken for link %s" % link)
+ else:
+ for link in links:
+ link = link.replace("http://sexuria.com/", "http://www.sexuria.com/")
+ finallink = self.load(link, just_header=True)['location']
+ if not finallink or "sexuria.com/" in finallink:
+ self.LogError("Broken for link %s" % link)
+ else:
+ linklist.append(finallink)
+
+ # Debug log
+ self.logDebug("%d supported links" % len(linklist))
+ for i, link in enumerate(linklist):
+ self.logDebug("Supported link %d, %s" % (i + 1, link))
+
+ return name, linklist, folder, password
diff --git a/pyload/plugins/crypter/ShareLinksBiz.py b/pyload/plugins/crypter/ShareLinksBiz.py
index 0c646eda8..7aa5dd17b 100644
--- a/pyload/plugins/crypter/ShareLinksBiz.py
+++ b/pyload/plugins/crypter/ShareLinksBiz.py
@@ -5,7 +5,7 @@ import binascii
import re
from Crypto.Cipher import AES
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class ShareLinksBiz(Crypter):
diff --git a/pyload/plugins/crypter/SharingmatrixComFolder.py b/pyload/plugins/crypter/SharingmatrixComFolder.py
new file mode 100644
index 000000000..a8ab3226a
--- /dev/null
+++ b/pyload/plugins/crypter/SharingmatrixComFolder.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadCrypter import DeadCrypter
+
+
+class SharingmatrixComFolder(DeadCrypter):
+ __name__ = "SharingmatrixComFolder"
+ __type__ = "crypter"
+ __version__ = "0.01"
+
+ __pattern__ = r'http://(?:www\.)?sharingmatrix\.com/folder/\w+'
+
+ __description__ = """Sharingmatrix.com folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
diff --git a/pyload/plugins/crypter/TusfilesNetFolder.py b/pyload/plugins/crypter/TusfilesNetFolder.py
index e8da59736..8ca1ada00 100644
--- a/pyload/plugins/crypter/TusfilesNetFolder.py
+++ b/pyload/plugins/crypter/TusfilesNetFolder.py
@@ -4,7 +4,7 @@ import math
import re
from urlparse import urljoin
-from module.plugins.internal.XFSCrypter import XFSCrypter
+from pyload.plugins.internal.XFSCrypter import XFSCrypter
class TusfilesNetFolder(XFSCrypter):
diff --git a/pyload/plugins/crypter/UlozToFolder.py b/pyload/plugins/crypter/UlozToFolder.py
index da1cb61b9..fe64d41bb 100644
--- a/pyload/plugins/crypter/UlozToFolder.py
+++ b/pyload/plugins/crypter/UlozToFolder.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
import re
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class UlozToFolder(Crypter):
diff --git a/pyload/plugins/crypter/UploadedToFolder.py b/pyload/plugins/crypter/UploadedToFolder.py
index 359ba92d0..da1354f02 100644
--- a/pyload/plugins/crypter/UploadedToFolder.py
+++ b/pyload/plugins/crypter/UploadedToFolder.py
@@ -4,7 +4,7 @@ import re
from urlparse import urljoin
-from module.plugins.internal.SimpleCrypter import SimpleCrypter
+from pyload.plugins.internal.SimpleCrypter import SimpleCrypter
class UploadedToFolder(SimpleCrypter):
diff --git a/pyload/plugins/crypter/WuploadComFolder.py b/pyload/plugins/crypter/WuploadComFolder.py
new file mode 100644
index 000000000..2626a0d13
--- /dev/null
+++ b/pyload/plugins/crypter/WuploadComFolder.py
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadCrypter import DeadCrypter
+
+
+class WuploadComFolder(DeadCrypter):
+ __name__ = "WuploadComFolder"
+ __type__ = "crypter"
+ __version__ = "0.01"
+
+ __pattern__ = r'http://(?:www\.)?wupload\.com/folder/\w+'
+
+ __description__ = """Wupload.com folder decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
diff --git a/pyload/plugins/internal/XFSPHoster.py b/pyload/plugins/crypter/XFileSharingProFolder.py
index c3f8b6f41..89fac31ac 100644
--- a/pyload/plugins/internal/XFSPHoster.py
+++ b/pyload/plugins/crypter/XFileSharingProFolder.py
@@ -2,17 +2,19 @@
import re
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSCrypter import XFSCrypter
-class XFileSharingPro(XFSHoster):
- __name__ = "XFileSharingPro"
- __type__ = "hoster"
- __version__ = "0.42"
+class XFileSharingProFolder(XFSCrypter):
+ __name__ = "XFileSharingProFolder"
+ __type__ = "crypter"
+ __version__ = "0.03"
__pattern__ = r'^unmatchable$'
+ __config__ = [("use_subfolder", "bool", "Save package to subfolder", True),
+ ("subfolder_per_package", "bool", "Create a subfolder for each package", True)]
- __description__ = """XFileSharingPro dummy hoster plugin for hook"""
+ __description__ = """XFileSharingPro dummy folder decrypter plugin for hook"""
__license__ = "GPLv3"
__authors__ = [("Walter Purcaro", "vuolter@gmail.com")]
@@ -24,9 +26,9 @@ class XFileSharingPro(XFSHoster):
def init(self):
- super(XFileSharingPro, self).init()
+ super(XFileSharingProFolder, self).init()
- self.__pattern__ = self.core.pluginManager.hosterPlugins[self.__name__]['pattern']
+ self.__pattern__ = self.core.pluginManager.crypterPlugins[self.__name__]['pattern']
self.HOSTER_DOMAIN = re.match(self.__pattern__, self.pyfile.url).group(1).lower()
self.HOSTER_NAME = "".join([str.capitalize() for str in self.HOSTER_DOMAIN.split('.')])
@@ -43,12 +45,3 @@ class XFileSharingPro(XFSHoster):
self.user, data = self.account.selectAccount()
self.req = self.account.getAccountRequest(self.user)
self.premium = self.account.isPremium(self.user)
-
-
- def setup(self):
- self.chunkLimit = 1
- self.resumeDownload = self.premium
- self.multiDL = True
-
-
-getInfo = create_getInfo(XFileSharingPro)
diff --git a/pyload/plugins/crypter/XupPl.py b/pyload/plugins/crypter/XupPl.py
index 87c93a305..7be72cf9e 100644
--- a/pyload/plugins/crypter/XupPl.py
+++ b/pyload/plugins/crypter/XupPl.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
class XupPl(Crypter):
diff --git a/pyload/plugins/crypter/YoutubeBatch.py b/pyload/plugins/crypter/YoutubeBatch.py
index 7cb0e2f0a..d25f991e8 100644
--- a/pyload/plugins/crypter/YoutubeBatch.py
+++ b/pyload/plugins/crypter/YoutubeBatch.py
@@ -5,7 +5,7 @@ import re
from urlparse import urljoin
from pyload.utils import json_loads
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.utils import safe_join
diff --git a/pyload/plugins/hook/BypassCaptcha.py b/pyload/plugins/hook/BypassCaptcha.py
index 8b34777f0..1a640ef87 100644
--- a/pyload/plugins/hook/BypassCaptcha.py
+++ b/pyload/plugins/hook/BypassCaptcha.py
@@ -5,7 +5,7 @@ from thread import start_new_thread
from pyload.network.HTTPRequest import BadHeader
from pyload.network.RequestFactory import getURL, getRequest
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
class BypassCaptchaException(Exception):
diff --git a/pyload/plugins/hook/Captcha9kw.py b/pyload/plugins/hook/Captcha9kw.py
index f131aa21e..ab5b802b0 100644
--- a/pyload/plugins/hook/Captcha9kw.py
+++ b/pyload/plugins/hook/Captcha9kw.py
@@ -11,7 +11,7 @@ from time import sleep
from pyload.network.HTTPRequest import BadHeader
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
class Captcha9kw(Hook):
diff --git a/pyload/plugins/hook/CaptchaBrotherhood.py b/pyload/plugins/hook/CaptchaBrotherhood.py
index 03821b8b6..1b7e18c51 100644
--- a/pyload/plugins/hook/CaptchaBrotherhood.py
+++ b/pyload/plugins/hook/CaptchaBrotherhood.py
@@ -15,7 +15,7 @@ from time import sleep
from urllib import urlencode
from pyload.network.RequestFactory import getURL, getRequest
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
class CaptchaBrotherhoodException(Exception):
diff --git a/pyload/plugins/hook/DeathByCaptcha.py b/pyload/plugins/hook/DeathByCaptcha.py
index f3e4bb808..d032c964f 100644
--- a/pyload/plugins/hook/DeathByCaptcha.py
+++ b/pyload/plugins/hook/DeathByCaptcha.py
@@ -12,7 +12,7 @@ from time import sleep
from pyload.utils import json_loads
from pyload.network.HTTPRequest import BadHeader
from pyload.network.RequestFactory import getRequest
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
class DeathByCaptchaException(Exception):
diff --git a/pyload/plugins/hook/ExpertDecoders.py b/pyload/plugins/hook/ExpertDecoders.py
index 933355fbe..ed889319a 100644
--- a/pyload/plugins/hook/ExpertDecoders.py
+++ b/pyload/plugins/hook/ExpertDecoders.py
@@ -9,7 +9,7 @@ from uuid import uuid4
from pyload.network.HTTPRequest import BadHeader
from pyload.network.RequestFactory import getURL, getRequest
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
class ExpertDecoders(Hook):
diff --git a/pyload/plugins/hook/ImageTyperz.py b/pyload/plugins/hook/ImageTyperz.py
index b79fd42ba..ce6527fad 100644
--- a/pyload/plugins/hook/ImageTyperz.py
+++ b/pyload/plugins/hook/ImageTyperz.py
@@ -9,7 +9,7 @@ from pycurl import FORM_FILE, LOW_SPEED_TIME
from thread import start_new_thread
from pyload.network.RequestFactory import getURL, getRequest
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
class ImageTyperzException(Exception):
diff --git a/pyload/plugins/hook/LinkdecrypterCom.py b/pyload/plugins/hook/LinkdecrypterCom.py
index 8455ed904..95145d462 100644
--- a/pyload/plugins/hook/LinkdecrypterCom.py
+++ b/pyload/plugins/hook/LinkdecrypterCom.py
@@ -3,7 +3,7 @@
import re
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
from pyload.utils import remove_chars
diff --git a/pyload/plugins/hook/XFileSharingPro.py b/pyload/plugins/hook/XFileSharingPro.py
index 3f70f88f3..53033d8a4 100644
--- a/pyload/plugins/hook/XFileSharingPro.py
+++ b/pyload/plugins/hook/XFileSharingPro.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hook import Hook
+from pyload.plugins.internal.Addon import Hook
class XFileSharingPro(Hook):
diff --git a/pyload/plugins/hoster/AlldebridCom.py b/pyload/plugins/hoster/AlldebridCom.py
index 7a7831204..7e5adf8ba 100644
--- a/pyload/plugins/hoster/AlldebridCom.py
+++ b/pyload/plugins/hoster/AlldebridCom.py
@@ -6,7 +6,7 @@ from random import randrange
from urllib import unquote
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import parseFileSize
diff --git a/pyload/plugins/hoster/BasePlugin.py b/pyload/plugins/hoster/BasePlugin.py
index 761ee720c..dd8540578 100644
--- a/pyload/plugins/hoster/BasePlugin.py
+++ b/pyload/plugins/hoster/BasePlugin.py
@@ -6,7 +6,7 @@ from urllib import unquote
from urlparse import urlparse
from pyload.network.HTTPRequest import BadHeader
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import html_unescape, remove_chars
diff --git a/pyload/plugins/hoster/BillionuploadsCom.py b/pyload/plugins/hoster/BillionuploadsCom.py
index b20ace0f1..d5d8c6c0f 100644
--- a/pyload/plugins/hoster/BillionuploadsCom.py
+++ b/pyload/plugins/hoster/BillionuploadsCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class BillionuploadsCom(XFSHoster):
diff --git a/pyload/plugins/hoster/CramitIn.py b/pyload/plugins/hoster/CramitIn.py
index 4f1ad1ff1..2d2c0cbbc 100644
--- a/pyload/plugins/hoster/CramitIn.py
+++ b/pyload/plugins/hoster/CramitIn.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class CramitIn(XFSHoster):
diff --git a/pyload/plugins/hoster/DailymotionCom.py b/pyload/plugins/hoster/DailymotionCom.py
index 4fb0b2222..4b3af6e8f 100644
--- a/pyload/plugins/hoster/DailymotionCom.py
+++ b/pyload/plugins/hoster/DailymotionCom.py
@@ -5,7 +5,7 @@ import re
from pyload.datatypes.PyFile import statusMap
from pyload.utils import json_loads
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
def getInfo(urls):
diff --git a/pyload/plugins/hoster/DebridItaliaCom.py b/pyload/plugins/hoster/DebridItaliaCom.py
index 1b6b1b030..81cf0b830 100644
--- a/pyload/plugins/hoster/DebridItaliaCom.py
+++ b/pyload/plugins/hoster/DebridItaliaCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class DebridItaliaCom(Hoster):
diff --git a/pyload/plugins/hoster/EasybytezCom.py b/pyload/plugins/hoster/EasybytezCom.py
index 3103d403f..b233e52ee 100644
--- a/pyload/plugins/hoster/EasybytezCom.py
+++ b/pyload/plugins/hoster/EasybytezCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class EasybytezCom(XFSHoster):
diff --git a/pyload/plugins/hoster/EnteruploadCom.py b/pyload/plugins/hoster/EnteruploadCom.py
new file mode 100644
index 000000000..c535d6f48
--- /dev/null
+++ b/pyload/plugins/hoster/EnteruploadCom.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class EnteruploadCom(DeadHoster):
+ __name__ = "EnteruploadCom"
+ __type__ = "hoster"
+ __version__ = "0.02"
+
+ __pattern__ = r'http://(?:www\.)?enterupload\.com/\w+'
+
+ __description__ = """EnterUpload.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+
+
+getInfo = create_getInfo(EnteruploadCom)
diff --git a/pyload/plugins/hoster/FastixRu.py b/pyload/plugins/hoster/FastixRu.py
index 2e01dc216..0e353f362 100644
--- a/pyload/plugins/hoster/FastixRu.py
+++ b/pyload/plugins/hoster/FastixRu.py
@@ -6,7 +6,7 @@ from random import randrange
from urllib import unquote
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class FastixRu(Hoster):
diff --git a/pyload/plugins/hoster/FileParadoxIn.py b/pyload/plugins/hoster/FileParadoxIn.py
index 7ed0e9b7a..174aa7211 100644
--- a/pyload/plugins/hoster/FileParadoxIn.py
+++ b/pyload/plugins/hoster/FileParadoxIn.py
@@ -2,7 +2,7 @@
import re
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class FileParadoxIn(XFSHoster):
diff --git a/pyload/plugins/hoster/FileSharkPl.py b/pyload/plugins/hoster/FileSharkPl.py
new file mode 100644
index 000000000..99cb4b51b
--- /dev/null
+++ b/pyload/plugins/hoster/FileSharkPl.py
@@ -0,0 +1,137 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from urlparse import urljoin
+
+from pyload.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
+
+
+class FileSharkPl(SimpleHoster):
+ __name__ = "FileSharkPl"
+ __type__ = "hoster"
+ __version__ = "0.01"
+
+ __pattern__ = r'http://(?:www\.)?fileshark\.pl/pobierz/\d{6}/\w{5}'
+
+ __description__ = """FileShark.pl hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("prOq", None),
+ ("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ NAME_PATTERN = r'<h2 class="name-file">(?P<N>.+)</h2>'
+ SIZE_PATTERN = r'<p class="size-file">(.*?)<strong>(?P<S>\d+\.?\d*)\s(?P<U>\w+)</strong></p>'
+
+ OFFLINE_PATTERN = '(P|p)lik zosta. (usuni.ty|przeniesiony)'
+
+ DOWNLOAD_ALERT = r'<p class="lead text-center alert alert-warning">(.*?)</p>'
+ IP_BLOCKED_PATTERN = 'Strona jest dost.pna wy..cznie dla u.ytkownik.w znajduj.cych si. na terenie Polski'
+ DOWNLOAD_SLOTS_ERROR_PATTERN = r'Osi.gni.to maksymaln. liczb. .ci.ganych jednocze.nie plik.w\.'
+
+ DOWNLOAD_URL_FREE = r'<a href="(.*?)" class="btn-upload-free">'
+ DOWNLOAD_URL_PREMIUM = r'<a href="(.*?)" class="btn-upload-premium">'
+
+ SECONDS_PATTERN = r'var timeToDownload = (\d+);'
+
+ CAPTCHA_IMG_PATTERN = '<img src="data:image/jpeg;base64,(.*?)" title="captcha"'
+ CAPTCHA_TOKEN_PATTERN = r'name="form\[_token\]" value="(.*?)" />'
+
+
+ def setup(self):
+ self.resumeDownload = True
+ if self.premium:
+ self.multiDL = True
+ self.limitDL = 20
+ else:
+ self.multiDL = False
+
+
+ def prepare(self):
+ super(FileSharkPl, self).prepare()
+
+ m = re.search(self.DOWNLOAD_ALERT, self.html):
+ if m:
+ return
+
+ alert = m.group(1)
+
+ if re.match(self.IP_BLOCKED_PATTERN, alert):
+ self.fail(_("Only connections from Polish IP are allowed"))
+ elif re.match(self.DOWNLOAD_SLOTS_ERROR_PATTERN, alert):
+ self.logInfo(_("No free download slots available"))
+ self.retry(10, 30 * 60, _("Still no free download slots available"))
+ else:
+ self.logInfo(alert)
+ self.retry(10, 10 * 60, _("Try again later"))
+
+
+ #@NOTE: handlePremium method was never been tested
+ def handlePremium(self):
+ self.logDebug("Premium accounts support in experimental modus!")
+ m = re.search(self.DOWNLOAD_URL_PREMIUM, self.html)
+ file_url = urljoin("http://fileshark.pl", m.group(1))
+
+ self.download(file_url, disposition=True)
+ self.checkDownload()
+
+
+ def handleFree(self):
+ m = re.search(self.DOWNLOAD_URL_FREE, self.html)
+ if m is None:
+ self.error(_("Download url not found"))
+
+ file_url = urljoin("http://fileshark.pl", m.group(1))
+
+ m = re.search(self.SECONDS_PATTERN, self.html)
+ if m:
+ seconds = int(m.group(1))
+ self.logDebug("Wait %s seconds" % seconds)
+ self.wait(seconds + 2)
+
+ action, inputs = self.parseHtmlForm('action=""')
+ m = re.search(self.CAPTCHA_TOKEN_PATTERN, self.html)
+ if m is None:
+ self.retry(reason=_("Captcha form not found"))
+
+ inputs['form[_token]'] = m.group(1)
+
+ m = re.search(self.CAPTCHA_IMG_PATTERN, self.html)
+ if m is None:
+ self.retry(reason=_("Captcha image not found"))
+
+ tmp_load = self.load
+ self.load = self.decode64 #: injects decode64 inside decryptCaptcha
+
+ inputs['form[captcha]'] = self.decryptCaptcha(m.group(1), imgtype='jpeg')
+ inputs['form[start]'] = ""
+
+ self.load = tmp_load
+
+ self.download(file_url, post=inputs, cookies=True, disposition=True)
+ self.checkDownload()
+
+
+ def checkDownload(self):
+ check = super(FileSharkPl, self).checkDownload({
+ 'wrong_captcha': re.compile(r'<label for="form_captcha" generated="true" class="error">(.*?)</label>'),
+ 'wait_pattern': re.compile(self.SECONDS_PATTERN),
+ 'DL-found': re.compile('<a href="(.*)">')
+ })
+
+ if check == "DL-found":
+ self.correctCaptcha()
+
+ elif check == "wrong_captcha":
+ self.invalidCaptcha()
+ self.retry(10, 1, _("Wrong captcha solution"))
+
+ elif check == "wait_pattern":
+ self.retry()
+
+
+ def decode64(self, data, *args, **kwargs):
+ return data.decode("base64")
+
+
+getInfo = create_getInfo(FileSharkPl)
diff --git a/pyload/plugins/hoster/FileomCom.py b/pyload/plugins/hoster/FileomCom.py
index 2b6fd34db..128039c2e 100644
--- a/pyload/plugins/hoster/FileomCom.py
+++ b/pyload/plugins/hoster/FileomCom.py
@@ -3,7 +3,7 @@
# Test links:
# http://fileom.com/gycaytyzdw3g/random.bin.html
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class FileomCom(XFSHoster):
diff --git a/pyload/plugins/hoster/FilerioCom.py b/pyload/plugins/hoster/FilerioCom.py
index 52906fc67..f4582b876 100644
--- a/pyload/plugins/hoster/FilerioCom.py
+++ b/pyload/plugins/hoster/FilerioCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class FilerioCom(XFSHoster):
diff --git a/pyload/plugins/hoster/FilesMailRu.py b/pyload/plugins/hoster/FilesMailRu.py
index c92cd0b0c..1c7c8059e 100644
--- a/pyload/plugins/hoster/FilesMailRu.py
+++ b/pyload/plugins/hoster/FilesMailRu.py
@@ -3,7 +3,7 @@
import re
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.Plugin import chunks
diff --git a/pyload/plugins/hoster/FileserveCom.py b/pyload/plugins/hoster/FileserveCom.py
index 88da94c46..f486d9f56 100644
--- a/pyload/plugins/hoster/FileserveCom.py
+++ b/pyload/plugins/hoster/FileserveCom.py
@@ -4,7 +4,7 @@ import re
from pyload.utils import json_loads
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.Plugin import chunks
from pyload.plugins.hoster.UnrestrictLi import secondsToMidnight
from pyload.plugins.internal.CaptchaService import ReCaptcha
diff --git a/pyload/plugins/hoster/FileshareInUa.py b/pyload/plugins/hoster/FileshareInUa.py
index 08e10dccb..8bb1a72c5 100644
--- a/pyload/plugins/hoster/FileshareInUa.py
+++ b/pyload/plugins/hoster/FileshareInUa.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
class FileshareInUa(DeadHoster):
diff --git a/pyload/plugins/hoster/FilesonicCom.py b/pyload/plugins/hoster/FilesonicCom.py
new file mode 100644
index 000000000..323983169
--- /dev/null
+++ b/pyload/plugins/hoster/FilesonicCom.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class FilesonicCom(DeadHoster):
+ __name__ = "FilesonicCom"
+ __type__ = "hoster"
+ __version__ = "0.35"
+
+ __pattern__ = r'http://(?:www\.)?filesonic\.com/file/\w+'
+
+ __description__ = """Filesonic.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("jeix", "jeix@hasnomail.de"),
+ ("paulking", None)]
+
+
+getInfo = create_getInfo(FilesonicCom)
diff --git a/pyload/plugins/hoster/FiredriveCom.py b/pyload/plugins/hoster/FiredriveCom.py
index 0e3a4e847..3c7ec25f2 100644
--- a/pyload/plugins/hoster/FiredriveCom.py
+++ b/pyload/plugins/hoster/FiredriveCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
class FiredriveCom(DeadHoster):
diff --git a/pyload/plugins/hoster/FreakshareCom.py b/pyload/plugins/hoster/FreakshareCom.py
index 1759df04a..bd31a5752 100644
--- a/pyload/plugins/hoster/FreakshareCom.py
+++ b/pyload/plugins/hoster/FreakshareCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.hoster.UnrestrictLi import secondsToMidnight
from pyload.plugins.internal.CaptchaService import ReCaptcha
diff --git a/pyload/plugins/hoster/FreeWayMe.py b/pyload/plugins/hoster/FreeWayMe.py
index 219333055..128f54958 100644
--- a/pyload/plugins/hoster/FreeWayMe.py
+++ b/pyload/plugins/hoster/FreeWayMe.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class FreeWayMe(Hoster):
diff --git a/pyload/plugins/hoster/Ftp.py b/pyload/plugins/hoster/Ftp.py
index a846d2b5f..2baec064b 100644
--- a/pyload/plugins/hoster/Ftp.py
+++ b/pyload/plugins/hoster/Ftp.py
@@ -6,7 +6,7 @@ import re
from urllib import quote, unquote
from urlparse import urlparse
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class Ftp(Hoster):
diff --git a/pyload/plugins/hoster/GamefrontCom.py b/pyload/plugins/hoster/GamefrontCom.py
index f502d9af4..195c6037e 100644
--- a/pyload/plugins/hoster/GamefrontCom.py
+++ b/pyload/plugins/hoster/GamefrontCom.py
@@ -3,7 +3,7 @@
import re
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import parseFileSize
diff --git a/pyload/plugins/hoster/HugefilesNet.py b/pyload/plugins/hoster/HugefilesNet.py
index cbbce119f..e955d53cc 100644
--- a/pyload/plugins/hoster/HugefilesNet.py
+++ b/pyload/plugins/hoster/HugefilesNet.py
@@ -3,7 +3,7 @@
# Test links:
# http://hugefiles.net/prthf9ya4w6s
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class HugefilesNet(XFSHoster):
diff --git a/pyload/plugins/hoster/HundredEightyUploadCom.py b/pyload/plugins/hoster/HundredEightyUploadCom.py
index 48e0c3d8c..717344efa 100644
--- a/pyload/plugins/hoster/HundredEightyUploadCom.py
+++ b/pyload/plugins/hoster/HundredEightyUploadCom.py
@@ -3,7 +3,7 @@
# Test links:
# http://180upload.com/js9qdm6kjnrs
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class HundredEightyUploadCom(XFSHoster):
diff --git a/pyload/plugins/hoster/JunocloudMe.py b/pyload/plugins/hoster/JunocloudMe.py
new file mode 100644
index 000000000..dc5620e0e
--- /dev/null
+++ b/pyload/plugins/hoster/JunocloudMe.py
@@ -0,0 +1,29 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+
+
+class JunocloudMe(XFSHoster):
+ __name__ = "JunocloudMe"
+ __type__ = "hoster"
+ __version__ = "0.03"
+
+ __pattern__ = r'http://(?:\w+\.)?junocloud\.me/\w{12}'
+
+ __description__ = """Junocloud.me hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("guidobelix", "guidobelix@hotmail.it")]
+
+
+ HOSTER_DOMAIN = "junocloud.me"
+
+ URL_REPLACEMENTS = [(r'/(?:embed-)?(\w{12}).*', r'/\1'), (r'//www\.', "//dl3.")]
+
+ NAME_PATTERN = r'<p class="request_file">http://junocloud.me/w{12}/(?P<N>.+?)</p>'
+ SIZE_PATTERN = r'<p class="request_filesize">Size: (?P<S>[\d.,]+) (?P<U>[\w^_]+)</p>'
+
+ OFFLINE_PATTERN = r'>No such file with this filename<'
+ TEMP_OFFLINE_PATTERN = r'The page may have been renamed, removed or be temporarily unavailable.<'
+
+
+getInfo = create_getInfo(JunocloudMe)
diff --git a/pyload/plugins/hoster/Keep2shareCc.py b/pyload/plugins/hoster/Keep2shareCc.py
new file mode 100644
index 000000000..6fc521107
--- /dev/null
+++ b/pyload/plugins/hoster/Keep2shareCc.py
@@ -0,0 +1,118 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from urlparse import urlparse, urljoin
+
+from pyload.plugins.internal.CaptchaService import ReCaptcha
+from pyload.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
+
+
+class Keep2shareCc(SimpleHoster):
+ __name__ = "Keep2shareCc"
+ __type__ = "hoster"
+ __version__ = "0.15"
+
+ __pattern__ = r'https?://(?:www\.)?(keep2share|k2s|keep2s)\.cc/file/(?P<ID>\w+)'
+
+ __description__ = """Keep2share.cc hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("stickell", "l.stickell@yahoo.it"),
+ ("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ NAME_PATTERN = r'File: <span>(?P<N>.+)</span>'
+ SIZE_PATTERN = r'Size: (?P<S>[^<]+)</div>'
+ OFFLINE_PATTERN = r'File not found or deleted|Sorry, this file is blocked or deleted|Error 404'
+
+ LINK_PATTERN = r'To download this file with slow speed, use <a href="([^"]+)">this link</a>'
+ CAPTCHA_PATTERN = r'src="(/file/captcha\.html.+?)"'
+ WAIT_PATTERN = r'Please wait ([\d:]+) to download this file'
+ MULTIDL_ERROR = r'Free account does not allow to download more than one file at the same time'
+
+
+ def handleFree(self):
+ self.sanitize_url()
+ self.html = self.load(self.pyfile.url)
+
+ self.fid = re.search(r'<input type="hidden" name="slow_id" value="([^"]+)">', self.html).group(1)
+ self.html = self.load(self.pyfile.url, post={'yt0': '', 'slow_id': self.fid})
+
+ if ">Downloading is not possible" in self.html:
+ self.fail("Free user can't download large files")
+
+ m = re.search(r"function download\(\){.*window\.location\.href = '([^']+)';", self.html, re.S)
+ if m: # Direct mode
+ self.startDownload(m.group(1))
+ else:
+ self.handleCaptcha()
+
+ self.wait(30)
+
+ self.html = self.load(self.pyfile.url, post={'uniqueId': self.fid, 'free': 1})
+
+ m = re.search(self.WAIT_PATTERN, self.html)
+ if m:
+ self.logDebug("Hoster told us to wait for %s" % m.group(1))
+ # string to time convert courtesy of https://stackoverflow.com/questions/10663720
+ ftr = [3600, 60, 1]
+ wait_time = sum([a * b for a, b in zip(ftr, map(int, m.group(1).split(':')))])
+ self.wait(wait_time, True)
+ self.retry()
+
+ m = re.search(self.MULTIDL_ERROR, self.html)
+ if m:
+ # if someone is already downloading on our line, wait 30min and retry
+ self.logDebug("Already downloading, waiting for 30 minutes")
+ self.wait(30 * 60, True)
+ self.retry()
+
+ m = re.search(self.LINK_PATTERN, self.html)
+ if m is None:
+ self.error(_("LINK_PATTERN not found"))
+ self.startDownload(m.group(1))
+
+
+ def handleCaptcha(self):
+ recaptcha = ReCaptcha(self)
+
+ for _i in xrange(5):
+ post_data = {'free': 1,
+ 'freeDownloadRequest': 1,
+ 'uniqueId': self.fid,
+ 'yt0': ''}
+
+ m = re.search(self.CAPTCHA_PATTERN, self.html)
+ if m:
+ captcha_url = urljoin(self.base_url, m.group(1))
+ post_data['CaptchaForm[code]'] = self.decryptCaptcha(captcha_url)
+ else:
+ challenge, response = recaptcha.challenge()
+ post_data.update({'recaptcha_challenge_field': challenge,
+ 'recaptcha_response_field': response})
+
+ self.html = self.load(self.pyfile.url, post=post_data)
+
+ if 'recaptcha' not in self.html:
+ self.correctCaptcha()
+ break
+ else:
+ self.invalidCaptcha()
+ else:
+ self.fail(_("All captcha attempts failed"))
+
+
+ def startDownload(self, url):
+ d = urljoin(self.base_url, url)
+ self.download(d, disposition=True)
+
+
+ def sanitize_url(self):
+ header = self.load(self.pyfile.url, just_header=True)
+ if 'location' in header:
+ self.pyfile.url = header['location']
+ p = urlparse(self.pyfile.url)
+ self.base_url = "%s://%s" % (p.scheme, p.hostname)
+
+
+getInfo = create_getInfo(Keep2shareCc)
diff --git a/pyload/plugins/hoster/KickloadCom.py b/pyload/plugins/hoster/KickloadCom.py
new file mode 100644
index 000000000..88c84390c
--- /dev/null
+++ b/pyload/plugins/hoster/KickloadCom.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class KickloadCom(DeadHoster):
+ __name__ = "KickloadCom"
+ __type__ = "hoster"
+ __version__ = "0.21"
+
+ __pattern__ = r'http://(?:www\.)?kickload\.com/get/.+'
+
+ __description__ = """Kickload.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("mkaay", "mkaay@mkaay.de")]
+
+
+getInfo = create_getInfo(KickloadCom)
diff --git a/pyload/plugins/hoster/LinksnappyCom.py b/pyload/plugins/hoster/LinksnappyCom.py
index c37006ac2..d7991ff3c 100644
--- a/pyload/plugins/hoster/LinksnappyCom.py
+++ b/pyload/plugins/hoster/LinksnappyCom.py
@@ -5,7 +5,7 @@ import re
from urlparse import urlsplit
from pyload.utils import json_loads, json_dumps
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class LinksnappyCom(Hoster):
diff --git a/pyload/plugins/hoster/LomafileCom.py b/pyload/plugins/hoster/LomafileCom.py
index a7ce39d37..2c4bd37a2 100644
--- a/pyload/plugins/hoster/LomafileCom.py
+++ b/pyload/plugins/hoster/LomafileCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class LomafileCom(XFSHoster):
diff --git a/pyload/plugins/hoster/MegaCoNz.py b/pyload/plugins/hoster/MegaCoNz.py
new file mode 100644
index 000000000..f09a5cdd5
--- /dev/null
+++ b/pyload/plugins/hoster/MegaCoNz.py
@@ -0,0 +1,144 @@
+# -*- coding: utf-8 -*-
+
+import random
+import re
+
+from array import array
+from base64 import standard_b64decode
+from os import remove
+
+from Crypto.Cipher import AES
+from Crypto.Util import Counter
+from pycurl import SSL_CIPHER_LIST
+
+from pyload.utils import json_loads, json_dumps
+from pyload.plugins.internal.Hoster import Hoster
+
+
+class MegaCoNz(Hoster):
+ __name__ = "MegaCoNz"
+ __type__ = "hoster"
+ __version__ = "0.16"
+
+ __pattern__ = r'https?://(\w+\.)?mega\.co\.nz/#!([\w!-]+)'
+
+ __description__ = """Mega.co.nz hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("RaNaN", "ranan@pyload.org")]
+
+
+ API_URL = "https://g.api.mega.co.nz/cs?id=%d"
+ FILE_SUFFIX = ".crypted"
+
+
+ def b64_decode(self, data):
+ data = data.replace("-", "+").replace("_", "/")
+ return standard_b64decode(data + '=' * (-len(data) % 4))
+
+
+ def getCipherKey(self, key):
+ """ Construct the cipher key from the given data """
+ a = array("I", key)
+ key_array = array("I", [a[0] ^ a[4], a[1] ^ a[5], a[2] ^ a[6], a[3] ^ a[7]])
+ return key_array
+
+
+ def callApi(self, **kwargs):
+ """ Dispatch a call to the api, see https://mega.co.nz/#developers """
+ # generate a session id, no idea where to obtain elsewhere
+ uid = random.randint(10 << 9, 10 ** 10)
+
+ res = self.load(self.API_URL % uid, post=json_dumps([kwargs]))
+ self.logDebug("Api Response: " + res)
+ return json_loads(res)
+
+
+ def decryptAttr(self, data, key):
+ cbc = AES.new(self.getCipherKey(key), AES.MODE_CBC, "\0" * 16)
+ attr = cbc.decrypt(self.b64_decode(data))
+ self.logDebug("Decrypted Attr: " + attr)
+ if not attr.startswith("MEGA"):
+ self.fail(_("Decryption failed"))
+
+ # Data is padded, 0-bytes must be stripped
+ return json_loads(re.search(r'{.+?}', attr).group(0))
+
+
+ def decryptFile(self, key):
+ """ Decrypts the file at lastDownload` """
+
+ # upper 64 bit of counter start
+ n = key[16:24]
+
+ # convert counter to long and shift bytes
+ ctr = Counter.new(128, initial_value=long(n.encode("hex"), 16) << 64)
+ cipher = AES.new(self.getCipherKey(key), AES.MODE_CTR, counter=ctr)
+
+ self.pyfile.setStatus("decrypting")
+
+ file_crypted = self.lastDownload
+ file_decrypted = file_crypted.rsplit(self.FILE_SUFFIX)[0]
+
+ try:
+ f = open(file_crypted, "rb")
+ df = open(file_decrypted, "wb")
+ except IOError, e:
+ self.fail(str(e))
+
+ # TODO: calculate CBC-MAC for checksum
+
+ size = 2 ** 15 # buffer size, 32k
+ while True:
+ buf = f.read(size)
+ if not buf:
+ break
+
+ df.write(cipher.decrypt(buf))
+
+ f.close()
+ df.close()
+ remove(file_crypted)
+
+ self.lastDownload = file_decrypted
+
+
+ def process(self, pyfile):
+ key = None
+
+ # match is guaranteed because plugin was chosen to handle url
+ node = re.match(self.__pattern__, pyfile.url).group(2)
+ if "!" in node:
+ node, key = node.split("!")
+
+ self.logDebug("File id: %s | Key: %s" % (node, key))
+
+ if not key:
+ self.fail(_("No file key provided in the URL"))
+
+ # g is for requesting a download url
+ # this is similar to the calls in the mega js app, documentation is very bad
+ dl = self.callApi(a="g", g=1, p=node, ssl=1)[0]
+
+ if "e" in dl:
+ e = dl['e']
+ # ETEMPUNAVAIL (-18): Resource temporarily not available, please try again later
+ if e == -18:
+ self.retry()
+ else:
+ self.fail(_("Error code:") + e)
+
+ # TODO: map other error codes, e.g
+ # EACCESS (-11): Access violation (e.g., trying to write to a read-only share)
+
+ key = self.b64_decode(key)
+ attr = self.decryptAttr(dl['at'], key)
+
+ pyfile.name = attr['n'] + self.FILE_SUFFIX
+
+ self.req.http.c.setopt(SSL_CIPHER_LIST, "RC4-MD5:DEFAULT")
+
+ self.download(dl['g'])
+ self.decryptFile(key)
+
+ # Everything is finished and final name can be set
+ pyfile.name = attr['n']
diff --git a/pyload/plugins/hoster/MegaDebridEu.py b/pyload/plugins/hoster/MegaDebridEu.py
index aaf5419e6..1354c0e3d 100644
--- a/pyload/plugins/hoster/MegaDebridEu.py
+++ b/pyload/plugins/hoster/MegaDebridEu.py
@@ -5,7 +5,7 @@ import re
from urllib import unquote_plus
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class MegaDebridEu(Hoster):
diff --git a/pyload/plugins/hoster/MegaRapidCz.py b/pyload/plugins/hoster/MegaRapidCz.py
new file mode 100644
index 000000000..f49d0e1ec
--- /dev/null
+++ b/pyload/plugins/hoster/MegaRapidCz.py
@@ -0,0 +1,71 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from pycurl import HTTPHEADER
+
+from pyload.network.RequestFactory import getRequest
+from pyload.plugins.internal.SimpleHoster import SimpleHoster, parseFileInfo
+
+
+def getInfo(urls):
+ h = getRequest()
+ h.c.setopt(HTTPHEADER,
+ ["Accept: text/html",
+ "User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0"])
+
+ for url in urls:
+ html = h.load(url, decode=True)
+ yield parseFileInfo(MegaRapidCz, url, html)
+
+
+class MegaRapidCz(SimpleHoster):
+ __name__ = "MegaRapidCz"
+ __type__ = "hoster"
+ __version__ = "0.54"
+
+ __pattern__ = r'http://(?:www\.)?(share|mega)rapid\.cz/soubor/\d+/.+'
+
+ __description__ = """MegaRapid.cz hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("MikyWoW", "mikywow@seznam.cz"),
+ ("zoidberg", "zoidberg@mujmail.cz"),
+ ("stickell", "l.stickell@yahoo.it"),
+ ("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ NAME_PATTERN = r'<h1[^>]*><span[^>]*>(?:<a[^>]*>)?(?P<N>[^<]+)'
+ SIZE_PATTERN = r'<td class="i">Velikost:</td>\s*<td class="h"><strong>\s*(?P<S>[\d.,]+) (?P<U>[\w^_]+)</strong></td>'
+ OFFLINE_PATTERN = ur'Nastala chyba 404|Soubor byl smazán'
+
+ FORCE_CHECK_TRAFFIC = True
+
+ LINK_PATTERN = r'<a href="([^"]+)" title="Stahnout">([^<]+)</a>'
+ ERR_LOGIN_PATTERN = ur'<div class="error_div"><strong>Stahování je přístupné pouze přihlášenÃœm uÅŸivatelům'
+ ERR_CREDIT_PATTERN = ur'<div class="error_div"><strong>Stahování zdarma je moÅŸné jen přes náš'
+
+
+ def setup(self):
+ self.chunkLimit = 1
+
+
+ def handlePremium(self):
+ try:
+ self.html = self.load(self.pyfile.url, decode=True)
+ except BadHeader, e:
+ self.account.relogin(self.user)
+ self.retry(wait_time=60, reason=str(e))
+
+ m = re.search(self.LINK_PATTERN, self.html)
+ if m:
+ link = m.group(1)
+ self.logDebug("Premium link: %s" % link)
+ self.download(link, disposition=True)
+ else:
+ if re.search(self.ERR_LOGIN_PATTERN, self.html):
+ self.relogin(self.user)
+ self.retry(wait_time=60, reason=_("User login failed"))
+ elif re.search(self.ERR_CREDIT_PATTERN, self.html):
+ self.fail(_("Not enough credit left"))
+ else:
+ self.fail(_("Download link not found"))
diff --git a/pyload/plugins/hoster/MegacrypterCom.py b/pyload/plugins/hoster/MegacrypterCom.py
index 4633f7d30..1ebd167f3 100644
--- a/pyload/plugins/hoster/MegacrypterCom.py
+++ b/pyload/plugins/hoster/MegacrypterCom.py
@@ -4,7 +4,7 @@ import re
from pyload.utils import json_loads, json_dumps
-from module.plugins.hoster.MegaCoNz import MegaCoNz
+from pyload.plugins.hoster.MegaCoNz import MegaCoNz
class MegacrypterCom(MegaCoNz):
diff --git a/pyload/plugins/hoster/MegauploadCom.py b/pyload/plugins/hoster/MegauploadCom.py
new file mode 100644
index 000000000..20700a3d0
--- /dev/null
+++ b/pyload/plugins/hoster/MegauploadCom.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class MegauploadCom(DeadHoster):
+ __name__ = "MegauploadCom"
+ __type__ = "hoster"
+ __version__ = "0.31"
+
+ __pattern__ = r'http://(?:www\.)?megaupload\.com/\?.*&?(d|v)=\w+'
+
+ __description__ = """Megaupload.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("spoob", "spoob@pyload.org")]
+
+
+getInfo = create_getInfo(MegauploadCom)
diff --git a/pyload/plugins/hoster/MegavideoCom.py b/pyload/plugins/hoster/MegavideoCom.py
new file mode 100644
index 000000000..aa458fa2c
--- /dev/null
+++ b/pyload/plugins/hoster/MegavideoCom.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class MegavideoCom(DeadHoster):
+ __name__ = "MegavideoCom"
+ __type__ = "hoster"
+ __version__ = "0.21"
+
+ __pattern__ = r'http://(?:www\.)?megavideo\.com/\?.*&?(d|v)=\w+'
+
+ __description__ = """Megavideo.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("jeix", "jeix@hasnomail.de"),
+ ("mkaay", "mkaay@mkaay.de")]
+
+
+getInfo = create_getInfo(MegavideoCom)
diff --git a/pyload/plugins/hoster/MovReelCom.py b/pyload/plugins/hoster/MovReelCom.py
index cd1626f6f..39216a295 100644
--- a/pyload/plugins/hoster/MovReelCom.py
+++ b/pyload/plugins/hoster/MovReelCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class MovReelCom(XFSHoster):
diff --git a/pyload/plugins/hoster/MyfastfileCom.py b/pyload/plugins/hoster/MyfastfileCom.py
index 14ed51ea7..cb1148389 100644
--- a/pyload/plugins/hoster/MyfastfileCom.py
+++ b/pyload/plugins/hoster/MyfastfileCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import json_loads
diff --git a/pyload/plugins/hoster/MyvideoDe.py b/pyload/plugins/hoster/MyvideoDe.py
index 886896056..8fbd3a772 100644
--- a/pyload/plugins/hoster/MyvideoDe.py
+++ b/pyload/plugins/hoster/MyvideoDe.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import html_unescape
diff --git a/pyload/plugins/hoster/NahrajCz.py b/pyload/plugins/hoster/NahrajCz.py
new file mode 100644
index 000000000..188e2b1e4
--- /dev/null
+++ b/pyload/plugins/hoster/NahrajCz.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class NahrajCz(DeadHoster):
+ __name__ = "NahrajCz"
+ __type__ = "hoster"
+ __version__ = "0.21"
+
+ __pattern__ = r'http://(?:www\.)?nahraj\.cz/content/download/.+'
+
+ __description__ = """Nahraj.cz hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+
+
+getInfo = create_getInfo(NahrajCz)
diff --git a/pyload/plugins/hoster/NetloadIn.py b/pyload/plugins/hoster/NetloadIn.py
index 5889611bb..b517fe455 100644
--- a/pyload/plugins/hoster/NetloadIn.py
+++ b/pyload/plugins/hoster/NetloadIn.py
@@ -5,7 +5,7 @@ import re
from time import sleep, time
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.Plugin import chunks
diff --git a/pyload/plugins/hoster/NosuploadCom.py b/pyload/plugins/hoster/NosuploadCom.py
index b2255ca54..f70d64551 100644
--- a/pyload/plugins/hoster/NosuploadCom.py
+++ b/pyload/plugins/hoster/NosuploadCom.py
@@ -2,7 +2,7 @@
import re
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class NosuploadCom(XFSHoster):
diff --git a/pyload/plugins/hoster/NovafileCom.py b/pyload/plugins/hoster/NovafileCom.py
index 5c4dfddca..8d0677ec8 100644
--- a/pyload/plugins/hoster/NovafileCom.py
+++ b/pyload/plugins/hoster/NovafileCom.py
@@ -4,7 +4,7 @@
# http://novafile.com/vfun4z6o2cit
# http://novafile.com/s6zrr5wemuz4
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class NovafileCom(XFSHoster):
diff --git a/pyload/plugins/hoster/NowVideoAt.py b/pyload/plugins/hoster/NowVideoAt.py
new file mode 100644
index 000000000..e17e2e256
--- /dev/null
+++ b/pyload/plugins/hoster/NowVideoAt.py
@@ -0,0 +1,44 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from pyload.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
+
+
+class NowVideoAt(SimpleHoster):
+ __name__ = "NowVideoAt"
+ __type__ = "hoster"
+ __version__ = "0.05"
+
+ __pattern__ = r'http://(?:www\.)?nowvideo\.(at|ch|co|eu|sx)/(video|mobile/#/videos)/(?P<ID>\w+)'
+
+ __description__ = """NowVideo.at hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ URL_REPLACEMENTS = [(__pattern__, r'http://www.nowvideo.at/video/\g<ID>')]
+
+ NAME_PATTERN = r'<h4>(?P<N>.+?)<'
+ OFFLINE_PATTERN = r'>This file no longer exists'
+
+ LINK_FREE_PATTERN = r'<source src="(.+?)"'
+ LINK_PREMIUM_PATTERN = r'<div id="content_player" >\s*<a href="(.+?)"'
+
+
+ def setup(self):
+ self.multiDL = True
+ self.resumeDownload = True
+
+
+ def handleFree(self):
+ self.html = self.load("http://www.nowvideo.at/mobile/video.php", get={'id': self.info['ID']})
+
+ m = re.search(self.LINK_FREE_PATTERN, self.html)
+ if m is None:
+ self.error(_("Free download link not found"))
+
+ self.download(m.group(1))
+
+
+getInfo = create_getInfo(NowVideoAt)
diff --git a/pyload/plugins/hoster/OboomCom.py b/pyload/plugins/hoster/OboomCom.py
index fcd73bf05..db2c0597b 100644
--- a/pyload/plugins/hoster/OboomCom.py
+++ b/pyload/plugins/hoster/OboomCom.py
@@ -6,7 +6,7 @@
import re
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.internal.CaptchaService import ReCaptcha
diff --git a/pyload/plugins/hoster/OronCom.py b/pyload/plugins/hoster/OronCom.py
new file mode 100644
index 000000000..22d6e65b3
--- /dev/null
+++ b/pyload/plugins/hoster/OronCom.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class OronCom(DeadHoster):
+ __name__ = "OronCom"
+ __type__ = "hoster"
+ __version__ = "0.14"
+
+ __pattern__ = r'https?://(?:www\.)?oron\.com/\w{12}'
+
+ __description__ = """Oron.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("chrox", "chrox@pyload.org"),
+ ("DHMH", "DHMH@pyload.org")]
+
+
+getInfo = create_getInfo(OronCom)
diff --git a/pyload/plugins/hoster/OverLoadMe.py b/pyload/plugins/hoster/OverLoadMe.py
index 1cea276f9..3d07db489 100644
--- a/pyload/plugins/hoster/OverLoadMe.py
+++ b/pyload/plugins/hoster/OverLoadMe.py
@@ -6,7 +6,7 @@ from random import randrange
from urllib import unquote
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import parseFileSize
diff --git a/pyload/plugins/hoster/PandaplaNet.py b/pyload/plugins/hoster/PandaplaNet.py
new file mode 100644
index 000000000..f3124aaae
--- /dev/null
+++ b/pyload/plugins/hoster/PandaplaNet.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class PandaplaNet(DeadHoster):
+ __name__ = "PandaplaNet"
+ __type__ = "hoster"
+ __version__ = "0.03"
+
+ __pattern__ = r'http://(?:www\.)?pandapla\.net/\w{12}'
+
+ __description__ = """Pandapla.net hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("t4skforce", "t4skforce1337[AT]gmail[DOT]com")]
+
+
+getInfo = create_getInfo(PandaplaNet)
diff --git a/pyload/plugins/hoster/PornhostCom.py b/pyload/plugins/hoster/PornhostCom.py
index d83b61c10..7fd337485 100644
--- a/pyload/plugins/hoster/PornhostCom.py
+++ b/pyload/plugins/hoster/PornhostCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class PornhostCom(Hoster):
diff --git a/pyload/plugins/hoster/PornhubCom.py b/pyload/plugins/hoster/PornhubCom.py
index d6cbdfede..d89d24029 100644
--- a/pyload/plugins/hoster/PornhubCom.py
+++ b/pyload/plugins/hoster/PornhubCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class PornhubCom(Hoster):
diff --git a/pyload/plugins/hoster/PremiumTo.py b/pyload/plugins/hoster/PremiumTo.py
index 680b0b25d..305b6d1d1 100644
--- a/pyload/plugins/hoster/PremiumTo.py
+++ b/pyload/plugins/hoster/PremiumTo.py
@@ -4,7 +4,7 @@ from os import remove
from os.path import exists
from urllib import quote
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import fs_encode
diff --git a/pyload/plugins/hoster/PremiumizeMe.py b/pyload/plugins/hoster/PremiumizeMe.py
index 9eab5888c..177edb1a0 100644
--- a/pyload/plugins/hoster/PremiumizeMe.py
+++ b/pyload/plugins/hoster/PremiumizeMe.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class PremiumizeMe(Hoster):
diff --git a/pyload/plugins/hoster/PrzeklejPl.py b/pyload/plugins/hoster/PrzeklejPl.py
new file mode 100644
index 000000000..5e6056adb
--- /dev/null
+++ b/pyload/plugins/hoster/PrzeklejPl.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class PrzeklejPl(DeadHoster):
+ __name__ = "PrzeklejPl"
+ __type__ = "hoster"
+ __version__ = "0.11"
+
+ __pattern__ = r'http://(?:www\.)?przeklej\.pl/plik/.+'
+
+ __description__ = """Przeklej.pl hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+
+
+getInfo = create_getInfo(PrzeklejPl)
diff --git a/pyload/plugins/hoster/RPNetBiz.py b/pyload/plugins/hoster/RPNetBiz.py
index 30c6773bd..b2a89f48a 100644
--- a/pyload/plugins/hoster/RPNetBiz.py
+++ b/pyload/plugins/hoster/RPNetBiz.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import json_loads
diff --git a/pyload/plugins/hoster/RapidfileshareNet.py b/pyload/plugins/hoster/RapidfileshareNet.py
new file mode 100644
index 000000000..849ac2b68
--- /dev/null
+++ b/pyload/plugins/hoster/RapidfileshareNet.py
@@ -0,0 +1,31 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+
+
+class RapidfileshareNet(XFSHoster):
+ __name__ = "RapidfileshareNet"
+ __type__ = "hoster"
+ __version__ = "0.02"
+
+ __pattern__ = r'http://(?:www\.)?rapidfileshare\.net/\w{12}'
+
+ __description__ = """Rapidfileshare.net hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("guidobelix", "guidobelix@hotmail.it")]
+
+
+ HOSTER_DOMAIN = "rapidfileshare.net"
+
+ NAME_PATTERN = r'<input type="hidden" name="fname" value="(?P<N>.+?)">'
+ SIZE_PATTERN = r'>http://www.rapidfileshare.net/\w+?</font> \((?P<S>[\d.,]+) (?P<U>[\w^_]+)\)</font>'
+
+ OFFLINE_PATTERN = r'>No such file with this filename'
+ TEMP_OFFLINE_PATTERN = r'The page may have been renamed, removed or be temporarily unavailable.<'
+
+
+ def handlePremium(self):
+ self.fail(_("Premium download not implemented"))
+
+
+getInfo = create_getInfo(RapidfileshareNet)
diff --git a/pyload/plugins/hoster/RapidshareCom.py b/pyload/plugins/hoster/RapidshareCom.py
index 4b8633fef..97823ba96 100644
--- a/pyload/plugins/hoster/RapidshareCom.py
+++ b/pyload/plugins/hoster/RapidshareCom.py
@@ -3,7 +3,7 @@
import re
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
def getInfo(urls):
diff --git a/pyload/plugins/hoster/RarefileNet.py b/pyload/plugins/hoster/RarefileNet.py
index cd60ec65e..fb54f6431 100644
--- a/pyload/plugins/hoster/RarefileNet.py
+++ b/pyload/plugins/hoster/RarefileNet.py
@@ -2,7 +2,7 @@
import re
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
from pyload.utils import html_unescape
diff --git a/pyload/plugins/hoster/RealdebridCom.py b/pyload/plugins/hoster/RealdebridCom.py
index f839dc613..2ca9970e0 100644
--- a/pyload/plugins/hoster/RealdebridCom.py
+++ b/pyload/plugins/hoster/RealdebridCom.py
@@ -7,7 +7,7 @@ from urllib import quote, unquote
from time import time
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import parseFileSize
diff --git a/pyload/plugins/hoster/RedtubeCom.py b/pyload/plugins/hoster/RedtubeCom.py
index 50c6ba9e3..b1272f68d 100644
--- a/pyload/plugins/hoster/RedtubeCom.py
+++ b/pyload/plugins/hoster/RedtubeCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import html_unescape
diff --git a/pyload/plugins/hoster/RehostTo.py b/pyload/plugins/hoster/RehostTo.py
index 08c43ad16..d9855c796 100644
--- a/pyload/plugins/hoster/RehostTo.py
+++ b/pyload/plugins/hoster/RehostTo.py
@@ -2,7 +2,7 @@
from urllib import quote, unquote
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class RehostTo(Hoster):
diff --git a/pyload/plugins/hoster/RyushareCom.py b/pyload/plugins/hoster/RyushareCom.py
index f41e4bfbf..ab6bf1017 100644
--- a/pyload/plugins/hoster/RyushareCom.py
+++ b/pyload/plugins/hoster/RyushareCom.py
@@ -5,7 +5,7 @@
import re
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
from pyload.plugins.internal.CaptchaService import SolveMedia
diff --git a/pyload/plugins/hoster/SecureUploadEu.py b/pyload/plugins/hoster/SecureUploadEu.py
index 64e6456a9..6939e4f6d 100644
--- a/pyload/plugins/hoster/SecureUploadEu.py
+++ b/pyload/plugins/hoster/SecureUploadEu.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class SecureUploadEu(XFSHoster):
diff --git a/pyload/plugins/hoster/SendmywayCom.py b/pyload/plugins/hoster/SendmywayCom.py
index 4254922fc..cb82fb19d 100644
--- a/pyload/plugins/hoster/SendmywayCom.py
+++ b/pyload/plugins/hoster/SendmywayCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class SendmywayCom(XFSHoster):
diff --git a/pyload/plugins/hoster/ShareonlineBiz.py b/pyload/plugins/hoster/ShareonlineBiz.py
index 73d598cb9..0769cfe17 100644
--- a/pyload/plugins/hoster/ShareonlineBiz.py
+++ b/pyload/plugins/hoster/ShareonlineBiz.py
@@ -5,7 +5,7 @@ import re
from time import time
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.Plugin import chunks
from pyload.plugins.internal.CaptchaService import ReCaptcha
diff --git a/pyload/plugins/hoster/ShareplaceCom.py b/pyload/plugins/hoster/ShareplaceCom.py
index 60d93698a..6e11de05c 100644
--- a/pyload/plugins/hoster/ShareplaceCom.py
+++ b/pyload/plugins/hoster/ShareplaceCom.py
@@ -4,7 +4,7 @@ import re
from urllib import unquote
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class ShareplaceCom(Hoster):
diff --git a/pyload/plugins/hoster/SharingmatrixCom.py b/pyload/plugins/hoster/SharingmatrixCom.py
new file mode 100644
index 000000000..7459c12b6
--- /dev/null
+++ b/pyload/plugins/hoster/SharingmatrixCom.py
@@ -0,0 +1,19 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class SharingmatrixCom(DeadHoster):
+ __name__ = "SharingmatrixCom"
+ __type__ = "hoster"
+ __version__ = "0.01"
+
+ __pattern__ = r'http://(?:www\.)?sharingmatrix\.com/file/\w+'
+
+ __description__ = """Sharingmatrix.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("jeix", "jeix@hasnomail.de"),
+ ("paulking", None)]
+
+
+getInfo = create_getInfo(SharingmatrixCom)
diff --git a/pyload/plugins/hoster/SimplyPremiumCom.py b/pyload/plugins/hoster/SimplyPremiumCom.py
index 0840bc8a2..bb431a5dd 100644
--- a/pyload/plugins/hoster/SimplyPremiumCom.py
+++ b/pyload/plugins/hoster/SimplyPremiumCom.py
@@ -4,7 +4,7 @@ import re
from datetime import datetime, timedelta
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.hoster.UnrestrictLi import secondsToMidnight
diff --git a/pyload/plugins/hoster/SimplydebridCom.py b/pyload/plugins/hoster/SimplydebridCom.py
index f34f15ab2..5092be32a 100644
--- a/pyload/plugins/hoster/SimplydebridCom.py
+++ b/pyload/plugins/hoster/SimplydebridCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class SimplydebridCom(Hoster):
diff --git a/pyload/plugins/hoster/SockshareCom.py b/pyload/plugins/hoster/SockshareCom.py
index aabb8dcd1..d28041893 100644
--- a/pyload/plugins/hoster/SockshareCom.py
+++ b/pyload/plugins/hoster/SockshareCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
class SockshareCom(DeadHoster):
diff --git a/pyload/plugins/hoster/SoundcloudCom.py b/pyload/plugins/hoster/SoundcloudCom.py
index 601ac774c..284f6ffbf 100644
--- a/pyload/plugins/hoster/SoundcloudCom.py
+++ b/pyload/plugins/hoster/SoundcloudCom.py
@@ -3,7 +3,7 @@
import pycurl
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class SoundcloudCom(Hoster):
diff --git a/pyload/plugins/hoster/StorageTo.py b/pyload/plugins/hoster/StorageTo.py
new file mode 100644
index 000000000..5ba0c145b
--- /dev/null
+++ b/pyload/plugins/hoster/StorageTo.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class StorageTo(DeadHoster):
+ __name__ = "StorageTo"
+ __type__ = "hoster"
+ __version__ = "0.01"
+
+ __pattern__ = r'http://(?:www\.)?storage\.to/get/.+'
+
+ __description__ = """Storage.to hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("mkaay", "mkaay@mkaay.de")]
+
+
+getInfo = create_getInfo(StorageTo)
diff --git a/pyload/plugins/hoster/StreamCz.py b/pyload/plugins/hoster/StreamCz.py
index 1c1b7f204..c9d00863e 100644
--- a/pyload/plugins/hoster/StreamCz.py
+++ b/pyload/plugins/hoster/StreamCz.py
@@ -3,7 +3,7 @@
import re
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
def getInfo(urls):
diff --git a/pyload/plugins/hoster/StreamcloudEu.py b/pyload/plugins/hoster/StreamcloudEu.py
index 4f854a99d..5ae617095 100644
--- a/pyload/plugins/hoster/StreamcloudEu.py
+++ b/pyload/plugins/hoster/StreamcloudEu.py
@@ -2,7 +2,7 @@
import re
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class StreamcloudEu(XFSHoster):
diff --git a/pyload/plugins/hoster/TusfilesNet.py b/pyload/plugins/hoster/TusfilesNet.py
index 8c80455b4..3b4d7f92c 100644
--- a/pyload/plugins/hoster/TusfilesNet.py
+++ b/pyload/plugins/hoster/TusfilesNet.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class TusfilesNet(XFSHoster):
diff --git a/pyload/plugins/hoster/UnrestrictLi.py b/pyload/plugins/hoster/UnrestrictLi.py
index e807cda98..583a9f4a9 100644
--- a/pyload/plugins/hoster/UnrestrictLi.py
+++ b/pyload/plugins/hoster/UnrestrictLi.py
@@ -5,7 +5,7 @@ import re
from datetime import datetime, timedelta
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
def secondsToMidnight(gmt=0):
diff --git a/pyload/plugins/hoster/UpleaCom.py b/pyload/plugins/hoster/UpleaCom.py
new file mode 100644
index 000000000..7a7dd4870
--- /dev/null
+++ b/pyload/plugins/hoster/UpleaCom.py
@@ -0,0 +1,60 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from urlparse import urljoin
+
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+
+
+class UpleaCom(XFSHoster):
+ __name__ = "UpleaCom"
+ __type__ = "hoster"
+ __version__ = "0.04"
+
+ __pattern__ = r'https?://(?:www\.)?uplea\.com/dl/\w{15}'
+
+ __description__ = """Uplea.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Redleon", None)]
+
+
+ HOSTER_DOMAIN = "uplea.com"
+
+ NAME_PATTERN = r'class="agmd size18">(?P<N>.+?)<'
+ SIZE_PATTERN = r'size14">(?P<S>[\d.,]+) (?P<U>[\w^_])</span>'
+
+ OFFLINE_PATTERN = r'>You followed an invalid or expired link'
+
+ LINK_PATTERN = r'"(http?://\w+\.uplea\.com/anonym/.*?)"'
+ WAIT_PATTERN = r'timeText:([\d.]+),'
+ VARS_PATTERN = r'class="cel_tbl_step1_foot">\s<a href="(/step/.+)">'
+
+
+ def setup(self):
+ self.multiDL = False
+ self.chunkLimit = 1
+ self.resumeDownload = True
+
+
+ def handleFree(self):
+ m = re.search(self.VARS_PATTERN, self.html)
+ if m is None:
+ self.error("VARS_PATTERN not found")
+
+ self.html = self.load(urljoin("http://uplea.com/", m.groups(1)))
+
+ m = re.search(self.WAIT_PATTERN, self.html)
+ if m:
+ self.wait(m.group(1), True)
+ self.retry()
+
+ m = re.search(self.LINK_PATTERN, self.html)
+ if m is None:
+ self.error("LINK_PATTERN not found")
+
+ self.wait(15)
+ self.download(m.group(1), disposition=True)
+
+
+getInfo = create_getInfo(UpleaCom)
diff --git a/pyload/plugins/hoster/UploadboxCom.py b/pyload/plugins/hoster/UploadboxCom.py
new file mode 100644
index 000000000..89a525c67
--- /dev/null
+++ b/pyload/plugins/hoster/UploadboxCom.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class UploadboxCom(DeadHoster):
+ __name__ = "Uploadbox"
+ __type__ = "hoster"
+ __version__ = "0.05"
+
+ __pattern__ = r'http://(?:www\.)?uploadbox\.com/files/.+'
+
+ __description__ = """UploadBox.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+
+
+getInfo = create_getInfo(UploadboxCom)
diff --git a/pyload/plugins/hoster/UploadedTo.py b/pyload/plugins/hoster/UploadedTo.py
index 17e3a4a0f..c39df66ea 100644
--- a/pyload/plugins/hoster/UploadedTo.py
+++ b/pyload/plugins/hoster/UploadedTo.py
@@ -9,7 +9,7 @@ import re
from time import sleep
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.Plugin import chunks
from pyload.plugins.internal.CaptchaService import ReCaptcha
from pyload.utils import html_unescape, parseFileSize
diff --git a/pyload/plugins/hoster/UploadhereCom.py b/pyload/plugins/hoster/UploadhereCom.py
new file mode 100644
index 000000000..ba02ea07c
--- /dev/null
+++ b/pyload/plugins/hoster/UploadhereCom.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class UploadhereCom(DeadHoster):
+ __name__ = "UploadhereCom"
+ __type__ = "hoster"
+ __version__ = "0.12"
+
+ __pattern__ = r'http://(?:www\.)?uploadhere\.com/\w{10}'
+
+ __description__ = """Uploadhere.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+
+
+getInfo = create_getInfo(UploadhereCom)
diff --git a/pyload/plugins/hoster/UploadkingCom.py b/pyload/plugins/hoster/UploadkingCom.py
new file mode 100644
index 000000000..e9c536819
--- /dev/null
+++ b/pyload/plugins/hoster/UploadkingCom.py
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.DeadHoster import DeadHoster, create_getInfo
+
+
+class UploadkingCom(DeadHoster):
+ __name__ = "UploadkingCom"
+ __type__ = "hoster"
+ __version__ = "0.14"
+
+ __pattern__ = r'http://(?:www\.)?uploadking\.com/\w{10}'
+
+ __description__ = """UploadKing.com hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz")]
+
+
+getInfo = create_getInfo(UploadkingCom)
diff --git a/pyload/plugins/hoster/UptoboxCom.py b/pyload/plugins/hoster/UptoboxCom.py
index eeddb96b6..5aaa73286 100644
--- a/pyload/plugins/hoster/UptoboxCom.py
+++ b/pyload/plugins/hoster/UptoboxCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class UptoboxCom(XFSHoster):
diff --git a/pyload/plugins/hoster/VeehdCom.py b/pyload/plugins/hoster/VeehdCom.py
index 440993a67..326d0a18e 100644
--- a/pyload/plugins/hoster/VeehdCom.py
+++ b/pyload/plugins/hoster/VeehdCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class VeehdCom(Hoster):
diff --git a/pyload/plugins/hoster/VidPlayNet.py b/pyload/plugins/hoster/VidPlayNet.py
index 76af05edd..3a5198973 100644
--- a/pyload/plugins/hoster/VidPlayNet.py
+++ b/pyload/plugins/hoster/VidPlayNet.py
@@ -3,7 +3,7 @@
# Test links:
# BigBuckBunny_320x180.mp4 - 61.7 Mb - http://vidplay.net/38lkev0h3jv0
-from module.plugins.internal.XFSHoster import XFSHoster, create_getInfo
+from pyload.plugins.internal.XFSHoster import XFSHoster, create_getInfo
class VidPlayNet(XFSHoster):
diff --git a/pyload/plugins/hoster/WebshareCz.py b/pyload/plugins/hoster/WebshareCz.py
index fcdfd55bf..bb41fbd26 100644
--- a/pyload/plugins/hoster/WebshareCz.py
+++ b/pyload/plugins/hoster/WebshareCz.py
@@ -2,7 +2,7 @@
import re
-from module.network.RequestFactory import getURL
+from pyload.network.RequestFactory import getURL
from pyload.plugins.internal.SimpleHoster import SimpleHoster
diff --git a/pyload/plugins/hoster/XHamsterCom.py b/pyload/plugins/hoster/XHamsterCom.py
index acbcc2192..503022ec9 100644
--- a/pyload/plugins/hoster/XHamsterCom.py
+++ b/pyload/plugins/hoster/XHamsterCom.py
@@ -5,7 +5,7 @@ import re
from urllib import unquote
from pyload.utils import json_loads
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
def clean_json(json_expr):
diff --git a/pyload/plugins/hoster/XVideosCom.py b/pyload/plugins/hoster/XVideosCom.py
index 4fb288e51..9ab9e4484 100644
--- a/pyload/plugins/hoster/XVideosCom.py
+++ b/pyload/plugins/hoster/XVideosCom.py
@@ -4,7 +4,7 @@ import re
from urllib import unquote
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class XVideosCom(Hoster):
diff --git a/pyload/plugins/hoster/Xdcc.py b/pyload/plugins/hoster/Xdcc.py
index dc0cbc27a..de750ee58 100644
--- a/pyload/plugins/hoster/Xdcc.py
+++ b/pyload/plugins/hoster/Xdcc.py
@@ -10,7 +10,7 @@ from os import makedirs
from os.path import exists, join
from select import select
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.utils import safe_join
diff --git a/pyload/plugins/hoster/YoupornCom.py b/pyload/plugins/hoster/YoupornCom.py
index 46c7ebfcb..6063e6816 100644
--- a/pyload/plugins/hoster/YoupornCom.py
+++ b/pyload/plugins/hoster/YoupornCom.py
@@ -2,7 +2,7 @@
import re
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class YoupornCom(Hoster):
diff --git a/pyload/plugins/hoster/YourfilesTo.py b/pyload/plugins/hoster/YourfilesTo.py
index 9e21144b7..7cb94a2df 100644
--- a/pyload/plugins/hoster/YourfilesTo.py
+++ b/pyload/plugins/hoster/YourfilesTo.py
@@ -4,7 +4,7 @@ import re
from urllib import unquote
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class YourfilesTo(Hoster):
diff --git a/pyload/plugins/hoster/YoutubeCom.py b/pyload/plugins/hoster/YoutubeCom.py
index 0246d0997..7fdf848c1 100644
--- a/pyload/plugins/hoster/YoutubeCom.py
+++ b/pyload/plugins/hoster/YoutubeCom.py
@@ -6,7 +6,7 @@ import subprocess
from urllib import unquote
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
from pyload.plugins.internal.SimpleHoster import replace_patterns
from pyload.utils import html_unescape
diff --git a/pyload/plugins/hoster/ZDF.py b/pyload/plugins/hoster/ZDF.py
index 9d2ad446b..53939ae6c 100644
--- a/pyload/plugins/hoster/ZDF.py
+++ b/pyload/plugins/hoster/ZDF.py
@@ -4,7 +4,7 @@ import re
from xml.etree.ElementTree import fromstring
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
# Based on zdfm by Roland Beermann (http://github.com/enkore/zdfm/)
diff --git a/pyload/plugins/hoster/ZeveraCom.py b/pyload/plugins/hoster/ZeveraCom.py
index 769602964..c0c10215d 100644
--- a/pyload/plugins/hoster/ZeveraCom.py
+++ b/pyload/plugins/hoster/ZeveraCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Hoster import Hoster
+from pyload.plugins.internal.Hoster import Hoster
class ZeveraCom(Hoster):
diff --git a/pyload/plugins/base/Account.py b/pyload/plugins/internal/Account.py
index acb5c7d8b..e6895f119 100644
--- a/pyload/plugins/base/Account.py
+++ b/pyload/plugins/internal/Account.py
@@ -29,7 +29,7 @@ class Account(Base):
#: after that time (in minutes) pyload will relogin the account
- login_timeout = 10 * 60
+ login_timeout = 10 * 60
#: after that time (in minutes) account data will be reloaded
info_threshold = 10 * 60
diff --git a/pyload/plugins/base/Addon.py b/pyload/plugins/internal/Addon.py
index 2dfeba83c..1aa51c69a 100644
--- a/pyload/plugins/base/Addon.py
+++ b/pyload/plugins/internal/Addon.py
@@ -24,15 +24,16 @@ class Addon(Base):
"""
Base class for addon plugins.
"""
- __name__ = "Addon"
- __type__ = "addon"
- __version__ = "0.2"
+ __name__ = "Addon"
+ __type__ = "addon"
+ __version__ = "0.03"
- __config__ = [("name", "type", "desc", "default")]
+ __config__ = [] #: [("name", "type", "desc", "default")]
__description__ = """Interface for addon"""
- __authors__ = [("mkaay", "mkaay@mkaay.de"),
- ("RaNaN", "RaNaN@pyload.org")]
+ __license__ = "GPLv3"
+ __authors__ = [("mkaay", "mkaay@mkaay.de"),
+ ("RaNaN", "RaNaN@pyload.org")]
#: automatically register event listeners for functions, attribute will be deleted dont use it yourself
@@ -50,7 +51,7 @@ class Addon(Base):
Base.__init__(self, core)
#: Provide information in dict here, usable by API `getInfo`
- self.info = None
+ self.info = {}
#: Callback of periodical job task, used by AddonManager
self.cb = None
@@ -86,7 +87,8 @@ class Addon(Base):
def _periodical(self):
try:
- if self.isActivated(): self.periodical()
+ if self.isActivated():
+ self.periodical()
except Exception, e:
self.logError(_("Error executing addon: %s") % e)
if self.core.debug:
@@ -98,14 +100,17 @@ class Addon(Base):
def __repr__(self):
return "<Addon %s>" % self.__name__
+
def setup(self):
""" more init stuff if needed """
pass
+
def unload(self):
""" called when addon was deactivated """
pass
+
def isActivated(self):
""" checks if addon is activated"""
return self.config.getPlugin(self.__name__, "activated")
@@ -115,36 +120,47 @@ class Addon(Base):
def coreReady(self):
pass
+
def coreExiting(self):
pass
+
def downloadPreparing(self, pyfile):
pass
+
def downloadFinished(self, pyfile):
pass
+
def downloadFailed(self, pyfile):
pass
+
def packageFinished(self, pypack):
pass
+
def beforeReconnecting(self, ip):
pass
+
def afterReconnecting(self, ip):
pass
+
def periodical(self):
pass
+
def newCaptchaTask(self, task):
""" new captcha task for the plugin, it MUST set the handler and timeout or will be ignored """
pass
+
def captchaCorrect(self, task):
pass
+
def captchaInvalid(self, task):
pass
diff --git a/pyload/plugins/base/Captcha.py b/pyload/plugins/internal/Captcha.py
index 86b073710..b2fd980e2 100644
--- a/pyload/plugins/base/Captcha.py
+++ b/pyload/plugins/internal/Captcha.py
@@ -6,17 +6,19 @@ from pyload.plugins.Plugin import Plugin
class Captcha(Plugin):
- __name__ = "Captcha"
- __version__ = "0.09"
+ __name__ = "Captcha"
+ __type__ = "captcha"
+ __version__ = "0.14"
__description__ = """Base captcha service plugin"""
- __authors__ = [("pyLoad Team", "admin@pyload.org")]
+ __license__ = "GPLv3"
+ __authors__ = [("pyLoad Team", "admin@pyload.org")]
- key = None
-
KEY_PATTERN = None
+ key = None #: last key detected
+
def __init__(self, plugin):
self.plugin = plugin
@@ -27,8 +29,8 @@ class Captcha(Plugin):
if hasattr(self.plugin, "html") and self.plugin.html:
html = self.plugin.html
else:
- errmsg = "%s html missing" % self.__name__
- self.plugin.fail(errmsg)
+ errmsg = _("%s html not found") % self.__name__
+ self.plugin.fail(errmsg) #@TODO: replace all plugin.fail(errmsg) with plugin.error(errmsg) in 0.4.10
raise TypeError(errmsg)
m = re.search(self.KEY_PATTERN, html)
diff --git a/pyload/plugins/base/Container.py b/pyload/plugins/internal/Container.py
index 1bb2e204b..4bd6644f9 100644
--- a/pyload/plugins/base/Container.py
+++ b/pyload/plugins/internal/Container.py
@@ -5,7 +5,7 @@ import re
from os import remove
from os.path import basename, exists
-from pyload.plugins.base.Crypter import Crypter
+from pyload.plugins.internal.Crypter import Crypter
from pyload.utils import safe_join
@@ -14,7 +14,7 @@ class Container(Crypter):
__type__ = "container"
__version__ = "0.01"
- __pattern__ = None
+ __pattern__ = r'^unmatchable$'
__config__ = [] #: [("name", "type", "desc", "default")]
__description__ = """Base container decrypter plugin"""
diff --git a/pyload/plugins/base/Crypter.py b/pyload/plugins/internal/Crypter.py
index 0a79300dd..ed92357a5 100644
--- a/pyload/plugins/base/Crypter.py
+++ b/pyload/plugins/internal/Crypter.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
from pyload.plugins.Plugin import Plugin
-from module.utils import save_path
+from pyload.utils import save_filename
class Crypter(Plugin):
@@ -9,7 +9,7 @@ class Crypter(Plugin):
__type__ = "crypter"
__version__ = "0.05"
- __pattern__ = None
+ __pattern__ = r'^unmatchable$'
__config__ = [("use_subfolder", "bool", "Save package to subfolder", True), #: Overrides core.config['general']['folder_per_package']
("subfolder_per_package", "bool", "Create a subfolder for each package", True)]
@@ -98,7 +98,7 @@ class Crypter(Plugin):
if not folder:
folder = name.replace("http://", "").replace(":", "").replace("/", "_").replace("\\", "_")
- folder = save_path(folder) #@TODO: move to core code
+ folder = save_filename(folder) #@TODO: move to core code
setFolder(folder)
self.logDebug("Set package %(name)s folder to: %(folder)s" % {"name": name, "folder": folder})
diff --git a/pyload/plugins/internal/DeadCrypter.py b/pyload/plugins/internal/DeadCrypter.py
index 83aed6d43..ad99c6a13 100644
--- a/pyload/plugins/internal/DeadCrypter.py
+++ b/pyload/plugins/internal/DeadCrypter.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Crypter import Crypter as _Crypter
+from pyload.plugins.internal.Crypter import Crypter as _Crypter
class DeadCrypter(_Crypter):
diff --git a/pyload/plugins/internal/DeadHoster.py b/pyload/plugins/internal/DeadHoster.py
index 76a7b5d80..3c59f1489 100644
--- a/pyload/plugins/internal/DeadHoster.py
+++ b/pyload/plugins/internal/DeadHoster.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.Hoster import Hoster as _Hoster
+from pyload.plugins.internal.Hoster import Hoster as _Hoster
def create_getInfo(plugin):
diff --git a/pyload/plugins/base/Hoster.py b/pyload/plugins/internal/Hoster.py
index a89727ba7..ea225262e 100644
--- a/pyload/plugins/base/Hoster.py
+++ b/pyload/plugins/internal/Hoster.py
@@ -13,7 +13,7 @@ class Hoster(Plugin):
__type__ = "hoster"
__version__ = "0.02"
- __pattern__ = None
+ __pattern__ = r'^unmatchable$'
__config__ = [] #: [("name", "type", "desc", "default")]
__description__ = """Base hoster plugin"""
diff --git a/pyload/plugins/internal/MultiHoster.py b/pyload/plugins/internal/MultiHoster.py
index 97cbb4591..88a9c888b 100644
--- a/pyload/plugins/internal/MultiHoster.py
+++ b/pyload/plugins/internal/MultiHoster.py
@@ -2,14 +2,14 @@
import re
-from pyload.plugins.base.Addon import Addon
+from pyload.plugins.internal.Addon import Addon
from pyload.utils import remove_chars
class MultiHoster(Addon):
__name__ = "MultiHoster"
__type__ = "addon"
- __version__ = "0.20"
+ __version__ = "0.20"
__description__ = """Generic MultiHoster plugin"""
__license__ = "GPLv3"
diff --git a/pyload/plugins/base/OCR.py b/pyload/plugins/internal/OCR.py
index c3a47e7ef..b5ee30cb7 100644
--- a/pyload/plugins/base/OCR.py
+++ b/pyload/plugins/internal/OCR.py
@@ -16,7 +16,7 @@ from os.path import abspath, join
class OCR(object):
__name__ = "OCR"
__type__ = "ocr"
- __version__ = "0.1"
+ __version__ = "0.01"
__description__ = """OCR base plugin"""
__license__ = "GPLv3"
diff --git a/pyload/plugins/internal/SimpleCrypter.py b/pyload/plugins/internal/SimpleCrypter.py
index 5f7f89bc2..251acd6b8 100644
--- a/pyload/plugins/internal/SimpleCrypter.py
+++ b/pyload/plugins/internal/SimpleCrypter.py
@@ -4,9 +4,9 @@ import re
from urlparse import urlparse
-from pyload.plugins.Crypter import Crypter
-from module.plugins.Plugin import Fail
-from module.plugins.internal.SimpleHoster import _error, _wait, parseFileInfo, replace_patterns, set_cookies
+from pyload.plugins.internal.Crypter import Crypter
+from pyload.plugins.Plugin import Fail
+from pyload.plugins.internal.SimpleHoster import _error, _wait, parseFileInfo, replace_patterns, set_cookies
from pyload.utils import fixup, html_unescape
diff --git a/pyload/plugins/internal/SimpleHoster.py b/pyload/plugins/internal/SimpleHoster.py
index dd3afdefd..ee8ef712b 100644
--- a/pyload/plugins/internal/SimpleHoster.py
+++ b/pyload/plugins/internal/SimpleHoster.py
@@ -9,8 +9,8 @@ from pycurl import FOLLOWLOCATION
from pyload.network.CookieJar import CookieJar
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Hoster import Hoster
-from module.plugins.Plugin import Fail
+from pyload.plugins.internal.Hoster import Hoster
+from pyload.plugins.Plugin import Fail
from pyload.utils import fixup, html_unescape, parseFileSize
diff --git a/pyload/plugins/internal/UpdateManager.py b/pyload/plugins/internal/UpdateManager.py
index 3f5b34c45..f1312dda5 100644
--- a/pyload/plugins/internal/UpdateManager.py
+++ b/pyload/plugins/internal/UpdateManager.py
@@ -7,7 +7,7 @@ from operator import itemgetter
from os import path, remove, stat
from pyload.network.RequestFactory import getURL
-from pyload.plugins.base.Addon import Expose, Addon, threaded
+from pyload.plugins.internal.Addon import Expose, Addon, threaded
from pyload.utils import safe_join
diff --git a/pyload/plugins/internal/XFSAccount.py b/pyload/plugins/internal/XFSAccount.py
new file mode 100644
index 000000000..0992a8c31
--- /dev/null
+++ b/pyload/plugins/internal/XFSAccount.py
@@ -0,0 +1,122 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from time import gmtime, mktime, strptime
+from urlparse import urljoin
+
+from pyload.plugins.internal.Account import Account
+from pyload.plugins.internal.SimpleHoster import parseHtmlForm, set_cookies
+
+
+class XFSAccount(Account):
+ __name__ = "XFSAccount"
+ __type__ = "account"
+ __version__ = "0.25"
+
+ __description__ = """XFileSharing account plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz"),
+ ("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ HOSTER_DOMAIN = None
+ HOSTER_URL = None
+
+ COOKIES = [(HOSTER_DOMAIN, "lang", "english")]
+
+ PREMIUM_PATTERN = r'\(Premium only\)'
+
+ VALID_UNTIL_PATTERN = r'>Premium.[Aa]ccount expire:.*?(\d{1,2} [\w^_]+ \d{4})'
+
+ TRAFFIC_LEFT_PATTERN = r'>Traffic available today:.*?<b>\s*(?P<S>[\d.,]+|[Uu]nlimited)\s*(?:(?P<U>[\w^_]+)\s*)?</b>'
+ TRAFFIC_LEFT_UNIT = "MB" #: used only if no group <U> was found
+
+ LOGIN_FAIL_PATTERN = r'>(Incorrect Login or Password|Error<)'
+
+
+ def __init__(self, manager, accounts): #@TODO: remove in 0.4.10
+ self.init()
+ return super(XFSAccount, self).__init__(manager, accounts)
+
+
+ def init(self):
+ # if not self.HOSTER_DOMAIN:
+ # self.fail(_("Missing HOSTER_DOMAIN"))
+
+ if not self.HOSTER_URL:
+ self.HOSTER_URL = "http://www.%s/" % self.HOSTER_DOMAIN
+
+
+ def loadAccountInfo(self, user, req):
+ validuntil = None
+ trafficleft = None
+ premium = None
+
+ html = req.load(self.HOSTER_URL, get={'op': "my_account"}, decode=True)
+
+ premium = True if re.search(self.PREMIUM_PATTERN, html) else False
+
+ m = re.search(self.VALID_UNTIL_PATTERN, html)
+ if m:
+ expiredate = m.group(1).strip()
+ self.logDebug("Expire date: " + expiredate)
+
+ try:
+ validuntil = mktime(strptime(expiredate, "%d %B %Y"))
+
+ except Exception, e:
+ self.logError(e)
+
+ else:
+ if validuntil > mktime(gmtime()):
+ premium = True
+ else:
+ premium = False
+ validuntil = None #: registered account type (not premium)
+
+ m = re.search(self.TRAFFIC_LEFT_PATTERN, html)
+ if m:
+ try:
+ traffic = m.groupdict()
+ size = traffic['S']
+
+ if "nlimited" in size:
+ trafficleft = -1
+ if validuntil is None:
+ validuntil = -1
+ else:
+ if 'U' in traffic:
+ unit = traffic['U']
+ elif isinstance(self.TRAFFIC_LEFT_UNIT, basestring):
+ unit = self.TRAFFIC_LEFT_UNIT
+ else:
+ unit = ""
+
+ trafficleft = self.parseTraffic(size + unit)
+
+ except Exception, e:
+ self.logError(e)
+
+ return {'validuntil': validuntil, 'trafficleft': trafficleft, 'premium': premium}
+
+
+ def login(self, user, data, req):
+ if isinstance(self.COOKIES, list):
+ set_cookies(req.cj, self.COOKIES)
+
+ url = urljoin(self.HOSTER_URL, "login.html")
+ html = req.load(url, decode=True)
+
+ action, inputs = parseHtmlForm('name="FL"', html)
+ if not inputs:
+ inputs = {'op': "login",
+ 'redirect': self.HOSTER_URL}
+
+ inputs.update({'login': user,
+ 'password': data['password']})
+
+ html = req.load(self.HOSTER_URL, post=inputs, decode=True)
+
+ if re.search(self.LOGIN_FAIL_PATTERN, html):
+ self.wrongPassword()
diff --git a/pyload/plugins/internal/XFSCrypter.py b/pyload/plugins/internal/XFSCrypter.py
new file mode 100644
index 000000000..2de39f4bc
--- /dev/null
+++ b/pyload/plugins/internal/XFSCrypter.py
@@ -0,0 +1,29 @@
+# -*- coding: utf-8 -*-
+
+from pyload.plugins.internal.SimpleCrypter import SimpleCrypter
+
+
+class XFSCrypter(SimpleCrypter):
+ __name__ = "XFSCrypter"
+ __type__ = "crypter"
+ __version__ = "0.04"
+
+ __pattern__ = r'^unmatchable$'
+
+ __description__ = """XFileSharing decrypter plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ HOSTER_DOMAIN = None
+ HOSTER_NAME = None
+
+ URL_REPLACEMENTS = [(r'&?per_page=\d+', ""), (r'[?/&]+$', ""), (r'(.+/[^?]+)$', r'\1?'), (r'$', r'&per_page=10000')]
+
+ COOKIES = [(HOSTER_DOMAIN, "lang", "english")]
+
+ LINK_PATTERN = r'<(?:td|TD).*?>\s*<a href="(.+?)".*?>.+?(?:</a>)?\s*</(?:td|TD)>'
+ NAME_PATTERN = r'<[tT]itle>.*?\: (?P<N>.+) folder</[tT]itle>'
+
+ OFFLINE_PATTERN = r'>\s*\w+ (Not Found|file (was|has been) removed)'
+ TEMP_OFFLINE_PATTERN = r'>\s*\w+ server (is in )?(maintenance|maintainance)'
diff --git a/pyload/plugins/internal/XFSHoster.py b/pyload/plugins/internal/XFSHoster.py
new file mode 100644
index 000000000..80ddda002
--- /dev/null
+++ b/pyload/plugins/internal/XFSHoster.py
@@ -0,0 +1,345 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from random import random
+from time import sleep
+
+from pycurl import FOLLOWLOCATION, LOW_SPEED_TIME
+
+from pyload.plugins.hoster.UnrestrictLi import secondsToMidnight
+from pyload.plugins.internal.CaptchaService import ReCaptcha, SolveMedia
+from pyload.plugins.internal.SimpleHoster import SimpleHoster, create_getInfo
+from pyload.utils import html_unescape
+
+
+class XFSHoster(SimpleHoster):
+ __name__ = "XFSHoster"
+ __type__ = "hoster"
+ __version__ = "0.15"
+
+ __pattern__ = r'^unmatchable$'
+
+ __description__ = """XFileSharing hoster plugin"""
+ __license__ = "GPLv3"
+ __authors__ = [("zoidberg", "zoidberg@mujmail.cz"),
+ ("stickell", "l.stickell@yahoo.it"),
+ ("Walter Purcaro", "vuolter@gmail.com")]
+
+
+ HOSTER_DOMAIN = None
+ HOSTER_NAME = None
+
+ URL_REPLACEMENTS = [(r'/(?:embed-)?(\w{12}).*', r'/\1')] #: plus support embedded files
+
+ COOKIES = [(HOSTER_DOMAIN, "lang", "english")]
+
+ INFO_PATTERN = r'<tr><td align=right><b>Filename:</b></td><td nowrap>(?P<N>[^<]+)</td></tr>\s*.*?<small>\((?P<S>[^<]+)\)</small>'
+ NAME_PATTERN = r'<input type="hidden" name="fname" value="(?P<N>[^"]+)"'
+ SIZE_PATTERN = r'You have requested .*\((?P<S>[\d.,]+) ?(?P<U>[\w^_]+)?\)</font>'
+
+ OFFLINE_PATTERN = r'>\s*\w+ (Not Found|file (was|has been) removed)'
+ TEMP_OFFLINE_PATTERN = r'>\s*\w+ server (is in )?(maintenance|maintainance)'
+
+ WAIT_PATTERN = r'<span id="countdown_str">.*?>(\d+)</span>'
+
+ OVR_LINK_PATTERN = r'<h2>Download Link</h2>\s*<textarea[^>]*>([^<]+)'
+ LINK_PATTERN = None #: final download url pattern
+
+ CAPTCHA_PATTERN = r'(http://[^"\']+?/captchas?/[^"\']+)'
+ CAPTCHA_DIV_PATTERN = r'>Enter code.*?<div.*?>(.+?)</div>'
+ RECAPTCHA_PATTERN = None
+ SOLVEMEDIA_PATTERN = None
+
+ ERROR_PATTERN = r'(?:class=["\']err["\'][^>]*>|<[Cc]enter><b>)(.+?)(?:["\']|</)|>\(ERROR:(.+?)\)'
+
+
+ def setup(self):
+ self.chunkLimit = 1
+ self.resumeDownload = self.multiDL = self.premium
+
+
+ def prepare(self):
+ """ Initialize important variables """
+ if not self.HOSTER_DOMAIN:
+ self.fail(_("Missing HOSTER_DOMAIN"))
+
+ if not self.HOSTER_NAME:
+ self.HOSTER_NAME = "".join([str.capitalize() for str in self.HOSTER_DOMAIN.split('.')])
+
+ if not self.LINK_PATTERN:
+ pattern = r'(https?://(www\.)?([^/]*?%s|\d+\.\d+\.\d+\.\d+)(\:\d+)?(/d/|(/files)?/\d+/\w+/).+?)["\'<]'
+ self.LINK_PATTERN = pattern % self.HOSTER_DOMAIN.replace('.', '\.')
+
+ self.captcha = None
+ self.errmsg = None
+ self.passwords = self.getPassword().splitlines()
+
+ if (self.__pattern__ != self.core.pluginManager.hosterPlugins[self.__name__]['pattern']
+ and re.match(self.__pattern__, self.pyfile.url) is None):
+ self.logInfo(_("Multi hoster detected"))
+ if self.premium:
+ self.logDebug(_("Looking for download link..."))
+ self.handleOverriden()
+ else:
+ self.fail(_("Only premium users can use url leech feature"))
+
+ return super(XFSHoster, self).prepare()
+
+
+ def handleFree(self):
+ link = self.getDownloadLink()
+
+ if link:
+ if self.captcha:
+ self.correctCaptcha()
+
+ self.download(link, ref=True, cookies=True, disposition=True)
+
+ elif self.errmsg:
+ if 'captcha' in self.errmsg:
+ self.fail(_("No valid captcha code entered"))
+ else:
+ self.fail(self.errmsg)
+
+ else:
+ self.fail(_("Download link not found"))
+
+
+ def handlePremium(self):
+ return self.handleFree()
+
+
+ def getDownloadLink(self):
+ for i in xrange(1, 5):
+ self.logDebug("Getting download link: #%d" % i)
+
+ self.checkErrors()
+
+ m = re.search(self.LINK_PATTERN, self.html, re.S)
+ if m:
+ break
+
+ data = self.getPostParameters()
+
+ # sleep(10)
+
+ self.req.http.c.setopt(FOLLOWLOCATION, 0)
+
+ self.html = self.load(self.pyfile.url, post=data, ref=True, decode=True)
+ self.header = self.req.http.header
+
+ self.req.http.c.setopt(FOLLOWLOCATION, 1)
+
+ m = re.search(r'Location\s*:\s*(.+)', self.header, re.I)
+ if m:
+ break
+
+ m = re.search(self.LINK_PATTERN, self.html, re.S)
+ if m:
+ break
+ else:
+ return
+
+ self.errmsg = None
+
+ return m.group(1).strip() #@TODO: Remove .strip() in 0.4.10
+
+
+ def handleOverriden(self):
+ #only tested with easybytez.com
+ self.html = self.load("http://www.%s/" % self.HOSTER_DOMAIN)
+
+ action, inputs = self.parseHtmlForm('')
+
+ upload_id = "%012d" % int(random() * 10 ** 12)
+ action += upload_id + "&js_on=1&utype=prem&upload_type=url"
+
+ inputs['tos'] = '1'
+ inputs['url_mass'] = self.pyfile.url
+ inputs['up1oad_type'] = 'url'
+
+ self.logDebug(action, inputs)
+
+ self.req.setOption("timeout", 600) #: wait for file to upload to easybytez.com
+
+ self.html = self.load(action, post=inputs)
+
+ self.checkErrors()
+
+ action, inputs = self.parseHtmlForm('F1')
+ if not inputs:
+ if self.errmsg:
+ self.retry(reason=self.errmsg)
+ else:
+ self.error(_("TEXTAREA F1 not found"))
+
+ self.logDebug(inputs)
+
+ stmsg = inputs['st']
+
+ if stmsg == 'OK':
+ self.html = self.load(action, post=inputs)
+
+ elif 'Can not leech file' in stmsg:
+ self.retry(20, 3 * 60, _("Can not leech file"))
+
+ elif 'today' in stmsg:
+ self.retry(wait_time=secondsToMidnight(gmt=2), reason=_("You've used all Leech traffic today"))
+
+ else:
+ self.fail(stmsg)
+
+ #get easybytez.com link for uploaded file
+ m = re.search(self.OVR_LINK_PATTERN, self.html)
+ if m is None:
+ self.error(_("OVR_LINK_PATTERN not found"))
+
+ header = self.load(m.group(1).strip(), just_header=True, decode=True) #@TODO: Remove .strip() in 0.4.10
+ if 'location' in header: #: Direct download link
+ self.download(header['location'], ref=True, cookies=True, disposition=True)
+ else:
+ self.fail(_("Download link not found"))
+
+
+ def checkErrors(self):
+ m = re.search(self.ERROR_PATTERN, self.html)
+
+ if m is None:
+ self.errmsg = None
+ else:
+ self.errmsg = m.group(1)
+
+ self.logWarning(re.sub(r"<.*?>", " ", self.errmsg))
+
+ if 'wait' in self.errmsg:
+ wait_time = sum([int(v) * {"hour": 3600, "minute": 60, "second": 1}[u] for v, u in
+ re.findall(r'(\d+)\s*(hour|minute|second)', self.errmsg)])
+ self.wait(wait_time, True)
+
+ elif 'captcha' in self.errmsg:
+ self.invalidCaptcha()
+
+ elif 'premium' in self.errmsg and 'require' in self.errmsg:
+ self.fail(_("File can be downloaded by premium users only"))
+
+ elif 'limit' in self.errmsg:
+ if 'days' in self.errmsg:
+ delay = secondsToMidnight(gmt=2)
+ retries = 3
+ else:
+ delay = 1 * 60 * 60
+ retries = 25
+
+ self.wait(delay, True)
+ self.retry(retries, reason=_("Download limit exceeded"))
+
+ elif 'countdown' in self.errmsg or 'Expired' in self.errmsg:
+ self.retry(reason=_("Link expired"))
+
+ elif 'maintenance' in self.errmsg or 'maintainance' in self.errmsg:
+ self.tempOffline()
+
+ elif 'download files up to' in self.errmsg:
+ self.fail(_("File too large for free download"))
+
+ else:
+ self.retry(wait_time=60, reason=self.errmsg)
+
+ return self.errmsg
+
+
+ def getPostParameters(self):
+ for _i in xrange(3):
+ if hasattr(self, "FORM_PATTERN"):
+ action, inputs = self.parseHtmlForm(self.FORM_PATTERN)
+ else:
+ action, inputs = self.parseHtmlForm(input_names={"op": re.compile("^download")})
+
+ if not inputs:
+ action, inputs = self.parseHtmlForm('F1')
+ if not inputs:
+ if self.errmsg:
+ self.retry(reason=self.errmsg)
+ else:
+ self.error(_("TEXTAREA F1 not found"))
+
+ self.logDebug(inputs)
+
+ if 'op' in inputs and inputs['op'] in ("download2", "download3"):
+ if "password" in inputs:
+ if self.passwords:
+ inputs['password'] = self.passwords.pop(0)
+ else:
+ self.fail(_("No or invalid passport"))
+
+ if not self.premium:
+ m = re.search(self.WAIT_PATTERN, self.html)
+ if m:
+ wait_time = int(m.group(1))
+ self.setWait(wait_time, False)
+ else:
+ wait_time = 0
+
+ self.captcha = self.handleCaptcha(inputs)
+
+ if wait_time:
+ self.wait()
+
+ return inputs
+ else:
+ inputs['referer'] = self.pyfile.url
+
+ if self.premium:
+ inputs['method_premium'] = "Premium Download"
+ if 'method_free' in inputs:
+ del inputs['method_free']
+ else:
+ inputs['method_free'] = "Free Download"
+ if 'method_premium' in inputs:
+ del inputs['method_premium']
+
+ self.html = self.load(self.pyfile.url, post=inputs, ref=True)
+ else:
+ self.error(_("FORM: %s") % (inputs['op'] if 'op' in inputs else _("UNKNOWN")))
+
+
+ def handleCaptcha(self, inputs):
+ m = re.search(self.CAPTCHA_PATTERN, self.html)
+ if m:
+ captcha_url = m.group(1)
+ inputs['code'] = self.decryptCaptcha(captcha_url)
+ return 1
+
+ m = re.search(self.CAPTCHA_DIV_PATTERN, self.html, re.S)
+ if m:
+ captcha_div = m.group(1)
+ self.logDebug(captcha_div)
+ numerals = re.findall(r'<span.*?padding-left\s*:\s*(\d+).*?>(\d)</span>', html_unescape(captcha_div))
+ inputs['code'] = "".join([a[1] for a in sorted(numerals, key=lambda num: int(num[0]))])
+ self.logDebug("Captcha code: %s" % inputs['code'], numerals)
+ return 2
+
+ recaptcha = ReCaptcha(self)
+ try:
+ captcha_key = re.search(self.RECAPTCHA_PATTERN, self.html).group(1)
+ except:
+ captcha_key = recaptcha.detect_key()
+
+ if captcha_key:
+ self.logDebug("ReCaptcha key: %s" % captcha_key)
+ inputs['recaptcha_challenge_field'], inputs['recaptcha_response_field'] = recaptcha.challenge(captcha_key)
+ return 3
+
+ solvemedia = SolveMedia(self)
+ try:
+ captcha_key = re.search(self.SOLVEMEDIA_PATTERN, self.html).group(1)
+ except:
+ captcha_key = solvemedia.detect_key()
+
+ if captcha_key:
+ self.logDebug("SolveMedia key: %s" % captcha_key)
+ inputs['adcopy_challenge'], inputs['adcopy_response'] = solvemedia.challenge(captcha_key)
+ return 4
+
+ return 0
diff --git a/pyload/plugins/internal/XFSPAccount.py b/pyload/plugins/internal/XFSPAccount.py
deleted file mode 100644
index edf6ad3cc..000000000
--- a/pyload/plugins/internal/XFSPAccount.py
+++ /dev/null
@@ -1,96 +0,0 @@
-# -*- coding: utf-8 -*-
-
-import re
-
-from urlparse import urljoin
-from time import mktime, strptime
-
-from pyload.plugins.base.Account import Account
-from pyload.plugins.internal.SimpleHoster import parseHtmlForm, set_cookies
-from pyload.utils import parseFileSize
-
-
-class XFSPAccount(Account):
- __name__ = "XFSPAccount"
- __type__ = "account"
- __version__ = "0.09"
-
- __description__ = """XFileSharingPro base account plugin"""
- __authors__ = [("zoidberg", "zoidberg@mujmail.cz"),
- ("Walter Purcaro", "vuolter@gmail.com")]
-
-
- HOSTER_URL = None
-
- COOKIES = None #: or list of tuples [(domain, name, value)]
-
- VALID_UNTIL_PATTERN = r'>Premium.[Aa]ccount expire:.*?<b>(.+?)</b>'
- TRAFFIC_LEFT_PATTERN = r'>Traffic available today:.*?<b>(?P<S>.+?)</b>'
- LOGIN_FAIL_PATTERN = r'>(Incorrect Login or Password|Error<)'
- # PREMIUM_PATTERN = r'>Renew premium<'
-
-
- def loadAccountInfo(self, user, req):
- html = req.load(self.HOSTER_URL, get={'op': "my_account"}, decode=True)
-
- validuntil = None
- trafficleft = None
- premium = None
-
- if hasattr(self, "PREMIUM_PATTERN"):
- premium = True if re.search(self.PREMIUM_PATTERN, html) else False
-
- m = re.search(self.VALID_UNTIL_PATTERN, html)
- if m:
- expiredate = m.group(1)
- self.logDebug("Expire date: " + expiredate)
-
- try:
- validuntil = mktime(strptime(expiredate, "%d %B %Y"))
- except Exception, e:
- self.logError(e)
- else:
- if validuntil > mktime(gmtime()):
- premium = True
- trafficleft = -1
- else:
- if premium is False: #: registered account type (not premium)
- validuntil = -1
- premium = False
-
- try:
- traffic = re.search(self.TRAFFIC_LEFT_PATTERN, html).groupdict()
- trafficsize = traffic['S'] + traffic['U'] if 'U' in traffic else traffic['S']
- if "Unlimited" in trafficsize:
- trafficleft = -1
- if premium is None:
- premium = True
- else:
- trafficleft = parseFileSize(trafficsize)
- except:
- pass
-
- if premium is None:
- premium = False
-
- return {'validuntil': validuntil, 'trafficleft': trafficleft, 'premium': premium}
-
-
- def login(self, user, data, req):
- set_cookies(req.cj, self.COOKIES)
-
- url = urljoin(self.HOSTER_URL, "login.html")
- html = req.load(url, decode=True)
-
- action, inputs = parseHtmlForm('name="FL"', html)
- if not inputs:
- inputs = {'op': "login",
- 'redirect': self.HOSTER_URL}
-
- inputs.update({'login': user,
- 'password': data['password']})
-
- html = req.load(self.HOSTER_URL, post=inputs, decode=True)
-
- if re.search(self.LOGIN_FAIL_PATTERN, html):
- self.wrongPassword()
diff --git a/pyload/plugins/ocr/GigasizeCom.py b/pyload/plugins/ocr/GigasizeCom.py
index 01b50be54..e1f6e8753 100644
--- a/pyload/plugins/ocr/GigasizeCom.py
+++ b/pyload/plugins/ocr/GigasizeCom.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.OCR import OCR
+from pyload.plugins.internal.OCR import OCR
class GigasizeCom(OCR):
diff --git a/pyload/plugins/ocr/LinksaveIn.py b/pyload/plugins/ocr/LinksaveIn.py
index 1bde857be..a9171ac7c 100644
--- a/pyload/plugins/ocr/LinksaveIn.py
+++ b/pyload/plugins/ocr/LinksaveIn.py
@@ -9,7 +9,7 @@ from glob import glob
from os import sep
from os.path import abspath, dirname
-from pyload.plugins.base.OCR import OCR
+from pyload.plugins.internal.OCR import OCR
class LinksaveIn(OCR):
diff --git a/pyload/plugins/ocr/NetloadIn.py b/pyload/plugins/ocr/NetloadIn.py
index 86916dd72..79a88c27a 100644
--- a/pyload/plugins/ocr/NetloadIn.py
+++ b/pyload/plugins/ocr/NetloadIn.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.OCR import OCR
+from pyload.plugins.internal.OCR import OCR
class NetloadIn(OCR):
diff --git a/pyload/plugins/ocr/ShareonlineBiz.py b/pyload/plugins/ocr/ShareonlineBiz.py
index 04ffeaf26..5263f8316 100644
--- a/pyload/plugins/ocr/ShareonlineBiz.py
+++ b/pyload/plugins/ocr/ShareonlineBiz.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
-from pyload.plugins.base.OCR import OCR
+from pyload.plugins.internal.OCR import OCR
class ShareonlineBiz(OCR):