mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 13:17:41 +00:00
GUACAMOLE-36: Add password reset date to schema.
This commit is contained in:
@@ -85,6 +85,7 @@ CREATE TABLE `guacamole_user` (
|
||||
`username` varchar(128) NOT NULL,
|
||||
`password_hash` binary(32) NOT NULL,
|
||||
`password_salt` binary(32),
|
||||
`password_date` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
|
||||
-- Account disabled/expired status
|
||||
`disabled` boolean NOT NULL DEFAULT 0,
|
||||
|
@@ -0,0 +1,25 @@
|
||||
--
|
||||
-- Licensed to the Apache Software Foundation (ASF) under one
|
||||
-- or more contributor license agreements. See the NOTICE file
|
||||
-- distributed with this work for additional information
|
||||
-- regarding copyright ownership. The ASF licenses this file
|
||||
-- to you under the Apache License, Version 2.0 (the
|
||||
-- "License"); you may not use this file except in compliance
|
||||
-- with the License. You may obtain a copy of the License at
|
||||
--
|
||||
-- http://www.apache.org/licenses/LICENSE-2.0
|
||||
--
|
||||
-- Unless required by applicable law or agreed to in writing,
|
||||
-- software distributed under the License is distributed on an
|
||||
-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
-- KIND, either express or implied. See the License for the
|
||||
-- specific language governing permissions and limitations
|
||||
-- under the License.
|
||||
--
|
||||
|
||||
--
|
||||
-- Add per-user password set date
|
||||
--
|
||||
|
||||
ALTER TABLE guacamole_user
|
||||
ADD COLUMN password_date DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP;
|
@@ -29,6 +29,7 @@
|
||||
<result column="username" property="identifier" jdbcType="VARCHAR"/>
|
||||
<result column="password_hash" property="passwordHash" jdbcType="BINARY"/>
|
||||
<result column="password_salt" property="passwordSalt" jdbcType="BINARY"/>
|
||||
<result column="password_date" property="passwordDate" jdbcType="TIMESTAMP"/>
|
||||
<result column="disabled" property="disabled" jdbcType="BOOLEAN"/>
|
||||
<result column="access_window_start" property="accessWindowStart" jdbcType="TIME"/>
|
||||
<result column="access_window_end" property="accessWindowEnd" jdbcType="TIME"/>
|
||||
@@ -61,6 +62,7 @@
|
||||
username,
|
||||
password_hash,
|
||||
password_salt,
|
||||
password_date,
|
||||
disabled,
|
||||
expired,
|
||||
access_window_start,
|
||||
@@ -85,6 +87,7 @@
|
||||
username,
|
||||
password_hash,
|
||||
password_salt,
|
||||
password_date,
|
||||
disabled,
|
||||
expired,
|
||||
access_window_start,
|
||||
@@ -112,6 +115,7 @@
|
||||
username,
|
||||
password_hash,
|
||||
password_salt,
|
||||
password_date,
|
||||
disabled,
|
||||
expired,
|
||||
access_window_start,
|
||||
@@ -139,6 +143,7 @@
|
||||
username,
|
||||
password_hash,
|
||||
password_salt,
|
||||
password_date,
|
||||
disabled,
|
||||
expired,
|
||||
access_window_start,
|
||||
@@ -151,6 +156,7 @@
|
||||
#{object.identifier,jdbcType=VARCHAR},
|
||||
#{object.passwordHash,jdbcType=BINARY},
|
||||
#{object.passwordSalt,jdbcType=BINARY},
|
||||
#{object.passwordDate,jdbcType=TIMESTAMP},
|
||||
#{object.disabled,jdbcType=BOOLEAN},
|
||||
#{object.expired,jdbcType=BOOLEAN},
|
||||
#{object.accessWindowStart,jdbcType=TIME},
|
||||
@@ -167,6 +173,7 @@
|
||||
UPDATE guacamole_user
|
||||
SET password_hash = #{object.passwordHash,jdbcType=BINARY},
|
||||
password_salt = #{object.passwordSalt,jdbcType=BINARY},
|
||||
password_date = #{object.passwordDate,jdbcType=TIMESTAMP},
|
||||
disabled = #{object.disabled,jdbcType=BOOLEAN},
|
||||
expired = #{object.expired,jdbcType=BOOLEAN},
|
||||
access_window_start = #{object.accessWindowStart,jdbcType=TIME},
|
||||
|
Reference in New Issue
Block a user