package fakebundleendpoint

import "github.com/spiffe/go-spiffe/v2/internal/test/fakebundleendpoint"

Index

Types

type Server

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

func New

func New(tb testing.TB, option ...ServerOption) *Server

func (*Server) Addr

func (s *Server) Addr() string

func (*Server) FetchBundleURL

func (s *Server) FetchBundleURL() string

func (*Server) RootCAs

func (s *Server) RootCAs() *x509.CertPool

func (*Server) Shutdown

func (s *Server) Shutdown()

type ServerOption

type ServerOption interface {
	// contains filtered or unexported methods
}

func WithSPIFFEAuth

func WithSPIFFEAuth(bundle *spiffebundle.Bundle, svid *x509svid.SVID) ServerOption

func WithTestBundles

func WithTestBundles(bundles ...*spiffebundle.Bundle) ServerOption

WithTestBundles sets the bundles that are returned by the Bundle Endpoint. You can specify several bundles, which are going to be returned one at a time each time a bundle is GET by a client.

Source Files

server.go

Version
v2.5.0 (latest)
Published
Jan 31, 2025
Platform
linux/amd64
Imports
15 packages
Last checked
2 months ago

Tools for package owners.