authzv1

package
v0.2.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 29, 2025 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_runtime_security_authz_v1_authz_proto protoreflect.FileDescriptor
View Source
var File_runtime_security_authz_v1_casbin_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type AuthZ

type AuthZ struct {
	Root      bool        `protobuf:"varint,1,opt,name=root,proto3" json:"root,omitempty"`
	Id        string      `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"`
	UserType  string      `protobuf:"bytes,3,opt,name=user_type,proto3" json:"user_type,omitempty"`
	Username  string      `protobuf:"bytes,4,opt,name=username,proto3" json:"username,omitempty"`
	Roles     []string    `protobuf:"bytes,5,rep,name=roles,proto3" json:"roles,omitempty"`
	Timestamp int64       `protobuf:"varint,6,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	Casbin    *CasbinAuth `protobuf:"bytes,7,opt,name=casbin,proto3" json:"casbin,omitempty"`
	// contains filtered or unexported fields
}

func (*AuthZ) Descriptor deprecated

func (*AuthZ) Descriptor() ([]byte, []int)

Deprecated: Use AuthZ.ProtoReflect.Descriptor instead.

func (*AuthZ) GetCasbin

func (x *AuthZ) GetCasbin() *CasbinAuth

func (*AuthZ) GetId

func (x *AuthZ) GetId() string

func (*AuthZ) GetRoles

func (x *AuthZ) GetRoles() []string

func (*AuthZ) GetRoot

func (x *AuthZ) GetRoot() bool

func (*AuthZ) GetTimestamp

func (x *AuthZ) GetTimestamp() int64

func (*AuthZ) GetUserType

func (x *AuthZ) GetUserType() string

func (*AuthZ) GetUsername

func (x *AuthZ) GetUsername() string

func (*AuthZ) ProtoMessage

func (*AuthZ) ProtoMessage()

func (*AuthZ) ProtoReflect

func (x *AuthZ) ProtoReflect() protoreflect.Message

func (*AuthZ) Reset

func (x *AuthZ) Reset()

func (*AuthZ) String

func (x *AuthZ) String() string

func (*AuthZ) Validate

func (m *AuthZ) Validate() error

Validate checks the field values on AuthZ with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*AuthZ) ValidateAll

func (m *AuthZ) ValidateAll() error

ValidateAll checks the field values on AuthZ with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in AuthZMultiError, or nil if none found.

type AuthZMultiError

type AuthZMultiError []error

AuthZMultiError is an error wrapping multiple validation errors returned by AuthZ.ValidateAll() if the designated constraints aren't met.

func (AuthZMultiError) AllErrors

func (m AuthZMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AuthZMultiError) Error

func (m AuthZMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type AuthZValidationError

type AuthZValidationError struct {
	// contains filtered or unexported fields
}

AuthZValidationError is the validation error returned by AuthZ.Validate if the designated constraints aren't met.

func (AuthZValidationError) Cause

func (e AuthZValidationError) Cause() error

Cause function returns cause value.

func (AuthZValidationError) Error

func (e AuthZValidationError) Error() string

Error satisfies the builtin error interface

func (AuthZValidationError) ErrorName

func (e AuthZValidationError) ErrorName() string

ErrorName returns error name.

func (AuthZValidationError) Field

func (e AuthZValidationError) Field() string

Field function returns field value.

func (AuthZValidationError) Key

func (e AuthZValidationError) Key() bool

Key function returns key value.

func (AuthZValidationError) Reason

func (e AuthZValidationError) Reason() string

Reason function returns reason value.

type CasbinAuth

type CasbinAuth struct {
	Policy *Policy    `protobuf:"bytes,1,opt,name=policy,proto3" json:"policy,omitempty"`
	Claims *v1.Claims `protobuf:"bytes,20,opt,name=claims,proto3" json:"claims,omitempty"` // Claims
	// contains filtered or unexported fields
}

func (*CasbinAuth) Descriptor deprecated

func (*CasbinAuth) Descriptor() ([]byte, []int)

Deprecated: Use CasbinAuth.ProtoReflect.Descriptor instead.

func (*CasbinAuth) GetClaims

func (x *CasbinAuth) GetClaims() *v1.Claims

func (*CasbinAuth) GetPolicy

func (x *CasbinAuth) GetPolicy() *Policy

func (*CasbinAuth) ProtoMessage

func (*CasbinAuth) ProtoMessage()

func (*CasbinAuth) ProtoReflect

func (x *CasbinAuth) ProtoReflect() protoreflect.Message

func (*CasbinAuth) Reset

func (x *CasbinAuth) Reset()

func (*CasbinAuth) String

func (x *CasbinAuth) String() string

func (*CasbinAuth) Validate

func (m *CasbinAuth) Validate() error

Validate checks the field values on CasbinAuth with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CasbinAuth) ValidateAll

func (m *CasbinAuth) ValidateAll() error

ValidateAll checks the field values on CasbinAuth with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CasbinAuthMultiError, or nil if none found.

type CasbinAuthMultiError

type CasbinAuthMultiError []error

CasbinAuthMultiError is an error wrapping multiple validation errors returned by CasbinAuth.ValidateAll() if the designated constraints aren't met.

func (CasbinAuthMultiError) AllErrors

func (m CasbinAuthMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CasbinAuthMultiError) Error

func (m CasbinAuthMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type CasbinAuthValidationError

type CasbinAuthValidationError struct {
	// contains filtered or unexported fields
}

CasbinAuthValidationError is the validation error returned by CasbinAuth.Validate if the designated constraints aren't met.

func (CasbinAuthValidationError) Cause

func (e CasbinAuthValidationError) Cause() error

Cause function returns cause value.

func (CasbinAuthValidationError) Error

Error satisfies the builtin error interface

func (CasbinAuthValidationError) ErrorName

func (e CasbinAuthValidationError) ErrorName() string

ErrorName returns error name.

func (CasbinAuthValidationError) Field

Field function returns field value.

func (CasbinAuthValidationError) Key

Key function returns key value.

func (CasbinAuthValidationError) Reason

func (e CasbinAuthValidationError) Reason() string

Reason function returns reason value.

type Policy

type Policy struct {
	Subject string            `protobuf:"bytes,1,opt,name=subject,proto3" json:"subject,omitempty"`
	Object  string            `protobuf:"bytes,2,opt,name=object,proto3" json:"object,omitempty"`
	Action  string            `protobuf:"bytes,3,opt,name=action,proto3" json:"action,omitempty"`
	Domain  []string          `protobuf:"bytes,4,rep,name=domain,proto3" json:"domain,omitempty"`
	Extras  map[string]string `` /* 139-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*Policy) Descriptor deprecated

func (*Policy) Descriptor() ([]byte, []int)

Deprecated: Use Policy.ProtoReflect.Descriptor instead.

func (*Policy) GetAction

func (x *Policy) GetAction() string

func (*Policy) GetDomain

func (x *Policy) GetDomain() []string

func (*Policy) GetExtras

func (x *Policy) GetExtras() map[string]string

func (*Policy) GetObject

func (x *Policy) GetObject() string

func (*Policy) GetSubject

func (x *Policy) GetSubject() string

func (*Policy) ProtoMessage

func (*Policy) ProtoMessage()

func (*Policy) ProtoReflect

func (x *Policy) ProtoReflect() protoreflect.Message

func (*Policy) Reset

func (x *Policy) Reset()

func (*Policy) String

func (x *Policy) String() string

func (*Policy) Validate

func (m *Policy) Validate() error

Validate checks the field values on Policy with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Policy) ValidateAll

func (m *Policy) ValidateAll() error

ValidateAll checks the field values on Policy with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in PolicyMultiError, or nil if none found.

type PolicyMultiError

type PolicyMultiError []error

PolicyMultiError is an error wrapping multiple validation errors returned by Policy.ValidateAll() if the designated constraints aren't met.

func (PolicyMultiError) AllErrors

func (m PolicyMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (PolicyMultiError) Error

func (m PolicyMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type PolicyValidationError

type PolicyValidationError struct {
	// contains filtered or unexported fields
}

PolicyValidationError is the validation error returned by Policy.Validate if the designated constraints aren't met.

func (PolicyValidationError) Cause

func (e PolicyValidationError) Cause() error

Cause function returns cause value.

func (PolicyValidationError) Error

func (e PolicyValidationError) Error() string

Error satisfies the builtin error interface

func (PolicyValidationError) ErrorName

func (e PolicyValidationError) ErrorName() string

ErrorName returns error name.

func (PolicyValidationError) Field

func (e PolicyValidationError) Field() string

Field function returns field value.

func (PolicyValidationError) Key

func (e PolicyValidationError) Key() bool

Key function returns key value.

func (PolicyValidationError) Reason

func (e PolicyValidationError) Reason() string

Reason function returns reason value.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL