diff options
author | Yorhel <git@yorhel.nl> | 2011-08-23 15:52:09 +0200 |
---|---|---|
committer | Yorhel <git@yorhel.nl> | 2011-08-23 15:52:09 +0200 |
commit | 49a1cb08f10f69f517f261ad9c34304e4979cefb (patch) | |
tree | e71c2e8ffbeca875ad04e6a96a5c4bd16960d765 /util | |
parent | 18c681f059389646d0b48b305ccf5e7622cb47e4 (diff) |
Added email confirmation to registration process
Diffstat (limited to 'util')
-rw-r--r-- | util/sql/schema.sql | 3 | ||||
-rw-r--r-- | util/updates/update_2.21.sql | 9 |
2 files changed, 11 insertions, 1 deletions
diff --git a/util/sql/schema.sql b/util/sql/schema.sql index 6cbd2b14..40af8975 100644 --- a/util/sql/schema.sql +++ b/util/sql/schema.sql @@ -365,7 +365,8 @@ CREATE TABLE users ( ip inet NOT NULL DEFAULT '0.0.0.0', c_tags integer NOT NULL DEFAULT 0, salt character(9) NOT NULL DEFAULT '', - ign_votes boolean NOT NULL DEFAULT FALSE + ign_votes boolean NOT NULL DEFAULT FALSE, + email_confirmed boolean NOT NULL DEFAULT FALSE ); -- users_prefs diff --git a/util/updates/update_2.21.sql b/util/updates/update_2.21.sql index d90a510d..30ddac60 100644 --- a/util/updates/update_2.21.sql +++ b/util/updates/update_2.21.sql @@ -6,3 +6,12 @@ UPDATE releases_rev SET resolution = resolution + 1 WHERE resolution >= 5; -- Old MD5 passwords can't be used anymore, so delete them UPDATE users SET passwd = '' WHERE salt = ''; + +-- Email addresses now have to be confirmed upon registration +-- This boolean column won't really checked on login, it's just here for +-- administration purposes. The passwd/salt columns contain a +-- password-reset-token, so the user won't be able to login directly after +-- registration anyway. +ALTER TABLE users ADD COLUMN email_confirmed boolean NOT NULL DEFAULT FALSE; +UPDATE users SET email_confirmed = TRUE; + |