proto: add AuthRegister and AuthApprove RPCs
Add gRPC service definitions for managing auth requests: AuthRegister to register interactive auth sessions and AuthApprove/AuthReject to approve or deny pending requests (used for SSH check mode). Updates #1850
This commit is contained in:
parent
107c2f2f70
commit
dc0e52a960
2 changed files with 50 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ import "headscale/v1/user.proto";
|
|||
import "headscale/v1/preauthkey.proto";
|
||||
import "headscale/v1/node.proto";
|
||||
import "headscale/v1/apikey.proto";
|
||||
import "headscale/v1/auth.proto";
|
||||
import "headscale/v1/policy.proto";
|
||||
|
||||
service HeadscaleService {
|
||||
|
|
@ -139,6 +140,29 @@ service HeadscaleService {
|
|||
|
||||
// --- Node end ---
|
||||
|
||||
// --- Auth start ---
|
||||
rpc AuthRegister(AuthRegisterRequest) returns (AuthRegisterResponse) {
|
||||
option (google.api.http) = {
|
||||
post : "/api/v1/auth/register"
|
||||
body : "*"
|
||||
};
|
||||
}
|
||||
|
||||
rpc AuthApprove(AuthApproveRequest) returns (AuthApproveResponse) {
|
||||
option (google.api.http) = {
|
||||
post : "/api/v1/auth/approve"
|
||||
body : "*"
|
||||
};
|
||||
}
|
||||
|
||||
rpc AuthReject(AuthRejectRequest) returns (AuthRejectResponse) {
|
||||
option (google.api.http) = {
|
||||
post : "/api/v1/auth/reject"
|
||||
body : "*"
|
||||
};
|
||||
}
|
||||
// --- Auth end ---
|
||||
|
||||
// --- ApiKeys start ---
|
||||
rpc CreateApiKey(CreateApiKeyRequest) returns (CreateApiKeyResponse) {
|
||||
option (google.api.http) = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue