authnv1

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: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	AuthN_Type_name = map[int32]string{
		0: "TYPE_UNSPECIFIED",
		1: "TYPE_BASIC",
		2: "TYPE_BEARER",
		3: "TYPE_DIGEST",
		4: "TYPE_OAUTH2",
		5: "TYPE_API_KEY",
		6: "TYPE_JWT",
		7: "TYPE_USER_ADDITIONAL",
	}
	AuthN_Type_value = map[string]int32{
		"TYPE_UNSPECIFIED":     0,
		"TYPE_BASIC":           1,
		"TYPE_BEARER":          2,
		"TYPE_DIGEST":          3,
		"TYPE_OAUTH2":          4,
		"TYPE_API_KEY":         5,
		"TYPE_JWT":             6,
		"TYPE_USER_ADDITIONAL": 7,
	}
)

Enum value maps for AuthN_Type.

View Source
var File_runtime_security_authn_v1_authn_proto protoreflect.FileDescriptor
View Source
var File_runtime_security_authn_v1_jwt_proto protoreflect.FileDescriptor
View Source
var File_runtime_security_authn_v1_token_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type ApiKeyAuth

type ApiKeyAuth struct {
	ApiKey string `protobuf:"bytes,1,opt,name=api_key,proto3" json:"api_key,omitempty"`
	// contains filtered or unexported fields
}

func (*ApiKeyAuth) Descriptor deprecated

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

Deprecated: Use ApiKeyAuth.ProtoReflect.Descriptor instead.

func (*ApiKeyAuth) GetApiKey

func (x *ApiKeyAuth) GetApiKey() string

func (*ApiKeyAuth) ProtoMessage

func (*ApiKeyAuth) ProtoMessage()

func (*ApiKeyAuth) ProtoReflect

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

func (*ApiKeyAuth) Reset

func (x *ApiKeyAuth) Reset()

func (*ApiKeyAuth) String

func (x *ApiKeyAuth) String() string

func (*ApiKeyAuth) Validate

func (m *ApiKeyAuth) Validate() error

Validate checks the field values on ApiKeyAuth 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 (*ApiKeyAuth) ValidateAll

func (m *ApiKeyAuth) ValidateAll() error

ValidateAll checks the field values on ApiKeyAuth 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 ApiKeyAuthMultiError, or nil if none found.

type ApiKeyAuthMultiError

type ApiKeyAuthMultiError []error

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

func (ApiKeyAuthMultiError) AllErrors

func (m ApiKeyAuthMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ApiKeyAuthMultiError) Error

func (m ApiKeyAuthMultiError) Error() string

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

type ApiKeyAuthValidationError

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

ApiKeyAuthValidationError is the validation error returned by ApiKeyAuth.Validate if the designated constraints aren't met.

func (ApiKeyAuthValidationError) Cause

func (e ApiKeyAuthValidationError) Cause() error

Cause function returns cause value.

func (ApiKeyAuthValidationError) Error

Error satisfies the builtin error interface

func (ApiKeyAuthValidationError) ErrorName

func (e ApiKeyAuthValidationError) ErrorName() string

ErrorName returns error name.

func (ApiKeyAuthValidationError) Field

Field function returns field value.

func (ApiKeyAuthValidationError) Key

Key function returns key value.

func (ApiKeyAuthValidationError) Reason

func (e ApiKeyAuthValidationError) Reason() string

Reason function returns reason value.

type AuthN

type AuthN struct {
	Type       AuthN_Type  `protobuf:"varint,1,opt,name=type,proto3,enum=runtime.security.authn.v1.AuthN_Type" json:"type,omitempty"`
	Basic      *BasicAuth  `protobuf:"bytes,10,opt,name=basic,proto3,oneof" json:"basic,omitempty"`
	Bearer     *BearerAuth `protobuf:"bytes,11,opt,name=bearer,proto3,oneof" json:"bearer,omitempty"`
	Digest     *DigestAuth `protobuf:"bytes,12,opt,name=digest,proto3,oneof" json:"digest,omitempty"`
	Oauth2     *OAuth2Auth `protobuf:"bytes,13,opt,name=oauth2,proto3,oneof" json:"oauth2,omitempty"`
	ApiKey     *ApiKeyAuth `protobuf:"bytes,14,opt,name=api_key,proto3,oneof" json:"api_key,omitempty"`
	Jwt        *JwtAuth    `protobuf:"bytes,15,opt,name=jwt,proto3,oneof" json:"jwt,omitempty"`
	Additional []byte      `protobuf:"bytes,16,opt,name=additional,proto3,oneof" json:"additional,omitempty"`
	// contains filtered or unexported fields
}

func (*AuthN) Descriptor deprecated

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

Deprecated: Use AuthN.ProtoReflect.Descriptor instead.

func (*AuthN) GetAdditional

func (x *AuthN) GetAdditional() []byte

func (*AuthN) GetApiKey

func (x *AuthN) GetApiKey() *ApiKeyAuth

func (*AuthN) GetBasic

func (x *AuthN) GetBasic() *BasicAuth

func (*AuthN) GetBearer

func (x *AuthN) GetBearer() *BearerAuth

func (*AuthN) GetDigest

func (x *AuthN) GetDigest() *DigestAuth

func (*AuthN) GetJwt

func (x *AuthN) GetJwt() *JwtAuth

func (*AuthN) GetOauth2

func (x *AuthN) GetOauth2() *OAuth2Auth

func (*AuthN) GetType

func (x *AuthN) GetType() AuthN_Type

func (*AuthN) ProtoMessage

func (*AuthN) ProtoMessage()

func (*AuthN) ProtoReflect

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

func (*AuthN) Reset

func (x *AuthN) Reset()

func (*AuthN) String

func (x *AuthN) String() string

func (*AuthN) Validate

func (m *AuthN) Validate() error

Validate checks the field values on AuthN 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 (*AuthN) ValidateAll

func (m *AuthN) ValidateAll() error

ValidateAll checks the field values on AuthN 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 AuthNMultiError, or nil if none found.

type AuthNMultiError

type AuthNMultiError []error

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

func (AuthNMultiError) AllErrors

func (m AuthNMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AuthNMultiError) Error

func (m AuthNMultiError) Error() string

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

type AuthNValidationError

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

AuthNValidationError is the validation error returned by AuthN.Validate if the designated constraints aren't met.

func (AuthNValidationError) Cause

func (e AuthNValidationError) Cause() error

Cause function returns cause value.

func (AuthNValidationError) Error

func (e AuthNValidationError) Error() string

Error satisfies the builtin error interface

func (AuthNValidationError) ErrorName

func (e AuthNValidationError) ErrorName() string

ErrorName returns error name.

func (AuthNValidationError) Field

func (e AuthNValidationError) Field() string

Field function returns field value.

func (AuthNValidationError) Key

func (e AuthNValidationError) Key() bool

Key function returns key value.

func (AuthNValidationError) Reason

func (e AuthNValidationError) Reason() string

Reason function returns reason value.

type AuthN_Type

type AuthN_Type int32
const (
	AuthN_TYPE_UNSPECIFIED AuthN_Type = 0 // default value not specified
	AuthN_TYPE_BASIC       AuthN_Type = 1 // Basic authentication
	AuthN_TYPE_BEARER      AuthN_Type = 2 // Bearer authentication
	AuthN_TYPE_DIGEST      AuthN_Type = 3 // Digest authentication
	AuthN_TYPE_OAUTH2      AuthN_Type = 4 // OAuth2 authentication
	AuthN_TYPE_API_KEY     AuthN_Type = 5 // API Key authentication
	AuthN_TYPE_JWT         AuthN_Type = 6 // JWT authentication
	// you can add more types as needed
	AuthN_TYPE_USER_ADDITIONAL AuthN_Type = 7
)

func (AuthN_Type) Descriptor

func (AuthN_Type) Descriptor() protoreflect.EnumDescriptor

func (AuthN_Type) Enum

func (x AuthN_Type) Enum() *AuthN_Type

func (AuthN_Type) EnumDescriptor deprecated

func (AuthN_Type) EnumDescriptor() ([]byte, []int)

Deprecated: Use AuthN_Type.Descriptor instead.

func (AuthN_Type) Number

func (x AuthN_Type) Number() protoreflect.EnumNumber

func (AuthN_Type) String

func (x AuthN_Type) String() string

func (AuthN_Type) Type

type BasicAuth

type BasicAuth struct {
	Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
	Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"`
	// contains filtered or unexported fields
}

func (*BasicAuth) Descriptor deprecated

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

Deprecated: Use BasicAuth.ProtoReflect.Descriptor instead.

func (*BasicAuth) GetPassword

func (x *BasicAuth) GetPassword() string

func (*BasicAuth) GetUsername

func (x *BasicAuth) GetUsername() string

func (*BasicAuth) ProtoMessage

func (*BasicAuth) ProtoMessage()

func (*BasicAuth) ProtoReflect

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

func (*BasicAuth) Reset

func (x *BasicAuth) Reset()

func (*BasicAuth) String

func (x *BasicAuth) String() string

func (*BasicAuth) Validate

func (m *BasicAuth) Validate() error

Validate checks the field values on BasicAuth 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 (*BasicAuth) ValidateAll

func (m *BasicAuth) ValidateAll() error

ValidateAll checks the field values on BasicAuth 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 BasicAuthMultiError, or nil if none found.

type BasicAuthMultiError

type BasicAuthMultiError []error

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

func (BasicAuthMultiError) AllErrors

func (m BasicAuthMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (BasicAuthMultiError) Error

func (m BasicAuthMultiError) Error() string

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

type BasicAuthValidationError

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

BasicAuthValidationError is the validation error returned by BasicAuth.Validate if the designated constraints aren't met.

func (BasicAuthValidationError) Cause

func (e BasicAuthValidationError) Cause() error

Cause function returns cause value.

func (BasicAuthValidationError) Error

func (e BasicAuthValidationError) Error() string

Error satisfies the builtin error interface

func (BasicAuthValidationError) ErrorName

func (e BasicAuthValidationError) ErrorName() string

ErrorName returns error name.

func (BasicAuthValidationError) Field

func (e BasicAuthValidationError) Field() string

Field function returns field value.

func (BasicAuthValidationError) Key

Key function returns key value.

func (BasicAuthValidationError) Reason

func (e BasicAuthValidationError) Reason() string

Reason function returns reason value.

type BearerAuth

type BearerAuth struct {
	Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
	// contains filtered or unexported fields
}

func (*BearerAuth) Descriptor deprecated

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

Deprecated: Use BearerAuth.ProtoReflect.Descriptor instead.

func (*BearerAuth) GetToken

func (x *BearerAuth) GetToken() string

func (*BearerAuth) ProtoMessage

func (*BearerAuth) ProtoMessage()

func (*BearerAuth) ProtoReflect

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

func (*BearerAuth) Reset

func (x *BearerAuth) Reset()

func (*BearerAuth) String

func (x *BearerAuth) String() string

func (*BearerAuth) Validate

func (m *BearerAuth) Validate() error

Validate checks the field values on BearerAuth 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 (*BearerAuth) ValidateAll

func (m *BearerAuth) ValidateAll() error

ValidateAll checks the field values on BearerAuth 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 BearerAuthMultiError, or nil if none found.

type BearerAuthMultiError

type BearerAuthMultiError []error

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

func (BearerAuthMultiError) AllErrors

func (m BearerAuthMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (BearerAuthMultiError) Error

func (m BearerAuthMultiError) Error() string

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

type BearerAuthValidationError

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

BearerAuthValidationError is the validation error returned by BearerAuth.Validate if the designated constraints aren't met.

func (BearerAuthValidationError) Cause

func (e BearerAuthValidationError) Cause() error

Cause function returns cause value.

func (BearerAuthValidationError) Error

Error satisfies the builtin error interface

func (BearerAuthValidationError) ErrorName

func (e BearerAuthValidationError) ErrorName() string

ErrorName returns error name.

func (BearerAuthValidationError) Field

Field function returns field value.

func (BearerAuthValidationError) Key

Key function returns key value.

func (BearerAuthValidationError) Reason

func (e BearerAuthValidationError) Reason() string

Reason function returns reason value.

type Claims

type Claims struct {
	Sub    string          `protobuf:"bytes,1,opt,name=sub,proto3" json:"sub,omitempty"`  // Subject
	Iss    string          `protobuf:"bytes,2,opt,name=iss,proto3" json:"iss,omitempty"`  // Issuer
	Aud    []string        `protobuf:"bytes,3,rep,name=aud,proto3" json:"aud,omitempty"`  // Audience
	Exp    int64           `protobuf:"varint,4,opt,name=exp,proto3" json:"exp,omitempty"` // Expiration Time
	Nbf    int64           `protobuf:"varint,5,opt,name=nbf,proto3" json:"nbf,omitempty"` // Not Before
	Iat    int64           `protobuf:"varint,6,opt,name=iat,proto3" json:"iat,omitempty"` // Issued At
	Jti    string          `protobuf:"bytes,7,opt,name=jti,proto3" json:"jti,omitempty"`  // JWT ID
	Scopes map[string]bool ``                                                             // Scopes
	/* 140-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*Claims) Descriptor deprecated

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

Deprecated: Use Claims.ProtoReflect.Descriptor instead.

func (*Claims) GetAud

func (x *Claims) GetAud() []string

func (*Claims) GetExp

func (x *Claims) GetExp() int64

func (*Claims) GetIat

func (x *Claims) GetIat() int64

func (*Claims) GetIss

func (x *Claims) GetIss() string

func (*Claims) GetJti

func (x *Claims) GetJti() string

func (*Claims) GetNbf

func (x *Claims) GetNbf() int64

func (*Claims) GetScopes

func (x *Claims) GetScopes() map[string]bool

func (*Claims) GetSub

func (x *Claims) GetSub() string

func (*Claims) ProtoMessage

func (*Claims) ProtoMessage()

func (*Claims) ProtoReflect

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

func (*Claims) Reset

func (x *Claims) Reset()

func (*Claims) String

func (x *Claims) String() string

func (*Claims) Validate

func (m *Claims) Validate() error

Validate checks the field values on Claims 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 (*Claims) ValidateAll

func (m *Claims) ValidateAll() error

ValidateAll checks the field values on Claims 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 ClaimsMultiError, or nil if none found.

type ClaimsMultiError

type ClaimsMultiError []error

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

func (ClaimsMultiError) AllErrors

func (m ClaimsMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ClaimsMultiError) Error

func (m ClaimsMultiError) Error() string

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

type ClaimsValidationError

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

ClaimsValidationError is the validation error returned by Claims.Validate if the designated constraints aren't met.

func (ClaimsValidationError) Cause

func (e ClaimsValidationError) Cause() error

Cause function returns cause value.

func (ClaimsValidationError) Error

func (e ClaimsValidationError) Error() string

Error satisfies the builtin error interface

func (ClaimsValidationError) ErrorName

func (e ClaimsValidationError) ErrorName() string

ErrorName returns error name.

func (ClaimsValidationError) Field

func (e ClaimsValidationError) Field() string

Field function returns field value.

func (ClaimsValidationError) Key

func (e ClaimsValidationError) Key() bool

Key function returns key value.

func (ClaimsValidationError) Reason

func (e ClaimsValidationError) Reason() string

Reason function returns reason value.

type Config

type Config struct {
	SigningMethod        string   `protobuf:"bytes,1,opt,name=signing_method,proto3" json:"signing_method,omitempty"`
	Key                  string   `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
	Key2                 string   `protobuf:"bytes,3,opt,name=key2,proto3" json:"key2,omitempty"`
	AccessTokenLifetime  int64    `protobuf:"varint,5,opt,name=access_token_lifetime,proto3" json:"access_token_lifetime,omitempty"`
	RefreshTokenLifetime int64    `protobuf:"varint,6,opt,name=refresh_token_lifetime,proto3" json:"refresh_token_lifetime,omitempty"`
	Issuer               string   `protobuf:"bytes,7,opt,name=issuer,proto3" json:"issuer,omitempty"`
	Audience             []string `protobuf:"bytes,8,rep,name=audience,proto3" json:"audience,omitempty"` // Audience
	TokenType            string   `protobuf:"bytes,9,opt,name=token_type,proto3" json:"token_type,omitempty"`
	// contains filtered or unexported fields
}

Config contains configuration parameters for creating and validating a JWT.

func (*Config) Descriptor deprecated

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

Deprecated: Use Config.ProtoReflect.Descriptor instead.

func (*Config) GetAccessTokenLifetime

func (x *Config) GetAccessTokenLifetime() int64

func (*Config) GetAudience

func (x *Config) GetAudience() []string

func (*Config) GetIssuer

func (x *Config) GetIssuer() string

func (*Config) GetKey

func (x *Config) GetKey() string

func (*Config) GetKey2

func (x *Config) GetKey2() string

func (*Config) GetRefreshTokenLifetime

func (x *Config) GetRefreshTokenLifetime() int64

func (*Config) GetSigningMethod

func (x *Config) GetSigningMethod() string

func (*Config) GetTokenType

func (x *Config) GetTokenType() string

func (*Config) ProtoMessage

func (*Config) ProtoMessage()

func (*Config) ProtoReflect

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

func (*Config) Reset

func (x *Config) Reset()

func (*Config) String

func (x *Config) String() string

func (*Config) Validate

func (m *Config) Validate() error

Validate checks the field values on Config 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 (*Config) ValidateAll

func (m *Config) ValidateAll() error

ValidateAll checks the field values on Config 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 ConfigMultiError, or nil if none found.

type ConfigMultiError

type ConfigMultiError []error

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

func (ConfigMultiError) AllErrors

func (m ConfigMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (ConfigMultiError) Error

func (m ConfigMultiError) Error() string

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

type ConfigValidationError

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

ConfigValidationError is the validation error returned by Config.Validate if the designated constraints aren't met.

func (ConfigValidationError) Cause

func (e ConfigValidationError) Cause() error

Cause function returns cause value.

func (ConfigValidationError) Error

func (e ConfigValidationError) Error() string

Error satisfies the builtin error interface

func (ConfigValidationError) ErrorName

func (e ConfigValidationError) ErrorName() string

ErrorName returns error name.

func (ConfigValidationError) Field

func (e ConfigValidationError) Field() string

Field function returns field value.

func (ConfigValidationError) Key

func (e ConfigValidationError) Key() bool

Key function returns key value.

func (ConfigValidationError) Reason

func (e ConfigValidationError) Reason() string

Reason function returns reason value.

type DigestAuth

type DigestAuth struct {
	Username  string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
	Realm     string `protobuf:"bytes,2,opt,name=realm,proto3" json:"realm,omitempty"`
	Nonce     string `protobuf:"bytes,3,opt,name=nonce,proto3" json:"nonce,omitempty"`
	Uri       string `protobuf:"bytes,4,opt,name=uri,proto3" json:"uri,omitempty"`
	Response  string `protobuf:"bytes,5,opt,name=response,proto3" json:"response,omitempty"`
	Algorithm string `protobuf:"bytes,6,opt,name=algorithm,proto3" json:"algorithm,omitempty"`
	Qop       string `protobuf:"bytes,7,opt,name=qop,proto3" json:"qop,omitempty"`
	Nc        string `protobuf:"bytes,8,opt,name=nc,proto3" json:"nc,omitempty"`
	Cnonce    string `protobuf:"bytes,9,opt,name=cnonce,proto3" json:"cnonce,omitempty"`
	// contains filtered or unexported fields
}

func (*DigestAuth) Descriptor deprecated

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

Deprecated: Use DigestAuth.ProtoReflect.Descriptor instead.

func (*DigestAuth) GetAlgorithm

func (x *DigestAuth) GetAlgorithm() string

func (*DigestAuth) GetCnonce

func (x *DigestAuth) GetCnonce() string

func (*DigestAuth) GetNc

func (x *DigestAuth) GetNc() string

func (*DigestAuth) GetNonce

func (x *DigestAuth) GetNonce() string

func (*DigestAuth) GetQop

func (x *DigestAuth) GetQop() string

func (*DigestAuth) GetRealm

func (x *DigestAuth) GetRealm() string

func (*DigestAuth) GetResponse

func (x *DigestAuth) GetResponse() string

func (*DigestAuth) GetUri

func (x *DigestAuth) GetUri() string

func (*DigestAuth) GetUsername

func (x *DigestAuth) GetUsername() string

func (*DigestAuth) ProtoMessage

func (*DigestAuth) ProtoMessage()

func (*DigestAuth) ProtoReflect

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

func (*DigestAuth) Reset

func (x *DigestAuth) Reset()

func (*DigestAuth) String

func (x *DigestAuth) String() string

func (*DigestAuth) Validate

func (m *DigestAuth) Validate() error

Validate checks the field values on DigestAuth 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 (*DigestAuth) ValidateAll

func (m *DigestAuth) ValidateAll() error

ValidateAll checks the field values on DigestAuth 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 DigestAuthMultiError, or nil if none found.

type DigestAuthMultiError

type DigestAuthMultiError []error

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

func (DigestAuthMultiError) AllErrors

func (m DigestAuthMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DigestAuthMultiError) Error

func (m DigestAuthMultiError) Error() string

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

type DigestAuthValidationError

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

DigestAuthValidationError is the validation error returned by DigestAuth.Validate if the designated constraints aren't met.

func (DigestAuthValidationError) Cause

func (e DigestAuthValidationError) Cause() error

Cause function returns cause value.

func (DigestAuthValidationError) Error

Error satisfies the builtin error interface

func (DigestAuthValidationError) ErrorName

func (e DigestAuthValidationError) ErrorName() string

ErrorName returns error name.

func (DigestAuthValidationError) Field

Field function returns field value.

func (DigestAuthValidationError) Key

Key function returns key value.

func (DigestAuthValidationError) Reason

func (e DigestAuthValidationError) Reason() string

Reason function returns reason value.

type JwtAuth

type JwtAuth struct {
	Token    string  `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"`
	JwtToken *Token  `protobuf:"bytes,2,opt,name=jwt_token,proto3" json:"jwt_token,omitempty"`
	Claims   *Claims `protobuf:"bytes,20,opt,name=claims,proto3" json:"claims,omitempty"` // Claims
	// contains filtered or unexported fields
}

func (*JwtAuth) Descriptor deprecated

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

Deprecated: Use JwtAuth.ProtoReflect.Descriptor instead.

func (*JwtAuth) GetClaims

func (x *JwtAuth) GetClaims() *Claims

func (*JwtAuth) GetJwtToken

func (x *JwtAuth) GetJwtToken() *Token

func (*JwtAuth) GetToken

func (x *JwtAuth) GetToken() string

func (*JwtAuth) ProtoMessage

func (*JwtAuth) ProtoMessage()

func (*JwtAuth) ProtoReflect

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

func (*JwtAuth) Reset

func (x *JwtAuth) Reset()

func (*JwtAuth) String

func (x *JwtAuth) String() string

func (*JwtAuth) Validate

func (m *JwtAuth) Validate() error

Validate checks the field values on JwtAuth 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 (*JwtAuth) ValidateAll

func (m *JwtAuth) ValidateAll() error

ValidateAll checks the field values on JwtAuth 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 JwtAuthMultiError, or nil if none found.

type JwtAuthMultiError

type JwtAuthMultiError []error

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

func (JwtAuthMultiError) AllErrors

func (m JwtAuthMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (JwtAuthMultiError) Error

func (m JwtAuthMultiError) Error() string

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

type JwtAuthValidationError

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

JwtAuthValidationError is the validation error returned by JwtAuth.Validate if the designated constraints aren't met.

func (JwtAuthValidationError) Cause

func (e JwtAuthValidationError) Cause() error

Cause function returns cause value.

func (JwtAuthValidationError) Error

func (e JwtAuthValidationError) Error() string

Error satisfies the builtin error interface

func (JwtAuthValidationError) ErrorName

func (e JwtAuthValidationError) ErrorName() string

ErrorName returns error name.

func (JwtAuthValidationError) Field

func (e JwtAuthValidationError) Field() string

Field function returns field value.

func (JwtAuthValidationError) Key

func (e JwtAuthValidationError) Key() bool

Key function returns key value.

func (JwtAuthValidationError) Reason

func (e JwtAuthValidationError) Reason() string

Reason function returns reason value.

type OAuth2Auth

type OAuth2Auth struct {
	AccessToken  string   `protobuf:"bytes,1,opt,name=access_token,proto3" json:"access_token,omitempty"`
	TokenType    string   `protobuf:"bytes,2,opt,name=token_type,proto3" json:"token_type,omitempty"`
	ExpiresIn    int32    `protobuf:"varint,3,opt,name=expires_in,proto3" json:"expires_in,omitempty"`
	RefreshToken string   `protobuf:"bytes,4,opt,name=refresh_token,proto3" json:"refresh_token,omitempty"`
	Scope        []string `protobuf:"bytes,5,rep,name=scope,proto3" json:"scope,omitempty"`
	// contains filtered or unexported fields
}

func (*OAuth2Auth) Descriptor deprecated

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

Deprecated: Use OAuth2Auth.ProtoReflect.Descriptor instead.

func (*OAuth2Auth) GetAccessToken

func (x *OAuth2Auth) GetAccessToken() string

func (*OAuth2Auth) GetExpiresIn

func (x *OAuth2Auth) GetExpiresIn() int32

func (*OAuth2Auth) GetRefreshToken

func (x *OAuth2Auth) GetRefreshToken() string

func (*OAuth2Auth) GetScope

func (x *OAuth2Auth) GetScope() []string

func (*OAuth2Auth) GetTokenType

func (x *OAuth2Auth) GetTokenType() string

func (*OAuth2Auth) ProtoMessage

func (*OAuth2Auth) ProtoMessage()

func (*OAuth2Auth) ProtoReflect

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

func (*OAuth2Auth) Reset

func (x *OAuth2Auth) Reset()

func (*OAuth2Auth) String

func (x *OAuth2Auth) String() string

func (*OAuth2Auth) Validate

func (m *OAuth2Auth) Validate() error

Validate checks the field values on OAuth2Auth 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 (*OAuth2Auth) ValidateAll

func (m *OAuth2Auth) ValidateAll() error

ValidateAll checks the field values on OAuth2Auth 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 OAuth2AuthMultiError, or nil if none found.

type OAuth2AuthMultiError

type OAuth2AuthMultiError []error

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

func (OAuth2AuthMultiError) AllErrors

func (m OAuth2AuthMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (OAuth2AuthMultiError) Error

func (m OAuth2AuthMultiError) Error() string

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

type OAuth2AuthValidationError

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

OAuth2AuthValidationError is the validation error returned by OAuth2Auth.Validate if the designated constraints aren't met.

func (OAuth2AuthValidationError) Cause

func (e OAuth2AuthValidationError) Cause() error

Cause function returns cause value.

func (OAuth2AuthValidationError) Error

Error satisfies the builtin error interface

func (OAuth2AuthValidationError) ErrorName

func (e OAuth2AuthValidationError) ErrorName() string

ErrorName returns error name.

func (OAuth2AuthValidationError) Field

Field function returns field value.

func (OAuth2AuthValidationError) Key

Key function returns key value.

func (OAuth2AuthValidationError) Reason

func (e OAuth2AuthValidationError) Reason() string

Reason function returns reason value.

type Token

type Token struct {
	ClientId       string `protobuf:"bytes,1,opt,name=client_id,proto3" json:"client_id,omitempty"`
	UserId         string `protobuf:"bytes,2,opt,name=user_id,proto3" json:"user_id,omitempty"`
	AccessToken    string `protobuf:"bytes,10,opt,name=access_token,proto3" json:"access_token,omitempty"`
	RefreshToken   string `protobuf:"bytes,11,opt,name=refresh_token,proto3" json:"refresh_token,omitempty"`
	ExpirationTime int64  `protobuf:"varint,12,opt,name=expiration_time,proto3" json:"expiration_time,omitempty"`
	// contains filtered or unexported fields
}

PWT is a web token that can be used to authenticate a user with protobuf services.

func (*Token) Descriptor deprecated

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

Deprecated: Use Token.ProtoReflect.Descriptor instead.

func (*Token) GetAccessToken

func (x *Token) GetAccessToken() string

func (*Token) GetClientId

func (x *Token) GetClientId() string

func (*Token) GetExpirationTime

func (x *Token) GetExpirationTime() int64

func (*Token) GetRefreshToken

func (x *Token) GetRefreshToken() string

func (*Token) GetUserId

func (x *Token) GetUserId() string

func (*Token) ProtoMessage

func (*Token) ProtoMessage()

func (*Token) ProtoReflect

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

func (*Token) Reset

func (x *Token) Reset()

func (*Token) String

func (x *Token) String() string

func (*Token) Validate

func (m *Token) Validate() error

Validate checks the field values on Token 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 (*Token) ValidateAll

func (m *Token) ValidateAll() error

ValidateAll checks the field values on Token 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 TokenMultiError, or nil if none found.

type TokenMultiError

type TokenMultiError []error

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

func (TokenMultiError) AllErrors

func (m TokenMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TokenMultiError) Error

func (m TokenMultiError) Error() string

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

type TokenValidationError

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

TokenValidationError is the validation error returned by Token.Validate if the designated constraints aren't met.

func (TokenValidationError) Cause

func (e TokenValidationError) Cause() error

Cause function returns cause value.

func (TokenValidationError) Error

func (e TokenValidationError) Error() string

Error satisfies the builtin error interface

func (TokenValidationError) ErrorName

func (e TokenValidationError) ErrorName() string

ErrorName returns error name.

func (TokenValidationError) Field

func (e TokenValidationError) Field() string

Field function returns field value.

func (TokenValidationError) Key

func (e TokenValidationError) Key() bool

Key function returns key value.

func (TokenValidationError) Reason

func (e TokenValidationError) 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