// users_tokendata is used by ga4php, users_otk is the qrcode data link if needed,
// tokentype is the software/hardware token types
- $sql = 'CREATE TABLE "users" ("users_id" INTEGER PRIMARY KEY AUTOINCREMENT,"users_username" TEXT, "users_realname" TEXT, "users_password" TEXT, "users_tokendata" TEXT, "users_qrcodeid" TEXT, "user_enabled" TEXT, "users_tokentype" TEXT);';
+ $sql = 'CREATE TABLE "users" ("users_id" INTEGER PRIMARY KEY AUTOINCREMENT,"users_username" TEXT, "users_realname" TEXT, "users_password" TEXT, "users_tokendata" TEXT, "users_qrcodeid" TEXT, "user_enabled" TEXT, "users_tokentype" TEXT, "users_isadmin" TEXT, "users_pin" TEXT);';
$dbobject->query($sql);
//if(!$res) {
//echo "Create user table failed\n";
{
$db = getDB();
- $sql = "insert into users values (NULL, '$username', '$realname', '', '$data', '', '1', '')";
+ $sql = "insert into users values (NULL, '$username', '$realname', '', '$data', '', '1', '', '0', '')";
}
// a funciton to deal with Config Vars
} else {
// do insert
//error_log("doing user data create");
- $sql = "insert into users values (NULL, '$username', '', '', '$data', '', '1', 'software')";
+ $sql = "insert into users values (NULL, '$username', '', '', '$data', '', '1', 'software', '0', '')";
}
if($dbObject->query($sql)) {
global $TCP_PORT_NUMBER;
+/* tasks we need to do (- prefix means done or working)
+ * - status
+ * - init
+ * - set ad login
+ * - set ad client group
+ * - set ad admin group
+ * - provision user
+ * - get users
+ * - delete user
+ * - create hardware token
+ * - list hardware tokens
+ * - assign hardware token
+ * disable user
+ * set user password
+ * enable admin for user
+ * disable admin for user
+ * resync token
+ * get qrcode
+ * re-create user token
+ * set user pin
+ * authenticate token
+ * authenticate pin
+ *
+ */
// the messages structure, used to extend gaas if needed