mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
This commit lets etcdserver check permission during its log applying phase. With this change, permission checking of operations is supported. Currently, put and range are supported. In addition, multi key permission check of range isn't supported yet.
51 lines
1.3 KiB
Protocol Buffer
51 lines
1.3 KiB
Protocol Buffer
syntax = "proto3";
|
|
package etcdserverpb;
|
|
|
|
import "gogoproto/gogo.proto";
|
|
import "etcdserver.proto";
|
|
import "rpc.proto";
|
|
|
|
option (gogoproto.marshaler_all) = true;
|
|
option (gogoproto.sizer_all) = true;
|
|
option (gogoproto.unmarshaler_all) = true;
|
|
option (gogoproto.goproto_getters_all) = false;
|
|
|
|
message RequestHeader {
|
|
uint64 ID = 1;
|
|
// username is a username that is associated with an auth token of gRPC connection
|
|
string username = 2;
|
|
}
|
|
|
|
// An InternalRaftRequest is the union of all requests which can be
|
|
// sent via raft.
|
|
message InternalRaftRequest {
|
|
RequestHeader header = 100;
|
|
uint64 ID = 1;
|
|
|
|
Request v2 = 2;
|
|
|
|
RangeRequest range = 3;
|
|
PutRequest put = 4;
|
|
DeleteRangeRequest delete_range = 5;
|
|
TxnRequest txn = 6;
|
|
CompactionRequest compaction = 7;
|
|
|
|
LeaseGrantRequest lease_grant = 8;
|
|
LeaseRevokeRequest lease_revoke = 9;
|
|
|
|
AuthEnableRequest auth_enable = 10;
|
|
AuthDisableRequest auth_disable = 11;
|
|
AuthUserAddRequest auth_user_add = 12;
|
|
AuthUserDeleteRequest auth_user_delete = 13;
|
|
AuthUserChangePasswordRequest auth_user_change_password = 14;
|
|
AuthUserGrantRequest auth_user_grant = 15;
|
|
AuthRoleAddRequest auth_role_add = 16;
|
|
AuthRoleGrantRequest auth_role_grant = 17;
|
|
AuthenticateRequest authenticate = 18;
|
|
|
|
AlarmRequest alarm = 19;
|
|
}
|
|
|
|
message EmptyResponse {
|
|
}
|