PHP Classes

Object CAPTCHA: Perform CAPTCHA validation using object images

Recommend this page to a friend!
  Info   Screenshots   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 320 All time: 7,230 This week: 206Up
Version License PHP version Categories
object-captcha 1.0BSD License5PHP 5, Graphics, Validation
Description 

Author

This class can be used to perform CAPTCHA validation using object images.

It can scan a given directory with object images in JPEG format and pick one randomly to display to the user.

The user must enter the object name that is taken from the object image file name and stored in a MySQL database for posterior validation.

Picture of wooptoo
Name: wooptoo <contact>
Classes: 2 packages by
Country: Romania Romania
Age: ???
All time rank: 131734 in Romania Romania
Week rank: 180 Up4 in Romania Romania Up

Details

README ------ We must connect to a db for this to work ======================================== 1. create a database 2. import objectcaptcha.sql in it 3. set your credentials in db.php ObjectCaptcha works in two steps ================================ * First (in index.php) an image is grabbed, the answer saved to the db, then the registration form displayed. * Second (in register.php) the answer from the db is compared to the input from the form. Some notes on ObjectCaptcha =========================== * A random jpg image will be displayed each time (and its answer saved to the db). * The answer to an image is the image's filename. * Multiple answers can be given for an image. They have to be separated with underscores in the image's filename. For example, for: boot_shoe.jpg the answer can be either 'boot' or 'shoe' * ObjectCaptcha needs a db to temporarily store answers, because it would be unsafe to store them in cookies. * Images are encoded in base64 format and displayed like that, so their original filename cannot be retrieved. * Random garbage is added to the end of an image (JPEG allows this) to protect against hash attacks on the image. * I originally created ObjectCaptcha as a mod for SMF forum. This is a more generic relase that can be used with other systems. Files ===== These are example files, not needed on a production site: db.php index.php register.php readme.txt screenshot.png objectcaptcha.sql is needed only for installation. Any .jpg file placed in the directory will be used by the Captcha.

Screenshots (1)  
  • screenshot.png
  Files folder image Files (11)  
File Role Description
Image file bird.jpg Data image1
Image file book.jpg Data image2
Image file boot_shoe.jpg Data image3
Image file box.jpg Data image4
Plain text file class.objectcaptcha.php Class ObjectCaptcha class
Plain text file db.php Example db config
Plain text file index.php Example example main page
Plain text file objectcaptcha.sql Data db schema
Plain text file readme.txt Doc. readme
Plain text file register.php Example example second page

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:320
This week:0
All time:7,230
This week:206Up