Documentation
¶
Overview ¶
Package trustmapping provides the service.module.grpc.trustmapping module: a gRPC service module that registers the kms.api.cmk.sessionmanager.trustmapping.v1.Service proto onto a grpc.ServiceRegistrar supplied by app.module.grpcserver.
Index ¶
- type Module
- type Server
- func (srv *Server) ApplyTrustMapping(ctx context.Context, in *trustmappingv1.ApplyTrustMappingRequest) (*trustmappingv1.ApplyTrustMappingResponse, error)
- func (srv *Server) BlockTrustMapping(ctx context.Context, req *trustmappingv1.BlockTrustMappingRequest) (*trustmappingv1.BlockTrustMappingResponse, error)
- func (srv *Server) RemoveTrustMapping(ctx context.Context, req *trustmappingv1.RemoveTrustMappingRequest) (*trustmappingv1.RemoveTrustMappingResponse, error)
- func (srv *Server) UnblockTrustMapping(ctx context.Context, req *trustmappingv1.UnblockTrustMappingRequest) (*trustmappingv1.UnblockTrustMappingResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Module ¶
type Module struct {
Mod string `yaml:"module"`
Trust string `yaml:"trust" default:"trust.module.oidc" dep:"sessionmanager.Trust"`
// contains filtered or unexported fields
}
Module is the service.module.grpc.trustmapping module. It owns a Server that implements the trustmapping proto and resolves its single dependency (a sessionmanager.Trust implementation) by ID via ctx.GetModule.
func (*Module) Module ¶
func (m *Module) Module() sessionmanager.ModuleInfo
func (*Module) Register ¶
func (m *Module) Register(s grpc.ServiceRegistrar)
type Server ¶
type Server struct {
trustmappingv1.UnimplementedServiceServer
// contains filtered or unexported fields
}
func NewServer ¶
func NewServer(trust sessionmanager.Trust) *Server
func (*Server) ApplyTrustMapping ¶
func (srv *Server) ApplyTrustMapping(ctx context.Context, in *trustmappingv1.ApplyTrustMappingRequest) (*trustmappingv1.ApplyTrustMappingResponse, error)
func (*Server) BlockTrustMapping ¶
func (srv *Server) BlockTrustMapping(ctx context.Context, req *trustmappingv1.BlockTrustMappingRequest) (*trustmappingv1.BlockTrustMappingResponse, error)
BlockTrustMapping blocks the trust for the specified tenant. It calls the underlying service to set the trust as blocked. Returns a response containing an optional error message if blocking fails.
func (*Server) RemoveTrustMapping ¶
func (srv *Server) RemoveTrustMapping(ctx context.Context, req *trustmappingv1.RemoveTrustMappingRequest) (*trustmappingv1.RemoveTrustMappingResponse, error)
RemoveTrustMapping removes the trust configuration for the tenant. It calls the underlying service to remove the trust. Returns a respose containing an optional error message if removing fails.
func (*Server) UnblockTrustMapping ¶
func (srv *Server) UnblockTrustMapping(ctx context.Context, req *trustmappingv1.UnblockTrustMappingRequest) (*trustmappingv1.UnblockTrustMappingResponse, error)
UnblockTrustMapping unblocks the trust for the specified tenant. It calls the underlying service to set the trust as unblocked. Returns a response containing an optional error message if unblocking fails.