2021-03-29 12:45:27 +01:00
|
|
|
// Copyright (C) 2019 Storj Labs, Inc.
|
|
|
|
// See LICENSE for copying information.
|
|
|
|
|
|
|
|
syntax = "proto3";
|
|
|
|
option go_package = "storj.io/storj/certificate/certificatepb";
|
|
|
|
|
|
|
|
package node;
|
|
|
|
|
|
|
|
service Certificates {
|
|
|
|
rpc Sign(SigningRequest) returns (SigningResponse);
|
|
|
|
}
|
|
|
|
|
|
|
|
message SigningRequest {
|
|
|
|
string auth_token = 1;
|
2023-01-19 15:02:44 +00:00
|
|
|
int64 timestamp = 2;
|
2021-03-29 12:45:27 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
message SigningResponse {
|
|
|
|
repeated bytes chain = 1;
|
|
|
|
}
|
2023-01-19 15:02:44 +00:00
|
|
|
|
|
|
|
|
|
|
|
// These types are used for storing authorizations in a database.
|
|
|
|
|
|
|
|
message AuthorizationGroup {
|
|
|
|
repeated Authorization authorizations = 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
message Authorization {
|
|
|
|
Token token = 1;
|
|
|
|
Claim claim = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message Token {
|
|
|
|
bytes user_id = 1;
|
|
|
|
bytes data = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message Claim {
|
|
|
|
bytes addr = 1;
|
|
|
|
int64 timestamp = 2;
|
|
|
|
bytes identity = 3;
|
|
|
|
repeated bytes signed_chain_bytes = 4;
|
|
|
|
}
|