summaryrefslogtreecommitdiffstats
path: root/module/plugins/crypter
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-12-09 16:58:35 +0100
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-12-09 16:58:35 +0100
commit4d578cb15f3d6edd036e438e504739b97660f93e (patch)
treeea8fd0a2a62466204feebb046525226f4297c962 /module/plugins/crypter
parentFix __version__ format in some plugins (diff)
downloadpyload-4d578cb15f3d6edd036e438e504739b97660f93e.tar.xz
Spare code cosmetics
Diffstat (limited to 'module/plugins/crypter')
-rw-r--r--module/plugins/crypter/FilecryptCc.py8
-rw-r--r--module/plugins/crypter/NCryptIn.py4
-rw-r--r--module/plugins/crypter/RelinkUs.py25
-rw-r--r--module/plugins/crypter/SafelinkingNet.py2
4 files changed, 24 insertions, 15 deletions
diff --git a/module/plugins/crypter/FilecryptCc.py b/module/plugins/crypter/FilecryptCc.py
index fb53e616b..0aa730744 100644
--- a/module/plugins/crypter/FilecryptCc.py
+++ b/module/plugins/crypter/FilecryptCc.py
@@ -107,10 +107,10 @@ class FilecryptCc(Crypter):
weblinks = re.findall(self.WEBLINK_PATTERN, self.siteWithLinks)
for link in weblinks:
- response = self.load("http://filecrypt.cc/Link/%s.html" % link, cookies=True)
- link2 = re.search('<iframe noresize src="(.*)"></iframe>', response)
- response2 = self.load(link2.group(1), just_header=True, cookies=True)
- self.links.append(response2['location'])
+ res = self.load("http://filecrypt.cc/Link/%s.html" % link, cookies=True)
+ link2 = re.search('<iframe noresize src="(.*)"></iframe>', res)
+ res2 = self.load(link2.group(1), just_header=True, cookies=True)
+ self.links.append(res2['location'])
except Exception, e:
self.logDebug("Error decrypting weblinks: %s" % e)
diff --git a/module/plugins/crypter/NCryptIn.py b/module/plugins/crypter/NCryptIn.py
index 3c08e26c1..1d572e538 100644
--- a/module/plugins/crypter/NCryptIn.py
+++ b/module/plugins/crypter/NCryptIn.py
@@ -156,9 +156,9 @@ class NCryptIn(Crypter):
captcha_key = re.search(r'\?k=(.*?)"', form).group(1)
self.logDebug("Resolving ReCaptcha with key [%s]" % captcha_key)
recaptcha = ReCaptcha(self)
- challenge, code = recaptcha.challenge(captcha_key)
+ challenge, response = recaptcha.challenge(captcha_key)
postData['recaptcha_challenge_field'] = challenge
- postData['recaptcha_response_field'] = code
+ postData['recaptcha_response_field'] = response
# Resolve circlecaptcha
if "circlecaptcha" in form:
diff --git a/module/plugins/crypter/RelinkUs.py b/module/plugins/crypter/RelinkUs.py
index 1111118b2..94a73cded 100644
--- a/module/plugins/crypter/RelinkUs.py
+++ b/module/plugins/crypter/RelinkUs.py
@@ -228,20 +228,29 @@ class RelinkUs(Crypter):
def handleWEBLinks(self):
self.logDebug("Search for WEB links")
+
package_links = []
- fw_params = re.findall(self.WEB_FORWARD_REGEX, self.html)
- self.logDebug("Decrypting %d Web links" % len(fw_params))
- for index, fw_param in enumerate(fw_params):
+ params = re.findall(self.WEB_FORWARD_REGEX, self.html)
+
+ self.logDebug("Decrypting %d Web links" % len(params))
+
+ for index, param in enumerate(params):
try:
- fw_url = self.WEB_FORWARD_URL + "?%s" % fw_param
- self.logDebug("Decrypting Web link %d, %s" % (index + 1, fw_url))
- fw_response = self.load(fw_url, decode=True)
- dl_link = re.search(self.WEB_LINK_REGEX, fw_response).group('link')
- package_links.append(dl_link)
+ url = self.WEB_FORWARD_URL + "?%s" % param
+
+ self.logDebug("Decrypting Web link %d, %s" % (index + 1, url))
+
+ res = self.load(url, decode=True)
+ link = re.search(self.WEB_LINK_REGEX, res).group('link')
+
+ package_links.append(link)
+
except Exception, detail:
self.logDebug("Error decrypting Web link %s, %s" % (index, detail))
+
self.setWait(4)
self.wait()
+
return package_links
diff --git a/module/plugins/crypter/SafelinkingNet.py b/module/plugins/crypter/SafelinkingNet.py
index 9bb6c3229..709083b51 100644
--- a/module/plugins/crypter/SafelinkingNet.py
+++ b/module/plugins/crypter/SafelinkingNet.py
@@ -57,7 +57,7 @@ class SafelinkingNet(Crypter):
challenge, response = captcha.challenge(captchaKey)
postData['adcopy_challenge'] = challenge
- postData['adcopy_response'] = response
+ postData['adcopy_response'] = response
self.html = self.load(url, post=postData)
if "The password you entered was incorrect" in self.html: