-
I would add the line :
request.getSession().setAttribute(Captcha.NAME, null);
to the sample code. It will reset the CAPTCHA. Otherwise spammers only have to type in the captcha once and can still automate the process and create for example 1000 accounts or place hundreds of messages on a messageboard
...
2009-09-11 19:11:12 UTC by nobody
-
I work with Websphere v6.1 with Java 1.5.0
When i try the example i alway's get following message, help is much appreciated...
[30/08/09 22:50:49:979 CEST] 0000002f ServletWrappe E SRVE0068E: Uncaught exception thrown in one of the service methods of the servlet: StickyCaptcha. Exception thrown : java.lang.UnsupportedClassVersionError: (nl/captcha/Captcha$Builder) bad major version at...
2009-08-30 20:55:10 UTC by pgoovaerts
-
I'm using Tomcat 6.0.18 (on Windows)
2009-06-06 13:27:03 UTC by nobody
-
Ok, fair enough. What version of Tomcat are you using? I'm using Tomcat 6.0.14 and I do not see this issue.
2009-06-05 17:17:53 UTC by dennis2681
-
"""CaptchaServletUtil.writeImage(resp, captcha.getImage()); """ sends data to the client,
but your web server needs to be aware that you want to send these datas with a jsession id.
The only solution, is to write req.getSession().setAttribute(NAME, captcha); before sending datas.
2009-06-05 17:09:44 UTC by nobody
-
It doesn't work fine...!!!
I tested it with Tomcat v6, and java throwed me an java.lang.IllegalStateException : not possible to create a session after the reponse has been send...
Then I swaped the two lines, as I explained above.
This really makes a difference, because without that, the server doesn't send a JSESSIONID to the client !!!
2009-06-05 17:02:25 UTC by nobody
-
dennis2681 committed revision 30 to the SimpleCaptcha SVN repository, changing 2 files.
2009-06-01 19:05:34 UTC by dennis2681
-
Does this really make any difference? I tested the current code and it seems to work fine unless I'm missing something...
2009-06-01 18:59:55 UTC by dennis2681
-
dennis2681 committed revision 29 to the SimpleCaptcha SVN repository, changing 1 files.
2009-05-29 19:45:48 UTC by dennis2681
-
dennis2681 committed revision 28 to the SimpleCaptcha SVN repository, changing 1 files.
2009-05-29 19:33:58 UTC by dennis2681