diff options
author | Craig Andrews <candrews@integralblue.com> | 2009-11-02 18:40:18 -0500 |
---|---|---|
committer | Craig Andrews <candrews@integralblue.com> | 2009-11-02 18:40:49 -0500 |
commit | b9d40f723bce8e01ddcbbb989bd7035b92cd9af8 (patch) | |
tree | a995cf45dbd3d913ba31bd097a5f14cf72a8c095 /db | |
parent | a2b830392597d88c435baf54ad0df4ecda02dc41 (diff) |
Added 'login' command that gives you a link that can be used to login to the website
Diffstat (limited to 'db')
-rw-r--r-- | db/08to09.sql | 10 | ||||
-rw-r--r-- | db/08to09_pg.sql | 10 | ||||
-rw-r--r-- | db/statusnet.sql | 10 | ||||
-rw-r--r-- | db/statusnet_pg.sql | 10 |
4 files changed, 40 insertions, 0 deletions
diff --git a/db/08to09.sql b/db/08to09.sql index 953e0e5f4..a0e37f0f1 100644 --- a/db/08to09.sql +++ b/db/08to09.sql @@ -32,3 +32,13 @@ create table user_role ( constraint primary key (user_id, role) ) ENGINE=InnoDB CHARACTER SET utf8 COLLATE utf8_bin; + +create table login_token ( + user_id integer not null comment 'user owning this token' references user (id), + token char(32) not null comment 'token useable for logging in', + created datetime not null comment 'date this record was created', + modified timestamp comment 'date this record was modified', + + constraint primary key (user_id) +) ENGINE=InnoDB CHARACTER SET utf8 COLLATE utf8_bin; + diff --git a/db/08to09_pg.sql b/db/08to09_pg.sql index 9e37314aa..197fcabfd 100644 --- a/db/08to09_pg.sql +++ b/db/08to09_pg.sql @@ -38,3 +38,13 @@ create table user_role ( primary key (user_id, role) ); + +create table login_token ( + user_id integer not null /* comment 'user owning this token'*/ references user (id), + token char(32) not null /* comment 'token useable for logging in'*/, + created timestamp not null DEFAULT CURRENT_TIMESTAMP /* comment 'date this record was created'*/, + modified timestamp /* comment 'date this record was modified'*/, + + constraint primary key (user_id) +); + diff --git a/db/statusnet.sql b/db/statusnet.sql index 1524d8395..3ed4e2c48 100644 --- a/db/statusnet.sql +++ b/db/statusnet.sql @@ -575,3 +575,13 @@ create table location_namespace ( modified timestamp comment 'date this record was modified' ) ENGINE=InnoDB CHARACTER SET utf8 COLLATE utf8_bin; + +create table login_token ( + user_id integer not null comment 'user owning this token' references user (id), + token char(32) not null comment 'token useable for logging in', + created datetime not null comment 'date this record was created', + modified timestamp comment 'date this record was modified', + + constraint primary key (user_id) +) ENGINE=InnoDB CHARACTER SET utf8 COLLATE utf8_bin; + diff --git a/db/statusnet_pg.sql b/db/statusnet_pg.sql index 672877ddf..0e5e96c32 100644 --- a/db/statusnet_pg.sql +++ b/db/statusnet_pg.sql @@ -569,3 +569,13 @@ create table user_role ( primary key (user_id, role) ); + +create table login_token ( + user_id integer not null /* comment 'user owning this token'*/ references user (id), + token char(32) not null /* comment 'token useable for logging in'*/, + created timestamp not null DEFAULT CURRENT_TIMESTAMP /* comment 'date this record was created'*/, + modified timestamp /* comment 'date this record was modified'*/, + + constraint primary key (user_id) +); + |