Any suggestions for configuring Engage with captcha. I want a captcha to prevent bot sign ups, but Engage logins fail when it is enabled on the login form.

Any suggestions are appreciated.

Comments

geokat’s picture

What captcha module are you using?

kreynen’s picture

I'm currently using captcha with recaptcha, but I'm willing to change the captcha module.

BenK’s picture

We also should support the Mollom module (http://drupal.org/project/mollom) as it is really popular in the Drupal community for implementing captchas. If this is indeed a problem we definitely need to fix this. I'll need to test to see if I can reproduce the problem.

--Ben

BenK’s picture

Title: Sugestions for configuring Engage with captcha? » Integrating Janrain Engage with Captcha and Mollom

I tried this out with Mollom and the issue becomes that the Mollom word verification always fails the first time around because the Mollom captcha obviously isn't a part of the Janrain Engage widget. As a result, the following error is displayed:

Word verification field is required.

The question is whether there is some way to programmatically bypass the Mollom word verification if the user is authenticating with Janrain Engage (and is obviously verifying their legitimate identity by doing so).

--Ben

geokat’s picture

Category: support » task

I think there is a way.

BenK’s picture

Hey George,

Yes, it turns out there is a fairly straightforward way to solve the Mollom issue. Check out this thread for details:

http://drupal.org/node/1150516

--Ben

geokat’s picture

Thanks, Ben!

Still need to investigate for other popular captcha modules out there.

Cheers,
George

kreynen’s picture

@geokat... I don't think anyone is questioning whether it's possible. I was asking for recommendations on the approach so that the time I spend writing a patch has a better chance of getting committed.

I think the easiest way to accomplish this is to override the #validate functions with duplicate functions that check for rpx data. I there is no rpx data, call the original function. This is going to be easier with Mollom than Captcha since Mollom only has a single set of functions...

$form['#validate'][] = 'mollom_validate_analysis';
$form['#validate'][] = 'mollom_validate_captcha';
$form['#validate'][] = 'mollom_validate_post';

Captcha loads a function from each type of captcha in most cases...

// Get CAPTCHA validate function or fall back on strict equality.
$captcha_validate = $element['#captcha_validate'];
if (!function_exists($captcha_validate)) {
  $captcha_validate = 'captcha_validate_strict_equality';
}

Even though Captcha is a bit more complicated, it's 4x as popular as Mollom (96K/27K sites). If everyone agrees that creating custom validation functions that process the original validation when users loggin without rpx data, does it make sense to write this as a separate module in a separate project since it could need to be updated as often as the captcha modules update?

kreynen’s picture

I really need this now, so I'm going to move forward with a separate module to override the form validation. The approach sun suggested in #1150516: Bypassing Mollom checks programmatically leads to PHP notices for Mollom is similar, but since Captcha lacks that form_state setting I'm going to use an approach that will work for both.

BenK’s picture

@kreynen: Sounds good. When you've got a project page up, post a link on this issue and we'll take a look. Do you plan to just support Captcha or do a more abstracted approach that also support Mollom?

--ben

geokat’s picture

Added support for Captcha (and sub-modules) and Mollom in 7.x-2.x. If
somebody's going to test this: user registration form is the only form
involved in this integration.

Thanks,
George

geokat’s picture

Version: 7.x-2.0 » 7.x-2.x-dev
geokat’s picture

Added in 6.x-2.x as well.

BenK’s picture

Status: Active » Fixed

I've tested both the Mollom and Captcha module integrations in D7 and this is working great... no problems at all. Nice work, George. Marking this as fixed!

--Ben

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

eidolon night’s picture

Status: Closed (fixed) » Active

I'm actually still having issues with the Captcha module (with ReCaptcha) and Janrain (both the stable and latest dev). I get shot over to the registration page with the error "The answer you entered for the CAPTCHA was not correct."

mkrkarthi’s picture

Version: 7.x-2.x-dev » 7.x-2.0

I am using Captcha module.
Users logged in using Janrain Engage are asked to enter the correct Captcha.
Could not bypass Captcha verification, Again the registration form displayed, which leads to edit other fields such as email etc.,
How to rectify this problem?

geokat’s picture

This could be some change in the latest version of Captcha breaking the integration.

Marcus 78’s picture

Version: 7.x-2.0 » 7.x-2.2

Just posting to say that this problem still exists on 2.2. I´ve only got captcha on registration but it asks for correct reply on login.

ktrev’s picture

I didn't see the option to bypass captcha.Is this a front end setting.Right now after login I am getting the error "invalid captcha"
I am using janrain version 7.x-2.4 and captcha version 7.x-1.0-beta2 and recaptcha version 7.x-1.9