summaryrefslogtreecommitdiff
path: root/app/Schema/Postgres.php
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2015-03-31 22:48:14 -0400
committerFrederic Guillot <fred@kanboard.net>2015-03-31 22:48:14 -0400
commitabeeba71672a711dab98194bb8ae751ee95e3385 (patch)
tree26838682b1ab13611b9697d1b8900122409dbf47 /app/Schema/Postgres.php
parent5d393ed9962ebe18a162cb09b08eaea9359df2cc (diff)
Add two factor authentication
Diffstat (limited to 'app/Schema/Postgres.php')
-rw-r--r--app/Schema/Postgres.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/app/Schema/Postgres.php b/app/Schema/Postgres.php
index 93d8e869..6c6ea001 100644
--- a/app/Schema/Postgres.php
+++ b/app/Schema/Postgres.php
@@ -6,7 +6,13 @@ use PDO;
use Core\Security;
use Model\Link;
-const VERSION = 40;
+const VERSION = 42;
+
+function version_42($pdo)
+{
+ $pdo->exec('ALTER TABLE users ADD COLUMN twofactor_activated BOOLEAN DEFAULT \'0\'');
+ $pdo->exec('ALTER TABLE users ADD COLUMN twofactor_secret CHAR(16)');
+}
function version_41($pdo)
{