mirror of
https://github.com/Caraxi/mare.server.git
synced 2025-12-12 18:17:22 +01:00
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>
This commit is contained in:
parent
d37c1208fe
commit
c98e2b2dd6
20 changed files with 313 additions and 159 deletions
|
|
@ -5,8 +5,8 @@ option csharp_namespace = "MareSynchronosShared.Protos";
|
|||
package mareservices;
|
||||
|
||||
service AuthService {
|
||||
rpc Authorize (AuthRequest) returns (AuthReply);
|
||||
rpc RemoveAuth (RemoveAuthRequest) returns (Empty);
|
||||
rpc Authorize (stream AuthRequest) returns (stream AuthReply);
|
||||
rpc RemoveAuth (UidMessage) returns (Empty);
|
||||
rpc ClearUnauthorized (Empty) returns (Empty);
|
||||
}
|
||||
|
||||
|
|
@ -101,10 +101,6 @@ message FileSizeResponse {
|
|||
map<string, int64> hashToFileSize = 1;
|
||||
}
|
||||
|
||||
message RemoveAuthRequest {
|
||||
string uid = 1;
|
||||
}
|
||||
|
||||
message AuthRequest {
|
||||
string ip = 1;
|
||||
string secretKey = 2;
|
||||
|
|
@ -112,5 +108,5 @@ message AuthRequest {
|
|||
|
||||
message AuthReply {
|
||||
bool success = 1;
|
||||
string uid = 2;
|
||||
UidMessage uid = 2;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue