They can be used as an effective anti-spambot registering tool. At least for now.
I have used two types of custom profile fields to do this, one is the drop down box, which is easier for your users to use, but also perhaps easier for a spambot to use, as it only has two choices. The second being a typed number.
In both cases the object is to have a default value which does not match the required value to be able to register.
So find the custom profile field page in your Admin Control Panel.

Drop Down Box Method
Here I have used a simple 'are you a spambot' question, with simple yes/no answer.

The settings for the "profile type specific options" are as follows.

Note you are rejecting the default value - so if more than two choices are provided you will have made it easier rather than harder to pass.
Numbers Method
Here I have used a set of 5 numbers, from 1 to 5 (only 3 are visable on the picture).

The settings for the "profile type specific options" are as follows.

Note the use of both the highest & lowest as being equal, and the default as not being the same.
It is not required to use just single numbers, they can be something like 1234, 5367, 8746, 9456, 3426.
So long as the number you have chosen as your required, is also set as the highest & lowest number and not the default it will work.
This will effectively allow you to use a 'code'. If wanting to use as a 'code', do not enter any numbers on the first page as examples (the place where I put the numbers 1 to 5). You would need to provide them with some other method of getting your 'code' to be able to enter, such as an email invite to join with the 'code' or placing it within your forums in an open topic etc.
With this option you could edit the language file which contains the error message returned when they 'fail' so that it does not provide the 'answer'.
To do this edit do the following.
- Code: Select all
#
open langauges/en/ucp.php
#
# repeat for other langauges
#
# Find
#
'FIELD_TOO_SMALL' => 'The value of “%1$s” is too small, a minimum value of %2$d is required.',
'FIELD_TOO_LARGE' => 'The value of “%1$s” is too large, a maximum value of %2$d is allowed.',
#
# Replace with
#
'FIELD_TOO_SMALL' => 'The value of “%1$s” is incorrect',
'FIELD_TOO_LARGE' => 'The value of “%1$s” is incorrect.',
#
# save and close all files
# Remember to clear the cache folder for this to
# take effect.
(my thanks to stevemaury for the code box above)
Result
This is the end result of those two being used together.

Recap
For this to work it is important that all forums use different questions and different answers.
Like all anti-spambot modifications the more they are identical across lots of forums the more the spambot makers will 'code' round that modification.
So make use of your own ideas, using this as a template only, so making yours unique, so making it harder for the spammers to code round it.
Update for ver 3.0.5 and later
Note that there have been some slight changes in version 3.0.5 that slightly change the Visibility settings, but also improve the operation of this technique. See viewtopic.php?p=9778455#p9778455
EDIT by stevemaury 1247322250 UTC -5 w/DST to add 3.0.5 update