Documentation ¶
Index ¶
- func FileExist(path string) bool
- func FileIsDir(path string) bool
- type CertManagerSecurity
- func (cm *CertManagerSecurity) CachePublicData(data []byte, identity string) error
- func (cm *CertManagerSecurity) CachedPublicData(identity string) ([]byte, error)
- func (cm *CertManagerSecurity) CallerIdentity(caller string) (string, error)
- func (cm *CertManagerSecurity) CallerName() string
- func (cm *CertManagerSecurity) ChecksumBytes(data []byte) []byte
- func (cm *CertManagerSecurity) ChecksumString(data string) []byte
- func (cm *CertManagerSecurity) Enroll(ctx context.Context, wait time.Duration, cb func(int)) error
- func (cm *CertManagerSecurity) HTTPClient(secure bool) (*http.Client, error)
- func (cm *CertManagerSecurity) Identity() string
- func (cm *CertManagerSecurity) PrivilegedVerifyByteSignature(dat []byte, sig []byte, identity string) bool
- func (cm *CertManagerSecurity) PrivilegedVerifyStringSignature(dat string, sig []byte, identity string) bool
- func (cm *CertManagerSecurity) Provider() string
- func (cm *CertManagerSecurity) PublicCertPem() (*pem.Block, error)
- func (cm *CertManagerSecurity) PublicCertTXT() ([]byte, error)
- func (cm *CertManagerSecurity) RemoteSignRequest(str []byte) (signed []byte, err error)
- func (cm *CertManagerSecurity) SSLContext() (*http.Transport, error)
- func (cm *CertManagerSecurity) SignBytes(b []byte) (signature []byte, err error)
- func (cm *CertManagerSecurity) SignString(s string) (signature []byte, err error)
- func (cm *CertManagerSecurity) TLSConfig() (*tls.Config, error)
- func (cm *CertManagerSecurity) Validate() (errs []string, ok bool)
- func (cm *CertManagerSecurity) VerifyByteSignature(str []byte, signature []byte, identity string) bool
- func (cm *CertManagerSecurity) VerifyCertificate(certpem []byte, identity string) error
- func (cm *CertManagerSecurity) VerifyStringSignature(str string, signature []byte, identity string) bool
- type Config
- type Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CertManagerSecurity ¶
type CertManagerSecurity struct {
// contains filtered or unexported fields
}
CertManagerSecurity implements a security provider that auto enrolls with Kubernetes Cert Manager
It only supports being used inside a cluster and does not use the kubernetes API client libraries due to dependencies and just awfulness with go mod
func New ¶
func New(opts ...Option) (*CertManagerSecurity, error)
func (*CertManagerSecurity) CachePublicData ¶
func (cm *CertManagerSecurity) CachePublicData(data []byte, identity string) error
func (*CertManagerSecurity) CachedPublicData ¶
func (cm *CertManagerSecurity) CachedPublicData(identity string) ([]byte, error)
func (*CertManagerSecurity) CallerIdentity ¶
func (cm *CertManagerSecurity) CallerIdentity(caller string) (string, error)
func (*CertManagerSecurity) CallerName ¶
func (cm *CertManagerSecurity) CallerName() string
func (*CertManagerSecurity) ChecksumBytes ¶
func (cm *CertManagerSecurity) ChecksumBytes(data []byte) []byte
func (*CertManagerSecurity) ChecksumString ¶
func (cm *CertManagerSecurity) ChecksumString(data string) []byte
func (*CertManagerSecurity) HTTPClient ¶
func (cm *CertManagerSecurity) HTTPClient(secure bool) (*http.Client, error)
func (*CertManagerSecurity) Identity ¶
func (cm *CertManagerSecurity) Identity() string
func (*CertManagerSecurity) PrivilegedVerifyByteSignature ¶
func (cm *CertManagerSecurity) PrivilegedVerifyByteSignature(dat []byte, sig []byte, identity string) bool
func (*CertManagerSecurity) PrivilegedVerifyStringSignature ¶
func (cm *CertManagerSecurity) PrivilegedVerifyStringSignature(dat string, sig []byte, identity string) bool
func (*CertManagerSecurity) Provider ¶
func (cm *CertManagerSecurity) Provider() string
func (*CertManagerSecurity) PublicCertPem ¶
func (cm *CertManagerSecurity) PublicCertPem() (*pem.Block, error)
func (*CertManagerSecurity) PublicCertTXT ¶
func (cm *CertManagerSecurity) PublicCertTXT() ([]byte, error)
func (*CertManagerSecurity) RemoteSignRequest ¶
func (cm *CertManagerSecurity) RemoteSignRequest(str []byte) (signed []byte, err error)
func (*CertManagerSecurity) SSLContext ¶
func (cm *CertManagerSecurity) SSLContext() (*http.Transport, error)
func (*CertManagerSecurity) SignBytes ¶
func (cm *CertManagerSecurity) SignBytes(b []byte) (signature []byte, err error)
func (*CertManagerSecurity) SignString ¶
func (cm *CertManagerSecurity) SignString(s string) (signature []byte, err error)
func (*CertManagerSecurity) TLSConfig ¶
func (cm *CertManagerSecurity) TLSConfig() (*tls.Config, error)
func (*CertManagerSecurity) Validate ¶
func (cm *CertManagerSecurity) Validate() (errs []string, ok bool)
func (*CertManagerSecurity) VerifyByteSignature ¶
func (cm *CertManagerSecurity) VerifyByteSignature(str []byte, signature []byte, identity string) bool
func (*CertManagerSecurity) VerifyCertificate ¶
func (cm *CertManagerSecurity) VerifyCertificate(certpem []byte, identity string) error
func (*CertManagerSecurity) VerifyStringSignature ¶
func (cm *CertManagerSecurity) VerifyStringSignature(str string, signature []byte, identity string) bool
Click to show internal directories.
Click to hide internal directories.