Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: vbgamer45 on April 14, 2020, 11:12:56 AM

Title: hCaptcha for SMF
Post by: vbgamer45 on April 14, 2020, 11:12:56 AM
[Link to the mod](https://custom.simplemachines.org/index.php?mod=4255)

hCaptcha for SMF
=================

About
-----
hCaptcha is degined to keep out bots, protects user privacy and rewards website owners.

This modification allows you to use [hCaptcha](https://www.hcaptcha.com/)
instead of the built-in Visual Verification system. It supports the SMF
2.0.x and 2.1.x series.



Features
--------
 - Use hCaptcha on your forum in place of or in combination with the
   built-in verification options.
 - Support for built-in hCaptcha themes


How to Use
----------
You can enable hCaptcha by going to:

Admin -> Configuration -> Security and Moderation -> Anti-Spam

A set of keys are required for operation of hCaptcha A link is
provided in the settings to register for a key pair.



Known Issues
------------
 - The error messages are the built-in ones, so they will talk about
   letters not being filled in or matching.


License
-------
This code is licensed under the terms of the BSD 3-Clause License. SMF
code used in this mod is copyright Simple Machines.

Portions code is copyright Michael Johnson (motokochan) based on reCAPTCHA for SMF https://custom.simplemachines.org/mods/index.php?mod=1044



Acknowledgements
----------------
"SMF" and "Simple Machines" are trademarks of Simple Machines.


Version History
---------------
See CHANGELOG



Title: Re: hCaptcha for SMF
Post by: Shambles on April 14, 2020, 12:06:07 PM
Hmm... not sure I like the sound of this.

QuoteWhen you use hCaptcha, companies bid on the work your users do as they prove their humanity.

Sounds like you'll be helping to train bots  ???  Change my mind.
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on April 14, 2020, 12:33:11 PM
It's the same thing reCaptcha. The ocr technology,photos people are the labor for free.
Title: Re: hCaptcha for SMF
Post by: -Rock Lee- on April 14, 2020, 01:46:19 PM
It seems interesting it would be a matter of proving that works, great job @vbgamer45!


Regards!
Title: Re: hCaptcha for SMF
Post by: shadav on April 27, 2020, 10:29:15 AM
well....
I was going to try this, as I can not use smf's built in captcha, nor recapthca
(I don't have a clue what messed those up...too many mods)

but.....
when I go to try and sign up for keys....
it seems it's not working on their site  :o
everytime I click submit get error of please complete the form
oopssss
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on April 27, 2020, 10:31:29 AM
Strange. Do you have a different email than normal? If not I would contact them on contact us.
Title: Re: hCaptcha for SMF
Post by: shadav on April 27, 2020, 10:36:30 AM
nope, was using yahoo....
i sent them an email to their support...
hopefully they fix it
Title: Re: hCaptcha for SMF
Post by: Arantor on April 27, 2020, 11:17:34 AM
Yahoo is a truly horrible provider to get email to.
Title: Re: hCaptcha for SMF
Post by: shadav on April 28, 2020, 01:06:06 AM
Quote from: Arantor on April 27, 2020, 11:17:34 AM
Yahoo is a truly horrible provider to get email to.
:laugh: yeah well....been using it for 20 some odd years....stuck with it til it dies  :laugh:
Title: Re: hCaptcha for SMF
Post by: SilverKnight on December 04, 2020, 09:50:02 PM
Thank you for this mod, this should be added to SMF in general these days, built in captcha is useless against today's A.I.
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on September 06, 2021, 09:11:55 PM
Update!

Version 2.0
+Adds support for SMF 2.1!
!Fixed bug in SMF 2.0.x with questions and answers.
Title: Re: hCaptcha for SMF
Post by: Shades. on December 10, 2021, 10:21:33 AM
Just installed on 2.0.18 and cant get the built in image verification to work with this. All that shows is ":" under the hcaptcha.

Image below shows the contact page mod but it does the same on the registration page too.
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on December 10, 2021, 10:26:03 AM
Do you have any questions and answers? for verification?
What do you have on the settings for registration
Title: Re: hCaptcha for SMF
Post by: Shades. on December 10, 2021, 10:38:42 AM
Quote from: vbgamer45 on December 10, 2021, 10:26:03 AMDo you have any questions and answers? for verification?
What do you have on the settings for registration
No questions & answers was just trying to use the built in image verification with hcaptcha too.

Here is my registration settings and Anti-Spam settings:
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on December 10, 2021, 10:46:24 AM
Try changing the visual verifaction option to none and see if it helps
Title: Re: hCaptcha for SMF
Post by: Shades. on December 10, 2021, 10:50:24 AM
Yes I have done that and the ":" disappears but my question is, why won't they work together (with both checked as on)? Or was it intended to work with both on or just one or the other? ???  O:)

Just asking cause it says "hCaptcha settings are below. If you don't want the built-in image verification, you must set it to none." So that's telling me I can use both at same time optionally. ;)

Also I just now tested and it works with the questions but not with the verification image. ;)
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on December 10, 2021, 11:10:37 AM
This mod should be one or the other basically hcaptcha replaces image verification option
Title: Re: hCaptcha for SMF
Post by: Shades. on December 10, 2021, 11:36:09 AM
I just installed a fresh copy of 2.0.18 with no mods except this one and still not working properly. I see the following errors in admin:

QuoteGuest
Type of error: Undefined
https://*****.com/index.php?action=registerApply
8: Undefined offset: 1
File: /home2/*****/public_html/*****/Themes/default/GenericControls.template.php (registration_form sub template - eval?)
Line: 353

Also Line 352 same error message

On the registration page it shows the hcaptcha, the question & answer box, and a ":" with a box under it but no image verification.
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on December 10, 2021, 12:20:59 PM
And image verification is set to none?
Title: Re: hCaptcha for SMF
Post by: Shades. on December 10, 2021, 01:05:59 PM
No all are turned on...it works with the image verification off but I thought its all supposed to work on together?
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on December 10, 2021, 01:31:25 PM
It is either one or the other. basiclly the same as the recaptcha mod i used that as the base
Title: Re: hCaptcha for SMF
Post by: Shades. on December 11, 2021, 12:35:03 AM
Quote from: Shades. on December 10, 2021, 10:50:24 AMJust asking cause it says "hCaptcha settings are below. If you don't want the built-in image verification, you must set it to none." So that's telling me I can use both at same time optionally. ;)
Ok sorry about that, I misunderstood lol! ;D

But as a suggestion this part here might need to be changed to "hCaptcha settings are below. You Must turn off the built-in image verification by setting it to "None" in order to use hCaptcha."

Or something like that lol! ;)  ;D

Just my two senses worth :laugh:  O:)
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on February 18, 2022, 07:08:59 PM
Update

Version 2.1
!Updated to new javascript url for the api
Title: Re: hCaptcha for SMF
Post by: Shades. on February 18, 2022, 07:33:06 PM
Quote from: vbgamer45 on April 14, 2020, 11:12:56 AM[url="https://custom.simplemachines.org/index.php?mod=4255"]Link to the mod[/url]
hCaptcha for SMF
Your link to the mod is messed up on first page https://www.simplemachines.org/community/index.php?topic=572713.msg4051935#msg4051935 ;)
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on February 18, 2022, 07:46:26 PM
Strange fixed just reedited the mod page.
Title: Re: hCaptcha for SMF
Post by: Diego Andrés on February 18, 2022, 08:02:23 PM
It's a known bug, it's logged internally  :)
Title: Re: hCaptcha for SMF
Post by: Butiks on June 19, 2023, 09:09:44 PM
Great mod!
Thanks vbgamer45

Please add the necessary functions of the captcha, enable it so that it can be optionally on separate pages:
../index.php?action=login (authorization popup window too)
../index.php?action=reminder - restore account access
../index.php?action=admin - adminpanel
../index.php?action=signup - registration
../index.php?action=search - standard search
../index.php?action=search2 - search from the top search form
../index.php?action=mlist - list of users
../index.php?action=post; - creating a topic on the forum and sending posts in topics
/index.php?action=pm;sa=send - page for sending private message
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on June 19, 2023, 11:33:10 PM
It should on any page that the standard SMF captcha is used.
Title: Re: hCaptcha for SMF
Post by: hatmak on July 28, 2023, 04:15:43 PM
I installed this mod but the recaptcha looks the same, it didn't change and I got the error message shown below.


C:/..../Themes/default/GenericControls.template.php (Line 221)
Backtrace information

Type of error: Undefined
Error message Select
2: Undefined array key "can_hcaptcha"

What can i do?
Title: Re: hCaptcha for SMF
Post by: vbgamer45 on July 28, 2023, 04:32:52 PM
Disable recaptcha or remove that mod it's either one or the other.