- Introduced error handling for non-existent servers and users. - Updated user management methods to include email retrieval. - Modified user creation to accept password as a parameter. - Added server management methods for retrieving friends and backups. - Removed obsolete PostgreSQL implementation. - Enhanced SQLite implementation with new SQL scripts for user and server management. - Implemented encryption for user passwords using AES-192 and scrypt. - Added tests for database operations and encryption functionality. - Improved server and user structures to include additional fields. Signed-off-by: Matheus Sampaio Queiroga <srherobrine20@gmail.com>
6 lines
198 B
SQL
6 lines
198 B
SQL
-- User
|
|
INSERT INTO user(username, name, email)
|
|
VALUE (LOWER($1), $2, LOWER($3));
|
|
-- Password hash
|
|
INSERT INTO password(user, password)
|
|
VALUE ((SELECT id FROM user WHERE username = $1 LIMIT 1), $4); |