Merge pull request #120 from mamarley/dbcreatefix
authorManuel Nickschas <sputnick@quassel-irc.org>
Thu, 9 Apr 2015 11:53:29 +0000 (13:53 +0200)
committerManuel Nickschas <sputnick@quassel-irc.org>
Thu, 9 Apr 2015 11:53:29 +0000 (13:53 +0200)
Update the schema creation DDL for the new password hashing

src/core/SQL/PostgreSQL/17/setup_000_quasseluser.sql
src/core/SQL/SQLite/18/setup_000_quasseluser.sql

index cd8292c..9c99376 100644 (file)
@@ -1,5 +1,6 @@
 CREATE TABLE quasseluser (
        userid serial NOT NULL PRIMARY KEY,
        username varchar(64) UNIQUE NOT NULL,
-       password char(40) NOT NULL -- hex reppresentation of sha1 hashes
+       password TEXT NOT NULL,
+       hashversion integer NOT NULL DEFAULT 0
 )
index 0b81759..1833f96 100644 (file)
@@ -1,7 +1,6 @@
 CREATE TABLE quasseluser (
        userid INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
        username TEXT UNIQUE NOT NULL,
-       password TEXT NOT NULL
+       password TEXT NOT NULL,
+       hashversion INTEGER NOT NULL DEFAULT 0
 )
-
-