Archive for the ‘phpBB2’ Category.

Improve Visual Confirmation Security

In a previous update for phpBB 2, they added visual confirmation to the registration page. However, bots have started to get past this so I have devised a very simple solution that just makes it a little more difficult for them.

What this mod will do is change the length of the visual confirmation image to 8 characters, but will also remove some HTML that may give bots pointers to how long your image should be.

Open:
includes/usercp_register.php
Find:
$code = substr(str_replace('0', 'Z', strtoupper(base_convert($code, 16, 35))), 2, 6);
Find in-line:
6);
Replace With:
8);
Open:
templates/subSilver/profile_add_body.tpl
Find:
<td class="row2"><input type="text" class="post" style="width: 200px" name="confirm_code" size="6" maxlength="6" value="" /></td>
Find in-line:
size="6" maxlength="6" value=""
Replace With:
value=""
SQL:
ALTER TABLE `test_confirm` CHANGE `code` `code` CHAR( 8 ) NOT NULL;
And its as simple as that. This one change I made on several boards I maintain had the result of going fromĀ 10 or more different kinds of bots to no bots registering at all and have had no more since.