istio: istio.io/istio/security/pkg/testing/sdsc Index | Files

package sdsc

import "istio.io/istio/security/pkg/testing/sdsc"

Package sdsc includes a lightweight testing client to interact with SDS.

Index

Package Files

sdsclient.go

func ValidateResponse Uses

func ValidateResponse(response *discovery.DiscoveryResponse) error

ValidateResponse validates the SDS response. TODO(incfly): add more check around cert.

type Client Uses

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

Client is a lightweight client for testing secret discovery service server.

func NewClient Uses

func NewClient(opt ClientOptions) (*Client, error)

NewClient returns a sds client for testing.

func (*Client) Send Uses

func (c *Client) Send() error

Send sends a request to the agent.

func (*Client) Start Uses

func (c *Client) Start()

Start starts sds client to receive the scecret updates from the server.

func (*Client) Stop Uses

func (c *Client) Stop() error

Stop stops the sds client.

func (*Client) WaitForUpdate Uses

func (c *Client) WaitForUpdate(duration time.Duration) (*discovery.DiscoveryResponse, error)

WaitForUpdate blocks until the error occurs or updates are pushed from the sds server.

type ClientOptions Uses

type ClientOptions struct {
    // unix://var/run/sds/, localhost:15000
    // https://github.com/grpc/grpc/blob/master/doc/naming.md#name-syntax
    ServerAddress string
}

ClientOptions contains the options for the SDS testing.

Package sdsc imports 15 packages (graph). Updated 2020-11-14. Refresh now. Tools for package owners.