mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-11-29 19:03:34 +00:00
webauthn has been implemented in an extension
This commit is contained in:
parent
001b60184c
commit
ad2e735687
|
|
@ -70,7 +70,6 @@ CREATE TABLE `tblUsers` (
|
|||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`login` varchar(50) DEFAULT NULL,
|
||||
`pwd` varchar(255) DEFAULT NULL,
|
||||
`webauthn` text DEFAULT NULL,
|
||||
`secret` varchar(50) DEFAULT NULL,
|
||||
`fullName` varchar(100) DEFAULT NULL,
|
||||
`email` varchar(70) DEFAULT NULL,
|
||||
|
|
|
|||
|
|
@ -65,7 +65,6 @@ CREATE TABLE "tblUsers" (
|
|||
"id" SERIAL UNIQUE,
|
||||
"login" varchar(50) default NULL,
|
||||
"pwd" varchar(255) default NULL,
|
||||
"webauthn" text default NULL,
|
||||
"secret" varchar(50) default NULL,
|
||||
"fullName" varchar(100) default NULL,
|
||||
"email" varchar(70) default NULL,
|
||||
|
|
|
|||
|
|
@ -66,7 +66,6 @@ CREATE TABLE `tblUsers` (
|
|||
`id` INTEGER PRIMARY KEY AUTOINCREMENT,
|
||||
`login` varchar(50) default NULL,
|
||||
`pwd` varchar(255) default NULL,
|
||||
`webauthn` TEXT default NULL,
|
||||
`secret` varchar(50) default NULL,
|
||||
`fullName` varchar(100) default NULL,
|
||||
`email` varchar(70) default NULL,
|
||||
|
|
|
|||
|
|
@ -8,8 +8,6 @@ ALTER TABLE "tblUserPasswordHistory" ALTER COLUMN "pwd" varchar(255) DEFAULT NUL
|
|||
|
||||
ALTER TABLE "tblUserPasswordRequest" ALTER COLUMN "hash" varchar(255) DEFAULT NULL;
|
||||
|
||||
ALTER TABLE "tblUsers" ADD COLUMN "webauthn" TYPE text DEFAULT NULL;
|
||||
|
||||
ALTER TABLE "tblUsers" ADD COLUMN "disabledUntil" TYPE TIMESTAMP DEFAULT NULL;
|
||||
|
||||
ALTER TABLE "tblDocuments" ADD COLUMN "startdate" TIMESTAMP default NULL;
|
||||
|
|
|
|||
|
|
@ -38,8 +38,6 @@ DROP TABLE `tblUsers`;
|
|||
|
||||
ALTER TABLE `new_tblUsers` RENAME TO `tblUsers`;
|
||||
|
||||
ALTER TABLE `tblUsers` ADD COLUMN `webauthn` TEXT DEFAULT NULL;
|
||||
|
||||
ALTER TABLE `tblUsers` ADD COLUMN `disabledUntil` TEXT DEFAULT NULL;
|
||||
|
||||
CREATE TABLE `new_tblUserPasswordRequest` (
|
||||
|
|
|
|||
|
|
@ -8,8 +8,6 @@ ALTER TABLE `tblUserPasswordHistory` CHANGE `pwd` `pwd` varchar(255) DEFAULT NUL
|
|||
|
||||
ALTER TABLE `tblUserPasswordRequest` CHANGE `hash` `hash` varchar(255) DEFAULT NULL;
|
||||
|
||||
ALTER TABLE `tblUsers` ADD COLUMN `webauthn` text DEFAULT NULL AFTER `pwd`;
|
||||
|
||||
ALTER TABLE `tblUsers` ADD COLUMN `disabledUntil` datetime DEFAULT NULL AFTER `disabled`;
|
||||
|
||||
ALTER TABLE `tblDocuments` ADD COLUMN `enddate` datetime DEFAULT NULL AFTER `sequence`;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@ include("../inc/inc.ClassSession.php");
|
|||
include("../inc/inc.DBInit.php");
|
||||
include("../inc/inc.ClassUI.php");
|
||||
include("../inc/inc.ClassController.php");
|
||||
require_once("../inc/inc.WebAuthn.php");
|
||||
|
||||
include $settings->_rootDir . "languages/" . $settings->_language . "/lang.inc";
|
||||
|
||||
|
|
@ -92,24 +91,11 @@ $controller->setParam('sesstheme', $sesstheme);
|
|||
$controller->setParam('referuri', $referuri);
|
||||
$controller->setParam('session', $session);
|
||||
$controller->setParam('authenticator', $authenticator);
|
||||
$action = !empty($_POST['action']) ? $_POST['action'] : '';
|
||||
switch($action) {
|
||||
/* preparelogin() and login() are both called by ajax */
|
||||
case 'preparelogin':
|
||||
$controller->preparelogin();
|
||||
exit();
|
||||
break;
|
||||
case 'login':
|
||||
$controller->login();
|
||||
exit();
|
||||
break;
|
||||
default:
|
||||
if(!$controller()) {
|
||||
$session = null;
|
||||
add_log_line("login failed", PEAR_LOG_ERR);
|
||||
_printMessage(getMLText($controller->getErrorMsg()), getMLText($controller->getErrorMsg())."\n");
|
||||
exit;
|
||||
}
|
||||
if(!$controller()) {
|
||||
$session = null;
|
||||
add_log_line("login failed", PEAR_LOG_ERR);
|
||||
_printMessage(getMLText($controller->getErrorMsg()), getMLText($controller->getErrorMsg())."\n");
|
||||
exit;
|
||||
}
|
||||
|
||||
$user = $controller->getUser();
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user