auth

package
v0.0.0-...-695150b Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2020 License: Apache-2.0 Imports: 6 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterAuthorizationHandler

func RegisterAuthorizationHandler(s server.Server, hdlr AuthorizationHandler, opts ...server.HandlerOption) error

Types

type AuthRequest

type AuthRequest struct {
	SessionToken         string   `protobuf:"bytes,1,opt,name=sessionToken,proto3" json:"sessionToken,omitempty"`
	Privileges           []string `protobuf:"bytes,2,rep,name=privileges,proto3" json:"privileges,omitempty"`
	Oemprivileges        []string `protobuf:"bytes,3,rep,name=oemprivileges,proto3" json:"oemprivileges,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AuthRequest) Descriptor

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

func (*AuthRequest) GetOemprivileges

func (m *AuthRequest) GetOemprivileges() []string

func (*AuthRequest) GetPrivileges

func (m *AuthRequest) GetPrivileges() []string

func (*AuthRequest) GetSessionToken

func (m *AuthRequest) GetSessionToken() string

func (*AuthRequest) ProtoMessage

func (*AuthRequest) ProtoMessage()

func (*AuthRequest) Reset

func (m *AuthRequest) Reset()

func (*AuthRequest) String

func (m *AuthRequest) String() string

func (*AuthRequest) XXX_DiscardUnknown

func (m *AuthRequest) XXX_DiscardUnknown()

func (*AuthRequest) XXX_Marshal

func (m *AuthRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AuthRequest) XXX_Merge

func (m *AuthRequest) XXX_Merge(src proto.Message)

func (*AuthRequest) XXX_Size

func (m *AuthRequest) XXX_Size() int

func (*AuthRequest) XXX_Unmarshal

func (m *AuthRequest) XXX_Unmarshal(b []byte) error

type AuthResponse

type AuthResponse struct {
	StatusCode           int32    `protobuf:"varint,1,opt,name=statusCode,proto3" json:"statusCode,omitempty"`
	StatusMessage        string   `protobuf:"bytes,2,opt,name=statusMessage,proto3" json:"statusMessage,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AuthResponse) Descriptor

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

func (*AuthResponse) GetStatusCode

func (m *AuthResponse) GetStatusCode() int32

func (*AuthResponse) GetStatusMessage

func (m *AuthResponse) GetStatusMessage() string

func (*AuthResponse) ProtoMessage

func (*AuthResponse) ProtoMessage()

func (*AuthResponse) Reset

func (m *AuthResponse) Reset()

func (*AuthResponse) String

func (m *AuthResponse) String() string

func (*AuthResponse) XXX_DiscardUnknown

func (m *AuthResponse) XXX_DiscardUnknown()

func (*AuthResponse) XXX_Marshal

func (m *AuthResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AuthResponse) XXX_Merge

func (m *AuthResponse) XXX_Merge(src proto.Message)

func (*AuthResponse) XXX_Size

func (m *AuthResponse) XXX_Size() int

func (*AuthResponse) XXX_Unmarshal

func (m *AuthResponse) XXX_Unmarshal(b []byte) error

type AuthorizationHandler

type AuthorizationHandler interface {
	IsAuthorized(context.Context, *AuthRequest, *AuthResponse) error
}

type AuthorizationService

type AuthorizationService interface {
	IsAuthorized(ctx context.Context, in *AuthRequest, opts ...client.CallOption) (*AuthResponse, error)
}

func NewAuthorizationService

func NewAuthorizationService(name string, c client.Client) AuthorizationService

Jump to

Keyboard shortcuts

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