Commit Graph

62 Commits

Author SHA1 Message Date
rootdarkarchon
d7e664477f Merge branch 'main' of https://github.com/Penumbra-Sync/server 2023-01-18 19:46:36 +01:00
rootdarkarchon
fe80faab6b potentially fix stuck uploads 2023-01-18 19:46:03 +01:00
rootdarkarchon
35f61d5387 add configurable redis pool and allow redis timeout 2023-01-18 11:11:59 +01:00
rootdarkarchon
4bd71a5889 Download rework (#22)
* rework server to send download ready back via signalr

* adjust queue handling for removal

* adjust api to main

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2023-01-15 16:00:38 +01:00
rootdarkarchon
9605be8d4a minor stylefixes 2023-01-14 12:54:11 +01:00
rootdarkarchon
617bc6afc8 fix token generation 2023-01-11 13:29:49 +01:00
rootdarkarchon
42b15cb6b7 Add Server-Side Download Queue (#21)
* test add queueing to file service

* further adjustments to download queueing

* add check for whether the request is still in the queue to CheckQueue

* forcefully release slot if download didn't finish in 15s

* actually cancel the delay task

* add metrics and refactor some of the request queue service

* refactor pathing

* reuse httpclient

* add queue request dto to requestfile, enqueue users immediately if a slot is available

* change startup to include all controllers

* update server pathing

* update pathing, again

* several adjustments to auth, banning, jwt server tokens, renaming, authorization

* update api I guess

* adjust automated banning of charaident and reg

* generate jwt on servers for internal authentication

* remove mvcextensions

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2023-01-11 12:22:22 +01:00
rootdarkarchon
a182f36485 attempt to switch ident service to redis 2023-01-08 14:51:56 +01:00
rootdarkarchon
d328056b9b fix claims and logging in files controller 2023-01-07 01:57:16 +01:00
rootdarkarchon
74b7fcdf89 Refactoring using Claims more, add Server Side Messaging (#20)
* add some refactoring based on claims, handle chara ident inside claim, fix discord userid in log

* improve authentication responses, add server side messaging

* update server to mainline api

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2023-01-04 15:49:18 +01:00
rootdarkarchon
5f0c12ecfa Switch to JWT authentication (#19)
* switch to jwt authentication

* fix delete files

* adjust saving of deletion of all files

* update api to main/jwt

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2023-01-02 17:07:34 +01:00
rootdarkarchon
7f49ca8627 increase timer again 2023-01-02 01:38:53 +01:00
rootdarkarchon
738c913be9 move some stuff around, pray 2023-01-01 23:36:34 +01:00
rootdarkarchon
f8c9d1e64f shuffle cdn shard configs to allow for multiple file shards to handle one file, randomly distributing 2023-01-01 17:32:22 +01:00
rootdarkarchon
b6404a9c1d add horizontal file sharding based on filename matches 2022-12-31 14:28:24 +01:00
rootdarkarchon
2a5e505130 readd auth header 2022-12-31 12:56:18 +01:00
rootdarkarchon
cbe361208c some changes to auth 2022-12-29 20:14:47 +01:00
rootdarkarchon
4196ab4062 bump shared to 7.0 2022-12-28 14:41:11 +01:00
rootdarkarchon
31550b0aeb move GetFileSize to database 2022-12-28 04:50:37 +01:00
rootdarkarchon
de2defe692 rework MareConfigurationServiceClient 2022-12-28 04:24:53 +01:00
rootdarkarchon
18a9a76dcd remove semaphore 2022-12-27 23:51:41 +01:00
rootdarkarchon
097d7d16e9 remove grpc from common calls to reduce locking 2022-12-27 23:49:25 +01:00
rootdarkarchon
761f208828 make semaphore readonly 2022-12-27 21:59:59 +01:00
rootdarkarchon
3ba37515ab some fixes for server, perhaps 2022-12-27 21:59:41 +01:00
rootdarkarchon
b8c10c4298 adjustments for grpc service client 2022-12-27 20:08:18 +01:00
rootdarkarchon
4d1ef1f871 something something metrics 2022-12-27 15:43:58 +01:00
rootdarkarchon
9eb5967935 rework server responsibilities (#18)
* rework server responsibilities
add remote configuration

* start metrics only when compiled as not debug

* add some more logging to discord bot

* fixes of some casts

* make metrics port configurable, minor fixes

* add docker bullshit

* md formatting

* adjustments to docker stuff

* fix docker json files, fix some stuff in discord bot, add /useradd for Discord bot

* adjust docker configs and fix sharded.bat

* fixes for logs, cache file provider repeat trying to open filestream

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2022-12-27 13:48:05 +01:00
rootdarkarchon
7ee7fdaf48 switch around all iconfiguration usage to ioptions 2022-12-23 01:53:21 +01:00
rootdarkarchon
25aa01c819 rework static files server 2022-12-20 14:20:24 +01:00
rootdarkarchon
ea19231851 remove unnecessary usings from solution, fixes in metrics 2022-12-20 12:00:23 +01:00
rootdarkarchon
7d3297e1e8 add some file statistics metrics 2022-12-20 05:02:03 +01:00
rootdarkarchon
90ccfe4162 adjust metrics 2022-12-19 15:01:12 +01:00
rootdarkarchon
5c9b15545c add metrics to each shard 2022-12-19 14:12:25 +01:00
rootdarkarchon
f278c5a762 rework authentication 2022-12-18 14:53:44 +01:00
rootdarkarchon
333a8dddd2 update dependencies and fix whitelisting of ips potentially 2022-12-12 19:30:06 +01:00
rootdarkarchon
5bd9c7d09d add positive response caching to grpc auth service to lessen load 2022-12-11 13:17:52 +01:00
rootdarkarchon
d83d9a6753 OneTime Invites Server handling (#17)
* add server-side handling for one time invites
2022-10-25 00:54:51 +02:00
Stanley Dimant
8164d737bf whitelist fixes, grpc stream fixes 2022-10-20 23:08:46 +02:00
rootdarkarchon
25772dade8 adjust command 2022-10-20 11:46:07 +02:00
rootdarkarchon
c98e2b2dd6 Switch Authentication to asynchronous streaming calls (#16)
* add base grpc service and swap auth service to streaming

* remove Authorize from hub itself

* remove unused usings

* heave files server to net 7, add exception handling in grpc auth stream

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2022-10-13 16:55:23 +02:00
rootdarkarchon
d37c1208fe Adjust Auth on server (#15)
* add auth that verifies identity is marked online

* few changes for testing

* handle identity with requirements

* remove unnecessary logging from auth handler

* change to UserRequirements

* fixes to checks

* fixes to UserRequirementHandler

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2022-10-10 19:44:30 +02:00
Stanley Dimant
b5325b9c50 adjust grpc api for idents 2022-10-09 14:32:44 +02:00
rootdarkarchon
777a764ef1 move marehub to strong api usage (#14)
* move marehub to strong api usage

* fix merge issues

* latest api

* further optimizations
2022-10-08 14:33:25 +02:00
rootdarkarchon
a45a923260 add group moderation and banning functionality to api (#13)
* add group moderation and banning functionality to api

* set moderator to false on group migration

* send IsModerator in addition on group join

Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
2022-10-06 15:50:15 +02:00
rootdarkarchon
17f26714ce Switch to GrpcClientIdentificationService and abolish Redis for Idents (#12)
* add GrpcClientIdentificationService

* remove unnecessary gauges

* set to no retry policy

* initialize metrics

Co-authored-by: Stanley Dimant <root.darkarchon@outlook.com>
2022-10-05 23:10:36 +02:00
Stanley Dimant
e2e97065f4 adjust alias length 2022-10-04 14:59:50 +02:00
rootdarkarchon
bff21ead95 Syncshells (#11)
* some groups stuff

* further groups rework

* fixes for pause changes

* adjsut timeout interval

* fixes and namespace change to file scoped

* more fixes

* further implement groups

* fix change group ownership

* add some more stuff for groups

* more fixes and additions

* some fixes based on analyzers, add shard info to ui

* add discord command, cleanup

* fix regex

* add group migration and deletion on user deletion

* add api method for client to check health of connection

* adjust regex for vanity

* fixes for server and bot

* fixes some string comparison in linq queries

* fixes group leave and sets alias to null

* fix syntax in changeownership

* add better logging, fixes for group leaving

* fixes for group leave

Co-authored-by: Stanley Dimant <root.darkarchon@outlook.com>
2022-10-04 14:13:43 +02:00
Stanley Dimant
8ce85ad754 change expiry 2022-09-13 12:28:07 +02:00
Stanley Dimant
54499f42a4 more redis fixes 2022-09-13 12:23:19 +02:00
Stanley Dimant
56728d1fba more redis fixes 2022-09-13 12:18:02 +02:00