sourcesmith / recaptcha4j

Automatically exported from code.google.com/p/recaptcha4j
0 stars 0 forks source link

SimpleHttpLoader fails to set request method to POST in httpPost() method, resulting in response verification to always fail #24

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. use example implementation in a Java servlet
2. try solving a CAPTCHA
3. see it fail, no matter how correct your response

What is the expected output? What do you see instead?
Expected: ReCaptchaImpl verifying user response
Actual: SimpleHttpLoader creating erroneous API request, incurring response 
independent indication of failure

What version of the product are you using? On what operating system?
Current version, Java version 1.7, OS doesn't matter

Please provide any additional information below.
Simply looking at the code in 
https://code.google.com/p/recaptcha4j/source/browse/trunk/recaptcha4j/src/main/j
ava/net/tanesha/recaptcha/http/SimpleHttpLoader.java reveals the problem right 
away: httpPost() should contain a line like this:

connection.setRequestMethod("POST");

Original issue reported on code.google.com by gsaut...@gmail.com on 13 Aug 2015 at 9:34