authProto

package
Version: v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2018 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package authProto is a generated protocol buffer package.

It is generated from these files:

auth.proto
auth_types.proto

It has these top-level messages:

CreateTokenRequest
CreateTokenResponse
CheckTokenRequest
CheckTokenResponse
ExtendTokenRequest
ExtendTokenResponse
UpdateAccessRequestElement
UpdateAccessRequest
GetUserTokensRequest
GetUserTokensResponse
DeleteTokenRequest
DeleteUserTokensRequest
AccessTokenByIDRequest
AccessTokenByIDResponse
StoredToken
AccessObject
ResourcesAccess
StoredTokenForUser

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterAuthServer

func RegisterAuthServer(s *grpc.Server, srv AuthServer)

Types

type AccessObject

type AccessObject struct {
	Label string `protobuf:"bytes,1,opt,name=label" json:"label,omitempty"`
	// swagger:strfmt uuid
	// @inject_tag: binding:"uuid"
	Id     string `protobuf:"bytes,2,opt,name=id" json:"id,omitempty" binding:"uuid"`
	Access string `protobuf:"bytes,3,opt,name=access" json:"access,omitempty"`
}

AccessObject represents user access to resource

swagger:model

func (*AccessObject) Descriptor

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

func (*AccessObject) GetAccess

func (m *AccessObject) GetAccess() string

func (*AccessObject) GetId

func (m *AccessObject) GetId() string

func (*AccessObject) GetLabel

func (m *AccessObject) GetLabel() string

func (*AccessObject) ProtoMessage

func (*AccessObject) ProtoMessage()

func (*AccessObject) Reset

func (m *AccessObject) Reset()

func (*AccessObject) String

func (m *AccessObject) String() string

type AccessTokenByIDRequest

type AccessTokenByIDRequest struct {
	// @inject_tag: binding:"uuid"
	TokenId  string `protobuf:"bytes,1,opt,name=token_id,json=tokenId" json:"token_id,omitempty" binding:"uuid"`
	UserRole string `protobuf:"bytes,2,opt,name=user_role,json=userRole" json:"user_role,omitempty"`
}

swagger:ignore

func (*AccessTokenByIDRequest) Descriptor

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

func (*AccessTokenByIDRequest) GetTokenId

func (m *AccessTokenByIDRequest) GetTokenId() string

func (*AccessTokenByIDRequest) GetUserRole

func (m *AccessTokenByIDRequest) GetUserRole() string

func (*AccessTokenByIDRequest) ProtoMessage

func (*AccessTokenByIDRequest) ProtoMessage()

func (*AccessTokenByIDRequest) Reset

func (m *AccessTokenByIDRequest) Reset()

func (*AccessTokenByIDRequest) String

func (m *AccessTokenByIDRequest) String() string

type AccessTokenByIDResponse

type AccessTokenByIDResponse struct {
	AccessToken string `protobuf:"bytes,1,opt,name=access_token,json=accessToken" json:"access_token,omitempty"`
}

AccessTokenByIDResponse contains access token get by ID.

swagger:model

func (*AccessTokenByIDResponse) Descriptor

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

func (*AccessTokenByIDResponse) GetAccessToken

func (m *AccessTokenByIDResponse) GetAccessToken() string

func (*AccessTokenByIDResponse) ProtoMessage

func (*AccessTokenByIDResponse) ProtoMessage()

func (*AccessTokenByIDResponse) Reset

func (m *AccessTokenByIDResponse) Reset()

func (*AccessTokenByIDResponse) String

func (m *AccessTokenByIDResponse) String() string

type AuthClient

func NewAuthClient

func NewAuthClient(cc *grpc.ClientConn) AuthClient

type CheckTokenRequest

type CheckTokenRequest struct {
	AccessToken string `protobuf:"bytes,1,opt,name=access_token,json=accessToken" json:"access_token,omitempty"`
	UserAgent   string `protobuf:"bytes,2,opt,name=user_agent,json=userAgent" json:"user_agent,omitempty"`
	FingerPrint string `protobuf:"bytes,3,opt,name=finger_print,json=fingerPrint" json:"finger_print,omitempty"`
	// @inject_tag: binding:"ip"
	UserIp string `protobuf:"bytes,4,opt,name=user_ip,json=userIp" json:"user_ip,omitempty" binding:"ip"`
}

swagger:ignore

func (*CheckTokenRequest) Descriptor

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

func (*CheckTokenRequest) GetAccessToken

func (m *CheckTokenRequest) GetAccessToken() string

func (*CheckTokenRequest) GetFingerPrint

func (m *CheckTokenRequest) GetFingerPrint() string

func (*CheckTokenRequest) GetUserAgent

func (m *CheckTokenRequest) GetUserAgent() string

func (*CheckTokenRequest) GetUserIp

func (m *CheckTokenRequest) GetUserIp() string

func (*CheckTokenRequest) ProtoMessage

func (*CheckTokenRequest) ProtoMessage()

func (*CheckTokenRequest) Reset

func (m *CheckTokenRequest) Reset()

func (*CheckTokenRequest) String

func (m *CheckTokenRequest) String() string

type CheckTokenResponse

type CheckTokenResponse struct {
	Access *ResourcesAccess `protobuf:"bytes,1,opt,name=access" json:"access,omitempty"`
	// @inject_tag: binding:"uuid"
	UserId   string `protobuf:"bytes,2,opt,name=user_id,json=userId" json:"user_id,omitempty" binding:"uuid"`
	UserRole string `protobuf:"bytes,3,opt,name=user_role,json=userRole" json:"user_role,omitempty"`
	// @inject_tag: binding:"uuid"
	TokenId string `protobuf:"bytes,4,opt,name=token_id,json=tokenId" json:"token_id,omitempty" binding:"uuid"`
	// @inject_tag: binding:"omitempty,uuid"
	PartTokenId string `protobuf:"bytes,5,opt,name=part_token_id,json=partTokenId" json:"part_token_id,omitempty" binding:"omitempty,uuid"`
}

swagger:ignore

func (*CheckTokenResponse) Descriptor

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

func (*CheckTokenResponse) GetAccess

func (m *CheckTokenResponse) GetAccess() *ResourcesAccess

func (*CheckTokenResponse) GetPartTokenId

func (m *CheckTokenResponse) GetPartTokenId() string

func (*CheckTokenResponse) GetTokenId

func (m *CheckTokenResponse) GetTokenId() string

func (*CheckTokenResponse) GetUserId

func (m *CheckTokenResponse) GetUserId() string

func (*CheckTokenResponse) GetUserRole

func (m *CheckTokenResponse) GetUserRole() string

func (*CheckTokenResponse) ProtoMessage

func (*CheckTokenResponse) ProtoMessage()

func (*CheckTokenResponse) Reset

func (m *CheckTokenResponse) Reset()

func (*CheckTokenResponse) String

func (m *CheckTokenResponse) String() string

type CreateTokenRequest

type CreateTokenRequest struct {
	UserAgent   string `protobuf:"bytes,1,opt,name=user_agent,json=userAgent" json:"user_agent,omitempty"`
	Fingerprint string `protobuf:"bytes,2,opt,name=fingerprint" json:"fingerprint,omitempty"`
	// @inject_tag: binding:"uuid"
	UserId string `protobuf:"bytes,3,opt,name=user_id,json=userId" json:"user_id,omitempty" binding:"uuid"`
	// @inject_tag: binding:"ip"
	UserIp   string           `protobuf:"bytes,4,opt,name=user_ip,json=userIp" json:"user_ip,omitempty" binding:"ip"`
	UserRole string           `protobuf:"bytes,5,opt,name=user_role,json=userRole" json:"user_role,omitempty"`
	RwAccess bool             `protobuf:"varint,6,opt,name=rw_access,json=rwAccess" json:"rw_access,omitempty"`
	Access   *ResourcesAccess `protobuf:"bytes,7,opt,name=access" json:"access,omitempty"`
	// @inject_tag: binding:"omitempty,uuid"
	PartTokenId string `protobuf:"bytes,8,opt,name=part_token_id,json=partTokenId" json:"part_token_id,omitempty" binding:"omitempty,uuid"`
}

swagger:ignore

func (*CreateTokenRequest) Descriptor

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

func (*CreateTokenRequest) GetAccess

func (m *CreateTokenRequest) GetAccess() *ResourcesAccess

func (*CreateTokenRequest) GetFingerprint

func (m *CreateTokenRequest) GetFingerprint() string

func (*CreateTokenRequest) GetPartTokenId

func (m *CreateTokenRequest) GetPartTokenId() string

func (*CreateTokenRequest) GetRwAccess

func (m *CreateTokenRequest) GetRwAccess() bool

func (*CreateTokenRequest) GetUserAgent

func (m *CreateTokenRequest) GetUserAgent() string

func (*CreateTokenRequest) GetUserId

func (m *CreateTokenRequest) GetUserId() string

func (*CreateTokenRequest) GetUserIp

func (m *CreateTokenRequest) GetUserIp() string

func (*CreateTokenRequest) GetUserRole

func (m *CreateTokenRequest) GetUserRole() string

func (*CreateTokenRequest) ProtoMessage

func (*CreateTokenRequest) ProtoMessage()

func (*CreateTokenRequest) Reset

func (m *CreateTokenRequest) Reset()

func (*CreateTokenRequest) String

func (m *CreateTokenRequest) String() string

type CreateTokenResponse

type CreateTokenResponse struct {
	AccessToken  string `protobuf:"bytes,1,opt,name=access_token,json=accessToken" json:"access_token,omitempty"`
	RefreshToken string `protobuf:"bytes,2,opt,name=refresh_token,json=refreshToken" json:"refresh_token,omitempty"`
}

CreateTokenResponse contains access and refresh token.

swagger:model

func (*CreateTokenResponse) Descriptor

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

func (*CreateTokenResponse) GetAccessToken

func (m *CreateTokenResponse) GetAccessToken() string

func (*CreateTokenResponse) GetRefreshToken

func (m *CreateTokenResponse) GetRefreshToken() string

func (*CreateTokenResponse) ProtoMessage

func (*CreateTokenResponse) ProtoMessage()

func (*CreateTokenResponse) Reset

func (m *CreateTokenResponse) Reset()

func (*CreateTokenResponse) String

func (m *CreateTokenResponse) String() string

type DeleteTokenRequest

type DeleteTokenRequest struct {
	// @inject_tag: binding:"uuid"
	TokenId string `protobuf:"bytes,1,opt,name=token_id,json=tokenId" json:"token_id,omitempty" binding:"uuid"`
	// @inject_tag: binding:"uuid"
	UserId string `protobuf:"bytes,2,opt,name=user_id,json=userId" json:"user_id,omitempty" binding:"uuid"`
}

swagger:ignore

func (*DeleteTokenRequest) Descriptor

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

func (*DeleteTokenRequest) GetTokenId

func (m *DeleteTokenRequest) GetTokenId() string

func (*DeleteTokenRequest) GetUserId

func (m *DeleteTokenRequest) GetUserId() string

func (*DeleteTokenRequest) ProtoMessage

func (*DeleteTokenRequest) ProtoMessage()

func (*DeleteTokenRequest) Reset

func (m *DeleteTokenRequest) Reset()

func (*DeleteTokenRequest) String

func (m *DeleteTokenRequest) String() string

type DeleteUserTokensRequest

type DeleteUserTokensRequest struct {
	// @inject_tag: binding:"uuid"
	UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId" json:"user_id,omitempty" binding:"uuid"`
}

swagger:ignore

func (*DeleteUserTokensRequest) Descriptor

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

func (*DeleteUserTokensRequest) GetUserId

func (m *DeleteUserTokensRequest) GetUserId() string

func (*DeleteUserTokensRequest) ProtoMessage

func (*DeleteUserTokensRequest) ProtoMessage()

func (*DeleteUserTokensRequest) Reset

func (m *DeleteUserTokensRequest) Reset()

func (*DeleteUserTokensRequest) String

func (m *DeleteUserTokensRequest) String() string

type ExtendTokenRequest

type ExtendTokenRequest struct {
	RefreshToken string `protobuf:"bytes,1,opt,name=refresh_token,json=refreshToken" json:"refresh_token,omitempty"`
	Fingerprint  string `protobuf:"bytes,2,opt,name=fingerprint" json:"fingerprint,omitempty"`
}

swagger:ignore

func (*ExtendTokenRequest) Descriptor

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

func (*ExtendTokenRequest) GetFingerprint

func (m *ExtendTokenRequest) GetFingerprint() string

func (*ExtendTokenRequest) GetRefreshToken

func (m *ExtendTokenRequest) GetRefreshToken() string

func (*ExtendTokenRequest) ProtoMessage

func (*ExtendTokenRequest) ProtoMessage()

func (*ExtendTokenRequest) Reset

func (m *ExtendTokenRequest) Reset()

func (*ExtendTokenRequest) String

func (m *ExtendTokenRequest) String() string

type ExtendTokenResponse

type ExtendTokenResponse struct {
	AccessToken  string `protobuf:"bytes,1,opt,name=access_token,json=accessToken" json:"access_token,omitempty"`
	RefreshToken string `protobuf:"bytes,2,opt,name=refresh_token,json=refreshToken" json:"refresh_token,omitempty"`
}

ExtendTokenResponse contains new access and refresh tokens

swagger:model

func (*ExtendTokenResponse) Descriptor

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

func (*ExtendTokenResponse) GetAccessToken

func (m *ExtendTokenResponse) GetAccessToken() string

func (*ExtendTokenResponse) GetRefreshToken

func (m *ExtendTokenResponse) GetRefreshToken() string

func (*ExtendTokenResponse) ProtoMessage

func (*ExtendTokenResponse) ProtoMessage()

func (*ExtendTokenResponse) Reset

func (m *ExtendTokenResponse) Reset()

func (*ExtendTokenResponse) String

func (m *ExtendTokenResponse) String() string

type GetUserTokensRequest

type GetUserTokensRequest struct {
	// @inject_tag: binding:"uuid"
	UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId" json:"user_id,omitempty" binding:"uuid"`
}

swagger:ignore

func (*GetUserTokensRequest) Descriptor

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

func (*GetUserTokensRequest) GetUserId

func (m *GetUserTokensRequest) GetUserId() string

func (*GetUserTokensRequest) ProtoMessage

func (*GetUserTokensRequest) ProtoMessage()

func (*GetUserTokensRequest) Reset

func (m *GetUserTokensRequest) Reset()

func (*GetUserTokensRequest) String

func (m *GetUserTokensRequest) String() string

type GetUserTokensResponse

type GetUserTokensResponse struct {
	Tokens []*StoredTokenForUser `protobuf:"bytes,1,rep,name=tokens" json:"tokens,omitempty"`
}

GetUserTokensResponse contains user tokens

swagger:model

func (*GetUserTokensResponse) Descriptor

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

func (*GetUserTokensResponse) GetTokens

func (m *GetUserTokensResponse) GetTokens() []*StoredTokenForUser

func (*GetUserTokensResponse) ProtoMessage

func (*GetUserTokensResponse) ProtoMessage()

func (*GetUserTokensResponse) Reset

func (m *GetUserTokensResponse) Reset()

func (*GetUserTokensResponse) String

func (m *GetUserTokensResponse) String() string

type ResourcesAccess

type ResourcesAccess struct {
	Namespace []*AccessObject `protobuf:"bytes,1,rep,name=namespace" json:"namespace,omitempty"`
	Volume    []*AccessObject `protobuf:"bytes,2,rep,name=volume" json:"volume,omitempty"`
}

ResourceAccesses contains user accesses to resources

swagger:model

func (*ResourcesAccess) Descriptor

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

func (*ResourcesAccess) GetNamespace

func (m *ResourcesAccess) GetNamespace() []*AccessObject

func (*ResourcesAccess) GetVolume

func (m *ResourcesAccess) GetVolume() []*AccessObject

func (*ResourcesAccess) ProtoMessage

func (*ResourcesAccess) ProtoMessage()

func (*ResourcesAccess) Reset

func (m *ResourcesAccess) Reset()

func (*ResourcesAccess) String

func (m *ResourcesAccess) String() string

type StoredToken

type StoredToken struct {
	// swagger:strfmt uuid
	// @inject_tag: binding:"uuid"
	TokenId     string `protobuf:"bytes,1,opt,name=token_id,json=tokenId" json:"token_id,omitempty" binding:"uuid"`
	UserAgent   string `protobuf:"bytes,2,opt,name=user_agent,json=userAgent" json:"user_agent,omitempty"`
	Platform    string `protobuf:"bytes,3,opt,name=platform" json:"platform,omitempty"`
	Fingerprint string `protobuf:"bytes,4,opt,name=fingerprint" json:"fingerprint,omitempty"`
	// swagger:strfmt uuid
	// @inject_tag: binding:"uuid"
	UserId        string `protobuf:"bytes,5,opt,name=user_id,json=userId" json:"user_id,omitempty" binding:"uuid"`
	UserRole      string `protobuf:"bytes,6,opt,name=user_role,json=userRole" json:"user_role,omitempty"`
	UserNamespace string `protobuf:"bytes,7,opt,name=user_namespace,json=userNamespace" json:"user_namespace,omitempty"`
	UserVolume    string `protobuf:"bytes,8,opt,name=user_volume,json=userVolume" json:"user_volume,omitempty"`
	RwAccess      bool   `protobuf:"varint,9,opt,name=rw_access,json=rwAccess" json:"rw_access,omitempty"`
	// swagger:strfmt ip
	// @inject_tag: binding:"ip"
	UserIp string `protobuf:"bytes,10,opt,name=user_ip,json=userIp" json:"user_ip,omitempty" binding:"ip"`
	// swagger:strfmt uuid
	// @inject_tag: binding:"omitempty,uuid"
	PartTokenId     string                     `protobuf:"bytes,11,opt,name=part_token_id,json=partTokenId" json:"part_token_id,omitempty" binding:"omitempty,uuid"`
	CreatedAt       *google_protobuf.Timestamp `protobuf:"bytes,12,opt,name=created_at,json=createdAt" json:"created_at,omitempty"`
	LifeTime        *google_protobuf1.Duration `protobuf:"bytes,13,opt,name=life_time,json=lifeTime" json:"life_time,omitempty"`
	RawRefreshToken string                     `protobuf:"bytes,14,opt,name=raw_refresh_token,json=rawRefreshToken" json:"raw_refresh_token,omitempty"`
}

StoredToken is a representaion of token database record

swagger:model

func (*StoredToken) Descriptor

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

func (*StoredToken) GetCreatedAt

func (m *StoredToken) GetCreatedAt() *google_protobuf.Timestamp

func (*StoredToken) GetFingerprint

func (m *StoredToken) GetFingerprint() string

func (*StoredToken) GetLifeTime

func (m *StoredToken) GetLifeTime() *google_protobuf1.Duration

func (*StoredToken) GetPartTokenId

func (m *StoredToken) GetPartTokenId() string

func (*StoredToken) GetPlatform

func (m *StoredToken) GetPlatform() string

func (*StoredToken) GetRawRefreshToken

func (m *StoredToken) GetRawRefreshToken() string

func (*StoredToken) GetRwAccess

func (m *StoredToken) GetRwAccess() bool

func (*StoredToken) GetTokenId

func (m *StoredToken) GetTokenId() string

func (*StoredToken) GetUserAgent

func (m *StoredToken) GetUserAgent() string

func (*StoredToken) GetUserId

func (m *StoredToken) GetUserId() string

func (*StoredToken) GetUserIp

func (m *StoredToken) GetUserIp() string

func (*StoredToken) GetUserNamespace

func (m *StoredToken) GetUserNamespace() string

func (*StoredToken) GetUserRole

func (m *StoredToken) GetUserRole() string

func (*StoredToken) GetUserVolume

func (m *StoredToken) GetUserVolume() string

func (*StoredToken) ProtoMessage

func (*StoredToken) ProtoMessage()

func (*StoredToken) Reset

func (m *StoredToken) Reset()

func (*StoredToken) String

func (m *StoredToken) String() string

type StoredTokenForUser

type StoredTokenForUser struct {
	// @inject_tag: binding:"uuid"
	// swagger:strfmt uuid
	TokenId   string `protobuf:"bytes,1,opt,name=token_id,json=tokenId" json:"token_id,omitempty" binding:"uuid"`
	UserAgent string `protobuf:"bytes,2,opt,name=user_agent,json=userAgent" json:"user_agent,omitempty"`
	// @inject_tag: binding:"ip"
	// swagger:strfmt ip
	Ip        string `protobuf:"bytes,3,opt,name=ip" json:"ip,omitempty" binding:"ip"`
	CreatedAt string `protobuf:"bytes,4,opt,name=created_at,json=createdAt" json:"created_at,omitempty"`
}

StoredTokenForUser is an information about token sent to user

swagger:model

func (*StoredTokenForUser) Descriptor

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

func (*StoredTokenForUser) GetCreatedAt

func (m *StoredTokenForUser) GetCreatedAt() string

func (*StoredTokenForUser) GetIp

func (m *StoredTokenForUser) GetIp() string

func (*StoredTokenForUser) GetTokenId

func (m *StoredTokenForUser) GetTokenId() string

func (*StoredTokenForUser) GetUserAgent

func (m *StoredTokenForUser) GetUserAgent() string

func (*StoredTokenForUser) ProtoMessage

func (*StoredTokenForUser) ProtoMessage()

func (*StoredTokenForUser) Reset

func (m *StoredTokenForUser) Reset()

func (*StoredTokenForUser) String

func (m *StoredTokenForUser) String() string

type UpdateAccessRequest

type UpdateAccessRequest struct {
	Users []*UpdateAccessRequestElement `protobuf:"bytes,1,rep,name=users" json:"users,omitempty"`
}

UpdateAccessRequest describes request for updating user resources accesses.

swagger:model

func (*UpdateAccessRequest) Descriptor

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

func (*UpdateAccessRequest) GetUsers

func (*UpdateAccessRequest) ProtoMessage

func (*UpdateAccessRequest) ProtoMessage()

func (*UpdateAccessRequest) Reset

func (m *UpdateAccessRequest) Reset()

func (*UpdateAccessRequest) String

func (m *UpdateAccessRequest) String() string

type UpdateAccessRequestElement

type UpdateAccessRequestElement struct {
	// @inject_tag: binding:"uuid"
	UserId string           `protobuf:"bytes,1,opt,name=user_id,json=userId" json:"user_id,omitempty" binding:"uuid"`
	Access *ResourcesAccess `protobuf:"bytes,2,opt,name=access" json:"access,omitempty"`
}

UpdateAccessRequestElement describes element for updating user resources accesses.

swagger:model

func (*UpdateAccessRequestElement) Descriptor

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

func (*UpdateAccessRequestElement) GetAccess

func (*UpdateAccessRequestElement) GetUserId

func (m *UpdateAccessRequestElement) GetUserId() string

func (*UpdateAccessRequestElement) ProtoMessage

func (*UpdateAccessRequestElement) ProtoMessage()

func (*UpdateAccessRequestElement) Reset

func (m *UpdateAccessRequestElement) Reset()

func (*UpdateAccessRequestElement) String

func (m *UpdateAccessRequestElement) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL