diff options
author | Christopher <4Christopher@gmx.de> | 2013-03-26 19:23:41 +0100 |
---|---|---|
committer | Christopher <4Christopher@gmx.de> | 2013-03-26 19:23:41 +0100 |
commit | 866d30eb0e6a8868a4f2eb1da3c91734d6b9d716 (patch) | |
tree | 2233ea2329e779761abb5dc8e08afee97973dc61 /module/plugins/internal/CaptchaService.py | |
parent | Movie2kTo: Added setting for quality in the folder name. (diff) | |
parent | Merge pull request #53 from enkore/stable (diff) | |
download | pyload-866d30eb0e6a8868a4f2eb1da3c91734d6b9d716.tar.xz |
Merge branch 'stable' of git://github.com/pyload/pyload into stable
Diffstat (limited to 'module/plugins/internal/CaptchaService.py')
-rw-r--r-- | module/plugins/internal/CaptchaService.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/module/plugins/internal/CaptchaService.py b/module/plugins/internal/CaptchaService.py index f2de00732..b912436a7 100644 --- a/module/plugins/internal/CaptchaService.py +++ b/module/plugins/internal/CaptchaService.py @@ -19,7 +19,7 @@ import re class CaptchaService(): - __version__ = "0.01" + __version__ = "0.02" def __init__(self, plugin): self.plugin = plugin @@ -64,11 +64,9 @@ class SolveMedia(CaptchaService): self.plugin = plugin def challenge(self, src): - html = self.plugin.req.load("http://api.solvemedia.com/papi/challenge.script?k=%s" % src, cookies=True) + html = self.plugin.req.load("http://api.solvemedia.com/papi/challenge.noscript?k=%s" % src, cookies=True) try: - ckey = re.search("ckey:.*?'(.*?)',",html).group(1) - html = self.plugin.req.load("http://api.solvemedia.com/papi/_challenge.js?k=%s" % ckey, cookies=True) - challenge = re.search('"chid".*?: "(.*?)"',html).group(1) + challenge = re.search(r'<input type=hidden name="adcopy_challenge" id="adcopy_challenge" value="([^"]+)">', html).group(1) except: self.plugin.fail("solvmedia error") result = self.result(challenge) |