Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CAClient ¶
type CAClient struct { GeneratedCerts [][]string // Cache the generated certificates for verification purpose. // contains filtered or unexported fields }
func NewMockCaClient ¶
NewMockCaClient create a CA client for CSR sign. The following function is adapted from istio NewMockCitadelClient (https://github.com/istio/istio/blob/1.20.0/security/pkg/nodeagent/caclient/providers/mock/mockcaclient.go)
func (*CAClient) CsrSend ¶
CsrSend send a grpc request to istio and sign a CSR. The following function is adapted from istio CSRSign (https://github.com/istio/istio/blob/1.20.0/security/pkg/nodeagent/caclient/providers/mock/mockcaclient.go)
func (*CAClient) FetchCert ¶
func (c *CAClient) FetchCert(identity string) (*security.SecretItem, error)
The following function is adapted from istio generateNewSecret (https://github.com/istio/istio/blob/master/security/pkg/nodeagent/cache/secretcache.go)
Click to show internal directories.
Click to hide internal directories.