diff options
author | Nold360 <nold@lavabit.com> | 2013-04-16 10:00:46 +0200 |
---|---|---|
committer | Nold360 <nold@lavabit.com> | 2013-04-16 10:00:46 +0200 |
commit | 36152ba7dec241e9b10cfc01bd2aeb78547cb046 (patch) | |
tree | 571b3db3f8a8171457ec441655376b2e0d47a2b3 /module/plugins/crypter | |
parent | Merge pull request #79 from 4Christopher/stable (diff) | |
download | pyload-36152ba7dec241e9b10cfc01bd2aeb78547cb046.tar.xz |
Added circlecaptcha to NCryptIn-Plugin
Diffstat (limited to 'module/plugins/crypter')
-rw-r--r-- | module/plugins/crypter/NCryptIn.py | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/module/plugins/crypter/NCryptIn.py b/module/plugins/crypter/NCryptIn.py index a8eaac631..996ff581e 100644 --- a/module/plugins/crypter/NCryptIn.py +++ b/module/plugins/crypter/NCryptIn.py @@ -52,6 +52,7 @@ class NCryptIn(Crypter): package_links.extend(self.handleContainers())
package_links.extend(self.handleCNL2())
package_links = set(package_links)
+ self.logDebug(package_links)
# Pack
self.packages = [(package_name, package_links, folder_name)]
@@ -65,7 +66,7 @@ class NCryptIn(Crypter): rexpr = re.compile(pattern, re.DOTALL)
content = re.sub(rexpr, "", content)
return content
-
+
def isOnline(self):
if "Your folder does not exist" in self.cleanedHtml:
self.logDebug("File not found")
@@ -121,6 +122,19 @@ class NCryptIn(Crypter): challenge, code = recaptcha.challenge(id)
postData['recaptcha_challenge_field'] = challenge
postData['recaptcha_response_field'] = code
+
+ # Resolve circlecaptcha
+ if "circlecaptcha" in form:
+ self.captcha = True
+ self.logDebug("Captcha protected")
+ captcha_img_url = "http://ncrypt.in/classes/captcha/circlecaptcha.php"
+ coords = self.decryptCaptcha(captcha_img_url, forceUser=True, imgtype="png", result_type='positional')
+ self.logDebug("Captcha resolved, coords [%s]" % str(coords))
+ self.captcha_post_url = self.pyfile.url
+
+ postData['circle.x'] = coords[0]
+ postData['circle.y'] = coords[1]
+
# Unlock protection
postData['submit_protected'] = 'Continue to folder '
@@ -221,4 +235,4 @@ class NCryptIn(Crypter): # Log and return
self.logDebug("Block has %d links" % len(links))
- return links
\ No newline at end of file + return links
|