Redo mac bans - reduce amount of db queries on login

Works just like ip and hwid bans in that they are loaded on startup
This commit is contained in:
P0nk
2024-10-01 22:12:10 +02:00
parent af02f8b744
commit 5d81e05458
18 changed files with 217 additions and 49 deletions

View File

@@ -15,3 +15,12 @@ CREATE TABLE hwid_ban
PRIMARY KEY (hwid)
);
GRANT SELECT ON TABLE hwid_ban TO ${server-username};
CREATE TABLE mac_ban
(
mac varchar(30) NOT NULL,
account_id integer,
created_at timestamp DEFAULT now() NOT NULL,
PRIMARY KEY (mac)
);
GRANT SELECT, INSERT ON TABLE mac_ban TO ${server-username};