From 4a1c1710a4be4d7a66493fe009e16979fa950cb5 Mon Sep 17 00:00:00 2001 From: Anthony Parsons Date: Thu, 30 Mar 2006 01:11:41 +0000 Subject: [PATCH] Made the registration process and TOS more appropriate. --- register.php | 13 +++++++++---- res/tos.xml | 11 +++++++++++ stuff.php | 8 +------- 3 files changed, 21 insertions(+), 11 deletions(-) create mode 100644 res/tos.xml diff --git a/register.php b/register.php index b255217..f96b30f 100644 --- a/register.php +++ b/register.php @@ -26,7 +26,7 @@ if ( isset($_POST['something']) ) { try { // Obvious stuff if ( empty($_POST['reg_u']) || empty($_POST['reg_p']) ) { - throw new LengthException('You left one or more fields empty.'); + throw new InvalidInputException('You left one or more fields empty.'); } if ( $_POST['reg_p'] !== $_POST['reg_c'] ) { throw new InvalidInputException('Both passwords must match exactly.'); @@ -35,7 +35,7 @@ if ( isset($_POST['something']) ) { throw new InvalidInputException('That username is already in use. Try a different name.'); } - // Slows down the more retarded malicious users, which is most of them. + // Faggot protection if ( defined('INVITE_ONLY') && ( !isset($_GET['code']) || !isset($_GET['user']) || 0 == $DB->query('SELECT `userid` FROM `things` WHERE `what` = "invite" @@ -45,6 +45,11 @@ if ( isset($_POST['something']) ) { throw new InvalidInputException('Form data was submitted incorrectly.'); } + // Retard protection + if ( empty($_POST['CYA']) ) { + throw new InvalidInputException('Illiteracy is not a defence.'); + } + // Flood protection if ( $DB->query('SELECT `userid` FROM `users` WHERE `reg_ip` = INET_ATON("'.$_SERVER['REMOTE_ADDR'].'") @@ -149,8 +154,8 @@ if ( defined('INVITE_ONLY') ) { Contact IRI -

Clicking this button implies that you have read and agree to follow the board rules: -

+

+

diff --git a/res/tos.xml b/res/tos.xml new file mode 100644 index 0000000..4efdc33 --- /dev/null +++ b/res/tos.xml @@ -0,0 +1,11 @@ +
+

Board Rules

+
+
Junk Accounts
+
Accounts made with the intention of bypassing access restrictions (lurkers/stalkers) will get removed or locked.
+
General Conduct
+
Retarded behaviour is not tolerated here. Your posting history on other boards will be taken into account. + If you can't follow this rule, go back to whatever site you came from; we don't want or need the likes of you.
+
+

Admins may ban users from the board or site for other reasons if necessary.

+
\ No newline at end of file diff --git a/stuff.php b/stuff.php index 8090a74..6300287 100644 --- a/stuff.php +++ b/stuff.php @@ -109,13 +109,7 @@ echo -

Board Rules

- - pagefooter(); ?> -- 2.11.4.GIT