server

package
v0.0.0-...-c63a931 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2022 License: AGPL-3.0 Imports: 24 Imported by: 0

Documentation

Overview

Copyright (C) 2022 Jake Sanders

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {

	// interfaces
	signv1connect.UnimplementedSignServiceHandler
	mgmtv1connect.UnimplementedManagementServiceHandler
	// contains filtered or unexported fields
}

func NewServer

func NewServer(options ...ServerOption) (*Server, error)

func (*Server) CreateSigner

func (s *Server) CreateSigner(ctx context.Context, req *connect.Request[mgmtv1.CreateSignerRequest]) (*connect.Response[emptypb.Empty], error)

func (*Server) DeleteSigner

func (s *Server) DeleteSigner(ctx context.Context, req *connect.Request[mgmtv1.DeleteSignerRequest]) (*connect.Response[emptypb.Empty], error)

func (*Server) GetSigner

func (s *Server) GetSigner(ctx context.Context, req *connect.Request[mgmtv1.GetSignerRequest]) (*connect.Response[mgmtv1.GetSignerResponse], error)

func (*Server) Init

func (s *Server) Init() error

func (*Server) ListSigners

func (s *Server) ListSigners(ctx context.Context, req *connect.Request[emptypb.Empty]) (*connect.Response[mgmtv1.ListSignersResponse], error)

func (*Server) Sign

func (s *Server) Sign(ctx context.Context, req *connect.Request[signv1.SignRequest]) (*connect.Response[signv1.SignResponse], error)

func (*Server) TrustBundle

func (s *Server) TrustBundle(ctx context.Context, req *connect.Request[signv1.TrustBundleRequest]) (*connect.Response[signv1.TrustBundleResponse], error)

type ServerOption

type ServerOption func(*Server) error

func WithDatastore

func WithDatastore(datastore string) ServerOption

func WithLogger

func WithLogger(logger *zap.Logger) ServerOption

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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