Reverts SQL query identifier escaping to simplify queries and improves overall readability by using lowercase column names.
Enhances maintainability and alignment with database conventions by adopting a uniform casing scheme across all SQL operations.
Removes unnecessary complexity in query construction, streamlining the database operations performed within the application.
Improves SQL query execution by ensuring proper casing for identifiers across various database types, particularly for Postgres.
Enhances security and compatibility by using an identifier escaping method, preventing potential errors due to case sensitivity in SQL queries.
Addresses potential issues with existing queries for better reliability and consistency.
Consolidates the creation of SQL query builders across multiple classes to ensure a unified approach for database operations.
Replaces manual type checks and specific query creators with a generic method for better maintainability and to prevent errors.
Improves code readability and reduces duplication, facilitating easier updates in the future.
Removes obsolete query builder interface and implementations.
Introduces a new namespace for query-related classes to enhance organization.
Updates various database managers to use the new query utilities, promoting code reuse and maintainability.
Enhances query functionality, ensuring better consistency across the codebase.
This fixes a bug with a bad actor getting banned with a blank client UUID and then preventing anyone from joining the server due to a lack of UUID on the Connect Request ban check.
DeathCradle spotted a typo in the ban converter and identified that the
issue is likely because we used table_name in some, but not all, of the
conversion SQL.
Co-authored-by: DeathCradle <rt.luke.s@gmail.com>
If there's one thing I learned in this exercise, it's that letting
people add random python scripts to the repo like gpltext.py that
promise to be easier than find and replace is a bad idea.
The ban system needs a full rewrite anyway, but this move removes
something from Utils, puts it closer to its operating point, simplifies
the method, and clarifies what it actually does.
Frontend still doesn't work properly. In particular:
1. Need a way to list bans by account name.
2. Need a way to unban by account name.
3. Really need a way to change the IP on a ban lol.
Ban system still needs to be be rebuilt fully, but at least this
doesn't necessarily character ban someone if you were going for an IP
ban.
Fixes#1412
Added BanningUser, Date(of ban), and Expiration to the db
On join, Expiration is checked, if ban is expired we remove it and the user is allowed on.
When running the ban command, your UAN is used as the banning user, and the date is that moment, with no expiration.
#531