mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
[s] [admin] Adds credential binding (#14178)
* Adds credential binding * Removes auto increment * qdel 1 * qdel 2 Co-authored-by: alexkar598 <>
This commit is contained in:
@@ -1,13 +1,28 @@
|
||||
Any time you make a change to the schema files, remember to increment the database schema version. Generally increment the minor number, major should be reserved for significant changes to the schema. Both values go up to 255.
|
||||
|
||||
The latest database version is 5.6; The query to update the schema revision table is:
|
||||
The latest database version is 5.10; The query to update the schema revision table is:
|
||||
|
||||
INSERT INTO `schema_revision` (`major`, `minor`) VALUES (5, 9);
|
||||
INSERT INTO `schema_revision` (`major`, `minor`) VALUES (5, 10);
|
||||
or
|
||||
INSERT INTO `SS13_schema_revision` (`major`, `minor`) VALUES (5, 9);
|
||||
INSERT INTO `SS13_schema_revision` (`major`, `minor`) VALUES (5, 10);
|
||||
|
||||
In any query remember to add a prefix to the table names if you use one.
|
||||
|
||||
version 5.10 2022-05-18, alexkar598
|
||||
Adds credentials binding
|
||||
|
||||
CREATE TABLE `bound_credentials` (
|
||||
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`ckey` varchar(32) NOT NULL,
|
||||
`computerid` varchar(32) DEFAULT NULL,
|
||||
`ip` int(10) unsigned DEFAULT NULL,
|
||||
`flags` set('bypass_bans') DEFAULT NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `idx_ckey_lookup` (`ckey`),
|
||||
KEY `idx_cid_lookup` (`computerid`),
|
||||
KEY `idx_ip_lookup` (`ip`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
version 5.9 23 November 2021, by adamsogm
|
||||
|
||||
Adds the datetime column to the primary key for the MFA table
|
||||
|
||||
@@ -116,6 +116,19 @@ CREATE TABLE IF NOT EXISTS `ban` (
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=39587 DEFAULT CHARSET=utf8;
|
||||
|
||||
|
||||
DROP TABLE IF EXISTS `bound_credentials`;
|
||||
CREATE TABLE `bound_credentials` (
|
||||
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`ckey` varchar(32) NOT NULL,
|
||||
`computerid` varchar(32) DEFAULT NULL,
|
||||
`ip` int(10) unsigned DEFAULT NULL,
|
||||
`flags` set('bypass_bans') DEFAULT NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `idx_ckey_lookup` (`ckey`),
|
||||
KEY `idx_cid_lookup` (`computerid`),
|
||||
KEY `idx_ip_lookup` (`ip`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
DROP TABLE IF EXISTS `connection_log`;
|
||||
CREATE TABLE IF NOT EXISTS `connection_log` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
|
||||
@@ -116,6 +116,18 @@ CREATE TABLE IF NOT EXISTS `SS13_ban` (
|
||||
KEY `idx_ban_count` (`bantime`,`a_ckey`,`applies_to_admins`,`unbanned_datetime`,`expiration_time`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=39587 DEFAULT CHARSET=utf8;
|
||||
|
||||
DROP TABLE IF EXISTS `SS13_bound_credentials`;
|
||||
CREATE TABLE `SS13_bound_credentials` (
|
||||
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`ckey` varchar(32) NOT NULL,
|
||||
`computerid` varchar(32) DEFAULT NULL,
|
||||
`ip` int(10) unsigned DEFAULT NULL,
|
||||
`flags` set('bypass_bans') DEFAULT NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `idx_ckey_lookup` (`ckey`),
|
||||
KEY `idx_cid_lookup` (`computerid`),
|
||||
KEY `idx_ip_lookup` (`ip`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
DROP TABLE IF EXISTS `SS13_connection_log`;
|
||||
CREATE TABLE IF NOT EXISTS `SS13_connection_log` (
|
||||
|
||||
Reference in New Issue
Block a user