chore: auto-generate protobuf files [skip ci]

This commit is contained in:
github-actions[bot]
2026-04-11 18:41:58 +00:00
parent 40819206d6
commit da649b7231
3 changed files with 350 additions and 18 deletions

View File

@@ -1273,6 +1273,198 @@ func (x *SystemUpdatePinResponse) GetSuccess() bool {
return false
}
type SystemBlockIpRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
IpAddress string `protobuf:"bytes,1,opt,name=ip_address,json=ipAddress,proto3" json:"ip_address,omitempty"`
AdminId string `protobuf:"bytes,2,opt,name=admin_id,json=adminId,proto3" json:"admin_id,omitempty"`
Reason *string `protobuf:"bytes,3,opt,name=reason,proto3,oneof" json:"reason,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *SystemBlockIpRequest) Reset() {
*x = SystemBlockIpRequest{}
mi := &file_sso_auth_proto_msgTypes[23]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *SystemBlockIpRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SystemBlockIpRequest) ProtoMessage() {}
func (x *SystemBlockIpRequest) ProtoReflect() protoreflect.Message {
mi := &file_sso_auth_proto_msgTypes[23]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SystemBlockIpRequest.ProtoReflect.Descriptor instead.
func (*SystemBlockIpRequest) Descriptor() ([]byte, []int) {
return file_sso_auth_proto_rawDescGZIP(), []int{23}
}
func (x *SystemBlockIpRequest) GetIpAddress() string {
if x != nil {
return x.IpAddress
}
return ""
}
func (x *SystemBlockIpRequest) GetAdminId() string {
if x != nil {
return x.AdminId
}
return ""
}
func (x *SystemBlockIpRequest) GetReason() string {
if x != nil && x.Reason != nil {
return *x.Reason
}
return ""
}
type SystemBlockIpResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *SystemBlockIpResponse) Reset() {
*x = SystemBlockIpResponse{}
mi := &file_sso_auth_proto_msgTypes[24]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *SystemBlockIpResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SystemBlockIpResponse) ProtoMessage() {}
func (x *SystemBlockIpResponse) ProtoReflect() protoreflect.Message {
mi := &file_sso_auth_proto_msgTypes[24]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SystemBlockIpResponse.ProtoReflect.Descriptor instead.
func (*SystemBlockIpResponse) Descriptor() ([]byte, []int) {
return file_sso_auth_proto_rawDescGZIP(), []int{24}
}
func (x *SystemBlockIpResponse) GetSuccess() bool {
if x != nil {
return x.Success
}
return false
}
type SystemUnblockIpRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
IpAddress string `protobuf:"bytes,1,opt,name=ip_address,json=ipAddress,proto3" json:"ip_address,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *SystemUnblockIpRequest) Reset() {
*x = SystemUnblockIpRequest{}
mi := &file_sso_auth_proto_msgTypes[25]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *SystemUnblockIpRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SystemUnblockIpRequest) ProtoMessage() {}
func (x *SystemUnblockIpRequest) ProtoReflect() protoreflect.Message {
mi := &file_sso_auth_proto_msgTypes[25]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SystemUnblockIpRequest.ProtoReflect.Descriptor instead.
func (*SystemUnblockIpRequest) Descriptor() ([]byte, []int) {
return file_sso_auth_proto_rawDescGZIP(), []int{25}
}
func (x *SystemUnblockIpRequest) GetIpAddress() string {
if x != nil {
return x.IpAddress
}
return ""
}
type SystemUnblockIpResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
Success bool `protobuf:"varint,2,opt,name=success,proto3" json:"success,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *SystemUnblockIpResponse) Reset() {
*x = SystemUnblockIpResponse{}
mi := &file_sso_auth_proto_msgTypes[26]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *SystemUnblockIpResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SystemUnblockIpResponse) ProtoMessage() {}
func (x *SystemUnblockIpResponse) ProtoReflect() protoreflect.Message {
mi := &file_sso_auth_proto_msgTypes[26]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SystemUnblockIpResponse.ProtoReflect.Descriptor instead.
func (*SystemUnblockIpResponse) Descriptor() ([]byte, []int) {
return file_sso_auth_proto_rawDescGZIP(), []int{26}
}
func (x *SystemUnblockIpResponse) GetSuccess() bool {
if x != nil {
return x.Success
}
return false
}
var File_sso_auth_proto protoreflect.FileDescriptor
const file_sso_auth_proto_rawDesc = "" +
@@ -1379,7 +1571,20 @@ const file_sso_auth_proto_rawDesc = "" +
"\bpin_hash\x18\x02 \x01(\tH\x00R\apinHash\x88\x01\x01B\v\n" +
"\t_pin_hash\"3\n" +
"\x17SystemUpdatePinResponse\x12\x18\n" +
"\asuccess\x18\x01 \x01(\bR\asuccess2\xc8\a\n" +
"\asuccess\x18\x01 \x01(\bR\asuccess\"x\n" +
"\x14SystemBlockIpRequest\x12\x1d\n" +
"\n" +
"ip_address\x18\x01 \x01(\tR\tipAddress\x12\x19\n" +
"\badmin_id\x18\x02 \x01(\tR\aadminId\x12\x1b\n" +
"\x06reason\x18\x03 \x01(\tH\x00R\x06reason\x88\x01\x01B\t\n" +
"\a_reason\"1\n" +
"\x15SystemBlockIpResponse\x12\x18\n" +
"\asuccess\x18\x01 \x01(\bR\asuccess\"7\n" +
"\x16SystemUnblockIpRequest\x12\x1d\n" +
"\n" +
"ip_address\x18\x01 \x01(\tR\tipAddress\"3\n" +
"\x17SystemUnblockIpResponse\x12\x18\n" +
"\asuccess\x18\x02 \x01(\bR\asuccess2\xee\b\n" +
"\vAuthService\x126\n" +
"\x05Login\x12\x15.auth.v1.LoginRequest\x1a\x16.auth.v1.LoginResponse\x12<\n" +
"\aRefresh\x12\x17.auth.v1.RefreshRequest\x1a\x18.auth.v1.RefreshResponse\x12H\n" +
@@ -1392,7 +1597,9 @@ const file_sso_auth_proto_rawDesc = "" +
"\x13SystemCreateAccount\x12#.auth.v1.SystemCreateAccountRequest\x1a$.auth.v1.SystemCreateAccountResponse\x12]\n" +
"\x12SystemChangeStatus\x12\".auth.v1.SystemChangeStatusRequest\x1a#.auth.v1.SystemChangeStatusResponse\x12c\n" +
"\x14SystemUpdatePassword\x12$.auth.v1.SystemUpdatePasswordRequest\x1a%.auth.v1.SystemUpdatePasswordResponse\x12T\n" +
"\x0fSystemUpdatePin\x12\x1f.auth.v1.SystemUpdatePinRequest\x1a .auth.v1.SystemUpdatePinResponseB*Z(git.lendry.ru/lendry-erp/proto.git/go;pbb\x06proto3"
"\x0fSystemUpdatePin\x12\x1f.auth.v1.SystemUpdatePinRequest\x1a .auth.v1.SystemUpdatePinResponse\x12N\n" +
"\rSystemBlockIp\x12\x1d.auth.v1.SystemBlockIpRequest\x1a\x1e.auth.v1.SystemBlockIpResponse\x12T\n" +
"\x0fSystemUnblockIp\x12\x1f.auth.v1.SystemUnblockIpRequest\x1a .auth.v1.SystemUnblockIpResponseB*Z(git.lendry.ru/lendry-erp/proto.git/go;pbb\x06proto3"
var (
file_sso_auth_proto_rawDescOnce sync.Once
@@ -1406,7 +1613,7 @@ func file_sso_auth_proto_rawDescGZIP() []byte {
return file_sso_auth_proto_rawDescData
}
var file_sso_auth_proto_msgTypes = make([]protoimpl.MessageInfo, 23)
var file_sso_auth_proto_msgTypes = make([]protoimpl.MessageInfo, 27)
var file_sso_auth_proto_goTypes = []any{
(*LoginRequest)(nil), // 0: auth.v1.LoginRequest
(*LoginResponse)(nil), // 1: auth.v1.LoginResponse
@@ -1431,6 +1638,10 @@ var file_sso_auth_proto_goTypes = []any{
(*SystemUpdatePasswordResponse)(nil), // 20: auth.v1.SystemUpdatePasswordResponse
(*SystemUpdatePinRequest)(nil), // 21: auth.v1.SystemUpdatePinRequest
(*SystemUpdatePinResponse)(nil), // 22: auth.v1.SystemUpdatePinResponse
(*SystemBlockIpRequest)(nil), // 23: auth.v1.SystemBlockIpRequest
(*SystemBlockIpResponse)(nil), // 24: auth.v1.SystemBlockIpResponse
(*SystemUnblockIpRequest)(nil), // 25: auth.v1.SystemUnblockIpRequest
(*SystemUnblockIpResponse)(nil), // 26: auth.v1.SystemUnblockIpResponse
}
var file_sso_auth_proto_depIdxs = []int32{
11, // 0: auth.v1.GetSessionsResponse.sessions:type_name -> auth.v1.SessionItem
@@ -1446,20 +1657,24 @@ var file_sso_auth_proto_depIdxs = []int32{
17, // 10: auth.v1.AuthService.SystemChangeStatus:input_type -> auth.v1.SystemChangeStatusRequest
19, // 11: auth.v1.AuthService.SystemUpdatePassword:input_type -> auth.v1.SystemUpdatePasswordRequest
21, // 12: auth.v1.AuthService.SystemUpdatePin:input_type -> auth.v1.SystemUpdatePinRequest
1, // 13: auth.v1.AuthService.Login:output_type -> auth.v1.LoginResponse
3, // 14: auth.v1.AuthService.Refresh:output_type -> auth.v1.RefreshResponse
7, // 15: auth.v1.AuthService.VerifyToken:output_type -> auth.v1.VerifyTokenResponse
9, // 16: auth.v1.AuthService.GetAccountRoleLevel:output_type -> auth.v1.GetAccountRoleLevelResponse
5, // 17: auth.v1.AuthService.Logout:output_type -> auth.v1.LogoutResponse
5, // 18: auth.v1.AuthService.LogoutOther:output_type -> auth.v1.LogoutResponse
12, // 19: auth.v1.AuthService.GetSessions:output_type -> auth.v1.GetSessionsResponse
14, // 20: auth.v1.AuthService.TerminateSession:output_type -> auth.v1.TerminateSessionResponse
16, // 21: auth.v1.AuthService.SystemCreateAccount:output_type -> auth.v1.SystemCreateAccountResponse
18, // 22: auth.v1.AuthService.SystemChangeStatus:output_type -> auth.v1.SystemChangeStatusResponse
20, // 23: auth.v1.AuthService.SystemUpdatePassword:output_type -> auth.v1.SystemUpdatePasswordResponse
22, // 24: auth.v1.AuthService.SystemUpdatePin:output_type -> auth.v1.SystemUpdatePinResponse
13, // [13:25] is the sub-list for method output_type
1, // [1:13] is the sub-list for method input_type
23, // 13: auth.v1.AuthService.SystemBlockIp:input_type -> auth.v1.SystemBlockIpRequest
25, // 14: auth.v1.AuthService.SystemUnblockIp:input_type -> auth.v1.SystemUnblockIpRequest
1, // 15: auth.v1.AuthService.Login:output_type -> auth.v1.LoginResponse
3, // 16: auth.v1.AuthService.Refresh:output_type -> auth.v1.RefreshResponse
7, // 17: auth.v1.AuthService.VerifyToken:output_type -> auth.v1.VerifyTokenResponse
9, // 18: auth.v1.AuthService.GetAccountRoleLevel:output_type -> auth.v1.GetAccountRoleLevelResponse
5, // 19: auth.v1.AuthService.Logout:output_type -> auth.v1.LogoutResponse
5, // 20: auth.v1.AuthService.LogoutOther:output_type -> auth.v1.LogoutResponse
12, // 21: auth.v1.AuthService.GetSessions:output_type -> auth.v1.GetSessionsResponse
14, // 22: auth.v1.AuthService.TerminateSession:output_type -> auth.v1.TerminateSessionResponse
16, // 23: auth.v1.AuthService.SystemCreateAccount:output_type -> auth.v1.SystemCreateAccountResponse
18, // 24: auth.v1.AuthService.SystemChangeStatus:output_type -> auth.v1.SystemChangeStatusResponse
20, // 25: auth.v1.AuthService.SystemUpdatePassword:output_type -> auth.v1.SystemUpdatePasswordResponse
22, // 26: auth.v1.AuthService.SystemUpdatePin:output_type -> auth.v1.SystemUpdatePinResponse
24, // 27: auth.v1.AuthService.SystemBlockIp:output_type -> auth.v1.SystemBlockIpResponse
26, // 28: auth.v1.AuthService.SystemUnblockIp:output_type -> auth.v1.SystemUnblockIpResponse
15, // [15:29] is the sub-list for method output_type
1, // [1:15] is the sub-list for method input_type
1, // [1:1] is the sub-list for extension type_name
1, // [1:1] is the sub-list for extension extendee
0, // [0:1] is the sub-list for field type_name
@@ -1473,13 +1688,14 @@ func file_sso_auth_proto_init() {
file_sso_auth_proto_msgTypes[1].OneofWrappers = []any{}
file_sso_auth_proto_msgTypes[7].OneofWrappers = []any{}
file_sso_auth_proto_msgTypes[21].OneofWrappers = []any{}
file_sso_auth_proto_msgTypes[23].OneofWrappers = []any{}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: unsafe.Slice(unsafe.StringData(file_sso_auth_proto_rawDesc), len(file_sso_auth_proto_rawDesc)),
NumEnums: 0,
NumMessages: 23,
NumMessages: 27,
NumExtensions: 0,
NumServices: 1,
},

View File

@@ -31,6 +31,8 @@ const (
AuthService_SystemChangeStatus_FullMethodName = "/auth.v1.AuthService/SystemChangeStatus"
AuthService_SystemUpdatePassword_FullMethodName = "/auth.v1.AuthService/SystemUpdatePassword"
AuthService_SystemUpdatePin_FullMethodName = "/auth.v1.AuthService/SystemUpdatePin"
AuthService_SystemBlockIp_FullMethodName = "/auth.v1.AuthService/SystemBlockIp"
AuthService_SystemUnblockIp_FullMethodName = "/auth.v1.AuthService/SystemUnblockIp"
)
// AuthServiceClient is the client API for AuthService service.
@@ -45,10 +47,13 @@ type AuthServiceClient interface {
LogoutOther(ctx context.Context, in *LogoutRequest, opts ...grpc.CallOption) (*LogoutResponse, error)
GetSessions(ctx context.Context, in *GetSessionRequest, opts ...grpc.CallOption) (*GetSessionsResponse, error)
TerminateSession(ctx context.Context, in *TerminateSessionRequest, opts ...grpc.CallOption) (*TerminateSessionResponse, error)
// Системные методы для админа
SystemCreateAccount(ctx context.Context, in *SystemCreateAccountRequest, opts ...grpc.CallOption) (*SystemCreateAccountResponse, error)
SystemChangeStatus(ctx context.Context, in *SystemChangeStatusRequest, opts ...grpc.CallOption) (*SystemChangeStatusResponse, error)
SystemUpdatePassword(ctx context.Context, in *SystemUpdatePasswordRequest, opts ...grpc.CallOption) (*SystemUpdatePasswordResponse, error)
SystemUpdatePin(ctx context.Context, in *SystemUpdatePinRequest, opts ...grpc.CallOption) (*SystemUpdatePinResponse, error)
SystemBlockIp(ctx context.Context, in *SystemBlockIpRequest, opts ...grpc.CallOption) (*SystemBlockIpResponse, error)
SystemUnblockIp(ctx context.Context, in *SystemUnblockIpRequest, opts ...grpc.CallOption) (*SystemUnblockIpResponse, error)
}
type authServiceClient struct {
@@ -179,6 +184,26 @@ func (c *authServiceClient) SystemUpdatePin(ctx context.Context, in *SystemUpdat
return out, nil
}
func (c *authServiceClient) SystemBlockIp(ctx context.Context, in *SystemBlockIpRequest, opts ...grpc.CallOption) (*SystemBlockIpResponse, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SystemBlockIpResponse)
err := c.cc.Invoke(ctx, AuthService_SystemBlockIp_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *authServiceClient) SystemUnblockIp(ctx context.Context, in *SystemUnblockIpRequest, opts ...grpc.CallOption) (*SystemUnblockIpResponse, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SystemUnblockIpResponse)
err := c.cc.Invoke(ctx, AuthService_SystemUnblockIp_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
// AuthServiceServer is the server API for AuthService service.
// All implementations must embed UnimplementedAuthServiceServer
// for forward compatibility.
@@ -191,10 +216,13 @@ type AuthServiceServer interface {
LogoutOther(context.Context, *LogoutRequest) (*LogoutResponse, error)
GetSessions(context.Context, *GetSessionRequest) (*GetSessionsResponse, error)
TerminateSession(context.Context, *TerminateSessionRequest) (*TerminateSessionResponse, error)
// Системные методы для админа
SystemCreateAccount(context.Context, *SystemCreateAccountRequest) (*SystemCreateAccountResponse, error)
SystemChangeStatus(context.Context, *SystemChangeStatusRequest) (*SystemChangeStatusResponse, error)
SystemUpdatePassword(context.Context, *SystemUpdatePasswordRequest) (*SystemUpdatePasswordResponse, error)
SystemUpdatePin(context.Context, *SystemUpdatePinRequest) (*SystemUpdatePinResponse, error)
SystemBlockIp(context.Context, *SystemBlockIpRequest) (*SystemBlockIpResponse, error)
SystemUnblockIp(context.Context, *SystemUnblockIpRequest) (*SystemUnblockIpResponse, error)
mustEmbedUnimplementedAuthServiceServer()
}
@@ -241,6 +269,12 @@ func (UnimplementedAuthServiceServer) SystemUpdatePassword(context.Context, *Sys
func (UnimplementedAuthServiceServer) SystemUpdatePin(context.Context, *SystemUpdatePinRequest) (*SystemUpdatePinResponse, error) {
return nil, status.Error(codes.Unimplemented, "method SystemUpdatePin not implemented")
}
func (UnimplementedAuthServiceServer) SystemBlockIp(context.Context, *SystemBlockIpRequest) (*SystemBlockIpResponse, error) {
return nil, status.Error(codes.Unimplemented, "method SystemBlockIp not implemented")
}
func (UnimplementedAuthServiceServer) SystemUnblockIp(context.Context, *SystemUnblockIpRequest) (*SystemUnblockIpResponse, error) {
return nil, status.Error(codes.Unimplemented, "method SystemUnblockIp not implemented")
}
func (UnimplementedAuthServiceServer) mustEmbedUnimplementedAuthServiceServer() {}
func (UnimplementedAuthServiceServer) testEmbeddedByValue() {}
@@ -478,6 +512,42 @@ func _AuthService_SystemUpdatePin_Handler(srv interface{}, ctx context.Context,
return interceptor(ctx, in, info, handler)
}
func _AuthService_SystemBlockIp_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SystemBlockIpRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(AuthServiceServer).SystemBlockIp(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: AuthService_SystemBlockIp_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(AuthServiceServer).SystemBlockIp(ctx, req.(*SystemBlockIpRequest))
}
return interceptor(ctx, in, info, handler)
}
func _AuthService_SystemUnblockIp_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SystemUnblockIpRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(AuthServiceServer).SystemUnblockIp(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: AuthService_SystemUnblockIp_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(AuthServiceServer).SystemUnblockIp(ctx, req.(*SystemUnblockIpRequest))
}
return interceptor(ctx, in, info, handler)
}
// AuthService_ServiceDesc is the grpc.ServiceDesc for AuthService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
@@ -533,6 +603,14 @@ var AuthService_ServiceDesc = grpc.ServiceDesc{
MethodName: "SystemUpdatePin",
Handler: _AuthService_SystemUpdatePin_Handler,
},
{
MethodName: "SystemBlockIp",
Handler: _AuthService_SystemBlockIp_Handler,
},
{
MethodName: "SystemUnblockIp",
Handler: _AuthService_SystemUnblockIp_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "sso/auth.proto",