Documentation
¶
Index ¶
- type CertsClient
- func (cl *CertsClient) CreateDeviceCert(deviceID string, pubKeyPEM string, validityDays int) (certPEM string, caCertPEM string, err error)
- func (cl *CertsClient) CreateServiceCert(serviceID string, pubKeyPEM string, names []string, validityDays int) (certPEM string, caCertPEM string, err error)
- func (cl *CertsClient) CreateUserCert(userID string, pubKeyPEM string, validityDays int) (certPEM string, caCertPEM string, err error)
- func (cl *CertsClient) VerifyCert(clientID string, certPEM string) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CertsClient ¶
type CertsClient struct {
// contains filtered or unexported fields
}
CertsClient is a marshaller for cert service messages using a provided hub connection. This uses the default serializer to marshal and unmarshal messages.
func NewCertsClient ¶
func NewCertsClient(hc *hubclient.HubClient) *CertsClient
NewCertsClient returns a certs service client for managing certificates
hc is the hub client connection to use
func (*CertsClient) CreateDeviceCert ¶
func (cl *CertsClient) CreateDeviceCert(deviceID string, pubKeyPEM string, validityDays int) ( certPEM string, caCertPEM string, err error)
CreateDeviceCert generates or renews IoT device certificate for access hub IoT gateway
func (*CertsClient) CreateServiceCert ¶
func (cl *CertsClient) CreateServiceCert( serviceID string, pubKeyPEM string, names []string, validityDays int) ( certPEM string, caCertPEM string, err error)
CreateServiceCert generates or renews service certificates for access hub IoT gateway
func (*CertsClient) CreateUserCert ¶
func (cl *CertsClient) CreateUserCert( userID string, pubKeyPEM string, validityDays int) ( certPEM string, caCertPEM string, err error)
CreateUserCert generates or renews user certificates for access hiveot hub
func (*CertsClient) VerifyCert ¶
func (cl *CertsClient) VerifyCert( clientID string, certPEM string) (err error)
VerifyCert verifies if the certificate is valid for the Hub
Click to show internal directories.
Click to hide internal directories.