Documentation
¶
Index ¶
- Constants
- func GetRekorClient(rekorServerURL string, opts ...Option) (*client.Rekor, error)
- type Option
- func WithHeaders(h map[string][]string) Option
- func WithInsecureTLS(enabled bool) Option
- func WithLogger(l any) Option
- func WithNoDisableKeepalives(noDisableKeepalives bool) Option
- func WithRetryCount(retryCount uint) Option
- func WithRetryWaitMax(t time.Duration) Option
- func WithRetryWaitMin(t time.Duration) Option
- func WithTLSConfig(tlsConfig *tls.Config) Option
- func WithUserAgent(userAgent string) Option
Constants ¶
const ( // DefaultRetryCount is the default number of retries. DefaultRetryCount = 3 // DefaultRetryWaitMin is the default minimum wait time between retries. DefaultRetryWaitMin = httpretry.DefaultWaitMin // DefaultRetryWaitMax is the default maximum wait time between retries. DefaultRetryWaitMax = httpretry.DefaultWaitMax )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Option ¶ added in v0.4.0
type Option func(*options)
Option is a functional option for customizing static signatures.
func WithHeaders ¶ added in v1.3.7
WithHeaders sets default headers for every client request.
func WithInsecureTLS ¶ added in v1.1.0
WithInsecureTLS disables TLS verification.
func WithLogger ¶ added in v1.0.0
WithLogger sets the logger; it must implement either a simple logger interface with a `Printf(string, ...any)` method, or a leveled logger interface with `Error`, `Info`, `Debug`, and `Warn` methods that take a message string and variadic `keysAndValues`.
func WithNoDisableKeepalives ¶ added in v1.3.7
WithNoDisableKeepalives unsets the default DisableKeepalives setting.
func WithRetryCount ¶ added in v1.0.0
WithRetryCount sets the number of retries.
func WithRetryWaitMax ¶ added in v1.3.7
WithRetryWaitMax sets the minimum length of time to wait between retries.
func WithRetryWaitMin ¶ added in v1.3.7
WithRetryWaitMin sets the minimum length of time to wait between retries.
func WithTLSConfig ¶ added in v1.5.0
WithTLSConfig sets the TLS config.
func WithUserAgent ¶ added in v0.4.0
WithUserAgent sets the media type of the signature.