Skip to content

Commit

Permalink
Improve documentation for MTRDeviceControllerStartupParams init metho…
Browse files Browse the repository at this point in the history
…ds. (#26251)
  • Loading branch information
bzbarsky-apple authored and pull[bot] committed Nov 15, 2023
1 parent dec2b3d commit d529b6f
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions src/darwin/Framework/CHIP/MTRDeviceControllerStartupParams.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ NS_ASSUME_NONNULL_BEGIN
* Prepare to initialize a controller given a keypair to use for signing
* operational certificates.
*
* A controller created from MTRDeviceControllerStartupParams initialized with
* this method will be able to issue operational certificates to devices it
* commissions, using nocSigner to sign them.
* @param ipk The Identity Protection Key, must be 16 bytes in length
* @param fabricID The fabric identifier, must be non-zero.
*/
Expand All @@ -40,17 +44,20 @@ NS_ASSUME_NONNULL_BEGIN
nocSigner:(id<MTRKeypair>)nocSigner API_AVAILABLE(ios(16.4), macos(13.3), watchos(9.4), tvos(16.4));

/**
* Prepare to initialize a controller with a complete operational certificate
* chain. This initialization method should be used when none of the
* certificate-signing private keys are available locally.
* Prepare to initialize a controller that is not able to sign operational
* certificates itself, and therefore needs to be provided with a complete
* operational certificate chain. This initialization method should be used
* when none of the certificate-signing private keys are available locally.
*
* A controller created from MTRDeviceControllerStartupParams initialized with
* this method will not be able to commission devices unless
* operationalCertificateIssuer and operationalCertificateIssuerQueue are set.
*
* The fabric id and node id to use will be derived from the provided
* The fabric id and node id to use for the controller will be derived from the provided
* operationalCertificate.
*
* @param ipk The Identity Protection Key, must be 16 bytes in length
* @param intermediateCertificate may be nil if operationalCertificate is directly signed by rootCertificate.
*
* ipk must be 16 bytes in length.
*/
- (instancetype)initWithIPK:(NSData *)ipk
operationalKeypair:(id<MTRKeypair>)operationalKeypair
Expand Down

0 comments on commit d529b6f

Please sign in to comment.