47 Commits

Author SHA1 Message Date
Opaque02
c2af4a07e9
Made changes to server to allow admin panel to retrieve last activity instead of last logged in date (#58)
* Made changes to server to allow admin panel to retrieve last activity instead of last logged in date

* Added TODO comment for lastLoggedIn json result

* Updated variable names as per Pancake's comments
2024-10-27 21:25:46 -04:00
Pancakes
00e783ff8a
Styling fixes 2024-10-22 15:50:01 -04:00
Opaque02
430496941c
Admin panel upgrade server updates (#54)
* Changes for testing

* Updating server code to allow unlinking discord IDs as needed

* Fixed some debug issues commented out code

* Updating server to allow updated admin panel functionality

* Updated some commentted out code

* Updated missed /

* Updated to allow for a single query to the db with multiple columns, and a conversion to allow string outputs instead of sql.NullStrings

* Deleted .bak files and .vs folder as per Walker's discord message

* Added logic to check server to make sure usename exists for discord linking and unlinking

* Changes to allow linking and unlinking of google Id from DB

* Removed .vs folder

* Reverted dev code

* PR comments

* Updates from Pancake's comments
2024-10-16 20:36:44 -04:00
Frederico Santos
8e20875453
feat: Add admin Discord link endpoint (#49)
* feat: Add admin Discord link endpoint

* feat: Add Discord Guild ID flag to server configuration

* feat: Add logging for Discord ID addition in admin Discord link endpoint

* chore: Update variable name for Discord guild ID in account package

* chore: Add logging for Discord ID addition in admin Discord link endpoint

* chore: Add admin Discord link endpoint

* chore: Add logging for Discord ID addition in admin Discord link endpoint

* chore: Remove unnecessary code in handleAdminDiscordLink function

* chore: Update logging format in handleAdminDiscordLink function

* chore: Refactor handleAdminDiscordLink function for improved logging

* chore: Update Discord Bot Token and Discord Guild ID flags in server configuration

* chore: Refactor handleAccountInfo function for improved readability and error handling

* chore: Update server configuration flags for Discord Bot Token and Guild ID

* Refactor handleAdminDiscordLink function for improved error handling and logging

* feat: Add "Helper" role to Discord admin check for enhanced access control
2024-09-13 22:32:49 -04:00
Frederico Santos
fa57f5997f
Added support for Discord OAuth2 (#25)
* Need a login check

* chore: Add Discord OAuth2 authentication endpoint

chore: Update dependencies and clean up code

chore: Update dependencies, add Discord OAuth2 authentication endpoint, and clean up code

chore: Update dependencies, add Google OAuth2 authentication endpoint, and clean up code

Code clean up

uniqueness on external account id

chore: Add Discord and Google OAuth2 authentication endpoints, and update dependencies

code review fixes

* chore: Update prodHandler to use clienturl flag for Access-Control-Allow-Origin

* chore: Refactor FetchDiscordIdByUsername and FetchGoogleIdByUsername to handle null values

* chore: Set secure and same-site attributes for session cookie

* chore: Set session cookie expiration to 3 months

* Update callback URL for Oauth2 client in docker-compose and rogueserver.go

* Update callback URL for Oauth2 client in docker-compose and rogueserver.go

---------

Co-authored-by: Matthew Olker <matthew.olker@gmail.com>
2024-07-27 18:41:44 -04:00
Pancakes
dd00d90211
Remove voucher compensation code 2024-06-22 16:10:35 -04:00
maru
476e667572
More cleanup 2024-05-24 01:47:36 -04:00
maru
c76746ad35
Replace REPLACE INTO usage 2024-05-24 01:41:50 -04:00
maru
7bfd9dfba7
Fix code 2024-05-21 01:48:07 -04:00
maru
fc458fad73
Revert "Remove anti cheat"
This reverts commit 512a24e5c3b1a51045a91acd9049c64266cc6d64.
2024-05-21 01:39:07 -04:00
Up
f31f130c14
also check for empty 2024-05-15 06:47:06 +02:00
Up
c17c583321
update active session if none is found 2024-05-15 06:46:08 +02:00
Up
e2efcd550c
fix faulty sql query 2024-05-14 23:17:14 +02:00
Up
c0aade2e65
simplify ID handling 2024-05-14 14:30:04 +02:00
Up
436fce8759
add client session ID tokens 2024-05-14 12:54:06 +02:00
maru
a087234aa8
Replace usernameFromRequest 2024-05-05 16:12:10 -04:00
maru
808a9e6c7d
Remove redundant error check 2024-05-05 16:08:43 -04:00
Flashfyre
3553891e6e Temporarily remove session expiration check 2024-05-05 14:57:58 -04:00
Flashfyre
e19104c86a Prevent initial out of date message on register 2024-04-30 14:59:58 -04:00
maru
512a24e5c3
Remove anti cheat 2024-04-30 14:34:40 -04:00
maru
786e947e09
Change 'banned' to 'limited 2024-04-30 00:32:55 -04:00
maru
8481626193
Relicense under AGPL 2024-04-29 17:26:46 -04:00
maru
235fb9c91c
Add copyright notice to files 2024-04-29 15:32:58 -04:00
maru
e8240c9c38
Rename to rogueserver 2024-04-29 15:22:27 -04:00
maru
e184e9da91
Ban if vouchers over a certain threshold 2024-04-28 20:59:53 -04:00
maru
cbcc68f8e4
Add password changes 2024-04-28 17:27:58 -04:00
maru
2adb70dd7e
Styling consistency 2024-04-25 15:11:26 -04:00
Flashfyre
2f8c2d3f07 Match trainer and secret ID on update for data integrity 2024-04-25 09:56:56 -04:00
Flashfyre
6acbb6448a Protect against cross-session overwrites 2024-04-21 16:23:25 -04:00
maru
522ce9f4fa
Update GitHub link 2024-04-14 19:25:36 -04:00
Flashfyre
a4014feea8 Track player vouchers 2024-04-11 10:13:35 -04:00
Flashfyre
992864b785 Add voucher compensation logic 2024-04-09 22:22:00 -04:00
maru
0edfeab3ca
Various styling changes 2024-04-08 18:15:09 -04:00
Flashfyre
99d3490172 Update account stats on system save 2024-04-06 17:43:11 -04:00
Flashfyre
be04408336 Update random daily seed logic 2024-03-18 19:55:02 -04:00
Flashfyre
23eb0bbbe8 Log last activity date 2024-03-15 16:38:32 -04:00
maru
a19280d02c
Add cloud save data 2023-12-31 16:12:20 -05:00
Flashfyre
e05f6f752b Add last logged in date to accounts table 2023-12-30 22:05:56 -05:00
maru
575167f0f9
Simplify error return in GetUsernameFromToken 2023-12-29 14:38:12 -05:00
Flashfyre
9ef76f1064 Fix account session insert query typo 2023-12-28 21:37:04 -05:00
Flashfyre
688b435bd1 Rename key column to hash 2023-12-28 21:32:03 -05:00
Flashfyre
b4be49bf80 Fix query keyword conflict by using alias 2023-12-28 21:13:21 -05:00
maru
f5d9cc6760
Workaround for column name 2023-12-28 21:09:15 -05:00
maru
0e6b2bbf5c
Fix query in GetUsernameFromToken 2023-12-28 20:09:50 -05:00
maru
8d3d24a58a
Add mysql driver 2023-12-28 19:58:54 -05:00
maru
4600b7b024
More changes 2023-12-28 19:53:59 -05:00
maru
f690c53607
Add changes so far 2023-12-05 13:28:08 -05:00