473,385 Members | 1,973 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

CAPTCHA and multiple users problem ?

In CAPTCHA, one starts a session, name it, and keep the verification
code as this:

$_SESSION['ecp_sess'] = $veristr;

When an end-user clicks SUBMIT, the server script will verify the code
as this:

if($_SESSION["ecp_sess"] == $_POST["veri_code"]) ....

Somehow I think this is going to create problem. The verification code
is dynamically generated, but the session name is unchanged. When
there are more than 1 users at a particular time, the earlier user who
clicks SUBMIT will find that the verification code is incorrect.

I am going to test with 2 computers; in the mean time any comments
from experienced people ?

Thanks.
Oct 22 '08 #1
1 1462
On Wed, 22 Oct 2008 10:55:24 +0200, <sb****@yahoo.comwrote:
In CAPTCHA, one starts a session, name it, and keep the verification
code as this:

$_SESSION['ecp_sess'] = $veristr;

When an end-user clicks SUBMIT, the server script will verify the code
as this:

if($_SESSION["ecp_sess"] == $_POST["veri_code"]) ....

Somehow I think this is going to create problem. The verification code
is dynamically generated, but the session name is unchanged. When
there are more than 1 users at a particular time, the earlier user who
clicks SUBMIT will find that the verification code is incorrect.

I am going to test with 2 computers; in the mean time any comments
from experienced people ?
1) As long they don't share a session (and you probably don't want that
anyway) $_SESSION["ecp_sess"] wil hold different values for different
users.
2) If you keep your served captcha image depends on the actual value of
$_SESSION["ecp_sess"], and is not a single image that gets overwritten
again and again (the horror!), things should be fine.
--
Rik Wasmus
Oct 22 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Krishna Kumar | last post by:
Hai all, I am doing a project in .net and in that project I have a problem in capturing text from an image. i.e images like CAPTCHA images . which has inbuilt text with in the image.So,...
12
by: Francois Bonzon | last post by:
After a Google search, I see that quite a few CAPTCHA implementations in PHP are available. I'd like one that's not (easily) OCR-able, or otherwise crackable. Open source or commercial is not...
2
by: Varangian | last post by:
Hi all, wanted to ask about Captcha image! When should I used it? When there is free text box to be filled? Should I use a Captcha when I have a page with only click buttons? Can a bot "click a...
4
by: xeiter | last post by:
Hi, I have a captcha script on my website located at /captcha.php. What it does it generates an image with the code, displays the image (gd2) and saves the value of the code in session. How do I...
2
by: ad | last post by:
I use form authentication mode to verify users like: <authentication mode="Forms"> <forms name="MyCookie" loginUrl="Login.aspx" defaultUrl="Home.aspx" protection="Validation"> and I want to...
7
by: =?Utf-8?B?bWF0dCBw?= | last post by:
Steve Orr has a neat Captcha control: http://steveorr.net/articles/CAPTCHASP.aspx but aside from "dragging the control onto your toolbox.." Does anyone have any installation instructions: e.g....
7
by: Joel Fireman | last post by:
I'm looking at the results of searching for "captcha" and "php" - there's a couple hundred of hits that seem to be uniquish... Before I start flogging them, I thought I'd ask the good folks here...
15
by: sb5309 | last post by:
When one uses CAPTCHA (form with verification code), a session is required to keep the session data. In examples that I have seen on the net, I did not see a session is closed after use. ...
10
by: jeddiki | last post by:
Hi, I have a captcha script which should pick up a background image and add some random letters to it and re-display This is the part of the form that the captcha image is part of: <span...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.