From 78de5a978e976eb5677454ed72a8388930543a53 Mon Sep 17 00:00:00 2001 From: Olov Danielson Date: Tue, 12 Jan 2010 17:37:00 +0000 Subject: [PATCH] when creatin yubikey entries all values better be filled in --- ykval-synclib.php | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/ykval-synclib.php b/ykval-synclib.php index 8db8ee1..e6d0839 100644 --- a/ykval-synclib.php +++ b/ykval-synclib.php @@ -128,12 +128,17 @@ class SyncLib if (!$res) { $this->log(LOG_NOTICE, 'Discovered new identity ' . $yk_publicname); - $this->db->save('yubikeys', array('yk_publicname'=>$yk_publicname, - 'created'=>time(), - 'active'=>1, + $this->db->save('yubikeys', array('active'=>1, + 'created'=>time(), + 'modified'=>0, + 'yk_publicname'=>$yk_publicname, + 'yk_internalname'=>'not set', 'yk_counter'=>0, 'yk_use'=>0, - 'nonce'=>0)); + 'yk_low'=>0, + 'yk_high'=>0, + 'nonce'=>'', + 'notes'=>'')); $res=$this->db->findBy('yubikeys', 'yk_publicname', $yk_publicname,1); } if ($res) {