Documentation ¶
Index ¶
- func NewIdentity(client *Client, name string, cred *credential.Credential) credential.Identity
- func NormalizeURL(addr string) (*url.URL, error)
- type Client
- func (c *Client) Enroll(req *api.EnrollmentRequest, saveOnDisk bool) (*api.EnrollmentResponse, error)
- func (c *Client) GenCSR(req *api.CSRInfo, id string) ([]byte, cccsp.Key, error)
- func (c *Client) GetCSP() cccsp.CCCSP
- func (c *Client) Init() error
- func (c *Client) NewX509Identity(name string, cred *credential.Credential) credential.Identity
- func (c *Client) Register(req *api.RegistrationRequest) (rr *api.RegistrationResponse, err error)
- func (c *Client) SendReq(req *http.Request, result interface{}) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewIdentity ¶
func NewIdentity(client *Client, name string, cred *credential.Credential) credential.Identity
NewIdentity is the constructor for identity
Types ¶
type Client ¶
type Client struct { // The client's home directory HomeDir string // The client's configuration Config *config.ClientConfig // contains filtered or unexported fields }
Client is the rksync-ca client object
func (*Client) Enroll ¶
func (c *Client) Enroll(req *api.EnrollmentRequest, saveOnDisk bool) (*api.EnrollmentResponse, error)
Enroll enrolls a new identity
func (*Client) NewX509Identity ¶
func (c *Client) NewX509Identity(name string, cred *credential.Credential) credential.Identity
NewX509Identity creates a new identity
func (*Client) Register ¶
func (c *Client) Register(req *api.RegistrationRequest) (rr *api.RegistrationResponse, err error)
Register registers a new identity
Click to show internal directories.
Click to hide internal directories.