From 35fa61dbba3ba374ec441de6deca8ee62ff66b42 Mon Sep 17 00:00:00 2001 From: Stefano Date: Mon, 25 Nov 2013 18:41:08 +0100 Subject: FshareVn: updated account plugin --- module/plugins/accounts/FshareVn.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'module/plugins/accounts') diff --git a/module/plugins/accounts/FshareVn.py b/module/plugins/accounts/FshareVn.py index 75191e74a..11abfa463 100644 --- a/module/plugins/accounts/FshareVn.py +++ b/module/plugins/accounts/FshareVn.py @@ -26,13 +26,13 @@ from module.plugins.Account import Account class FshareVn(Account): __name__ = "FshareVn" - __version__ = "0.04" + __version__ = "0.05" __type__ = "account" __description__ = """fshare.vn account plugin""" - __author_name__ = ("zoidberg") - __author_mail__ = ("zoidberg@mujmail.cz") + __author_name__ = ("zoidberg", "stickell") + __author_mail__ = ("zoidberg@mujmail.cz", "l.stickell@yahoo.it") - VALID_UNTIL_PATTERN = ur'
Thời hạn dùng:
\s*
([^<]+)
' + VALID_UNTIL_PATTERN = ur'
Lần đăng nhập trước:
\s*
([^<]+)
' TRAFFIC_LEFT_PATTERN = ur'
Tổng Dung Lượng Tài Khoản
\s*]*>([0-9.]+) ([kKMG])B' DIRECT_DOWNLOAD_PATTERN = ur']*)[^>]*/>Kích hoạt download trực tiếp' @@ -41,7 +41,7 @@ class FshareVn(Account): found = re.search(self.VALID_UNTIL_PATTERN, html) if found: premium = True - validuntil = mktime(strptime(found.group(1), '%I:%M:%S %p %d-%m-%Y')) + validuntil = mktime(strptime(found.group(1), '%d-%m-%Y')) found = re.search(self.TRAFFIC_LEFT_PATTERN, html) trafficleft = float(found.group(1)) * 1024 ** { 'k': 0, 'K': 0, 'M': 1, 'G': 2}[found.group(2)] if found else 0 -- cgit v1.2.3 From a1cdc2d29776a2f98388cce647962cd01faa5822 Mon Sep 17 00:00:00 2001 From: Stefano Date: Tue, 26 Nov 2013 16:39:35 +0100 Subject: FilefactoryCom: fixed premium login. See #366 --- module/plugins/accounts/FilefactoryCom.py | 57 ++++++++++++++++--------------- 1 file changed, 30 insertions(+), 27 deletions(-) (limited to 'module/plugins/accounts') diff --git a/module/plugins/accounts/FilefactoryCom.py b/module/plugins/accounts/FilefactoryCom.py index 679409058..04ba0ea86 100644 --- a/module/plugins/accounts/FilefactoryCom.py +++ b/module/plugins/accounts/FilefactoryCom.py @@ -1,45 +1,46 @@ # -*- coding: utf-8 -*- -""" - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, - or (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - See the GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, see . - - @author: zoidberg -""" +############################################################################ +# This program is free software: you can redistribute it and/or modify # +# it under the terms of the GNU Affero General Public License as # +# published by the Free Software Foundation, either version 3 of the # +# License, or (at your option) any later version. # +# # +# This program is distributed in the hope that it will be useful, # +# but WITHOUT ANY WARRANTY; without even the implied warranty of # +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +# GNU Affero General Public License for more details. # +# # +# You should have received a copy of the GNU Affero General Public License # +# along with this program. If not, see . # +############################################################################ import re from time import mktime, strptime +from pycurl import REFERER + from module.plugins.Account import Account class FilefactoryCom(Account): __name__ = "FilefactoryCom" - __version__ = "0.13" + __version__ = "0.14" __type__ = "account" __description__ = """filefactory.com account plugin""" __author_name__ = ("zoidberg", "stickell") __author_mail__ = ("zoidberg@mujmail.cz", "l.stickell@yahoo.it") - ACCOUNT_INFO_PATTERN = r'