@@ -185,7 +185,7 @@ CHIP_ERROR Efr32PsaOperationalKeystore::NewOpKeypairForFabric(FabricIndex fabric
185
185
MutableByteSpan & outCertificateSigningRequest)
186
186
{
187
187
CHIP_ERROR error = CHIP_NO_ERROR;
188
- VerifyOrReturnError (mIsInitialized , CHIP_ERROR_INCORRECT_STATE );
188
+ VerifyOrReturnError (mIsInitialized , CHIP_ERROR_WELL_UNINITIALIZED );
189
189
VerifyOrReturnError (IsValidFabricIndex (fabricIndex), CHIP_ERROR_INVALID_FABRIC_INDEX);
190
190
191
191
// If a key is pending, we cannot generate for a different fabric index until we commit or revert.
@@ -267,7 +267,7 @@ CHIP_ERROR Efr32PsaOperationalKeystore::NewOpKeypairForFabric(FabricIndex fabric
267
267
CHIP_ERROR Efr32PsaOperationalKeystore::ActivateOpKeypairForFabric (FabricIndex fabricIndex,
268
268
const Crypto::P256PublicKey & nocPublicKey)
269
269
{
270
- VerifyOrReturnError (mIsInitialized , CHIP_ERROR_INCORRECT_STATE );
270
+ VerifyOrReturnError (mIsInitialized , CHIP_ERROR_WELL_UNINITIALIZED );
271
271
VerifyOrReturnError (mPendingKeypair != nullptr , CHIP_ERROR_INVALID_FABRIC_INDEX);
272
272
VerifyOrReturnError (IsValidFabricIndex (fabricIndex) && (fabricIndex == mPendingFabricIndex ), CHIP_ERROR_INVALID_FABRIC_INDEX);
273
273
@@ -281,7 +281,7 @@ CHIP_ERROR Efr32PsaOperationalKeystore::ActivateOpKeypairForFabric(FabricIndex f
281
281
282
282
CHIP_ERROR Efr32PsaOperationalKeystore::CommitOpKeypairForFabric (FabricIndex fabricIndex)
283
283
{
284
- VerifyOrReturnError (mIsInitialized , CHIP_ERROR_INCORRECT_STATE );
284
+ VerifyOrReturnError (mIsInitialized , CHIP_ERROR_WELL_UNINITIALIZED );
285
285
VerifyOrReturnError (mPendingKeypair != nullptr , CHIP_ERROR_INVALID_FABRIC_INDEX);
286
286
VerifyOrReturnError (IsValidFabricIndex (fabricIndex) && (fabricIndex == mPendingFabricIndex ), CHIP_ERROR_INVALID_FABRIC_INDEX);
287
287
VerifyOrReturnError (mIsPendingKeypairActive == true , CHIP_ERROR_INCORRECT_STATE);
@@ -329,7 +329,7 @@ CHIP_ERROR Efr32PsaOperationalKeystore::CommitOpKeypairForFabric(FabricIndex fab
329
329
330
330
CHIP_ERROR Efr32PsaOperationalKeystore::RemoveOpKeypairForFabric (FabricIndex fabricIndex)
331
331
{
332
- VerifyOrReturnError (mIsInitialized , CHIP_ERROR_INCORRECT_STATE );
332
+ VerifyOrReturnError (mIsInitialized , CHIP_ERROR_WELL_UNINITIALIZED );
333
333
VerifyOrReturnError (IsValidFabricIndex (fabricIndex), CHIP_ERROR_INVALID_FABRIC_INDEX);
334
334
335
335
// Remove pending keypair if we have it and the fabric ID matches
@@ -396,7 +396,7 @@ void Efr32PsaOperationalKeystore::RevertPendingKeypair()
396
396
CHIP_ERROR Efr32PsaOperationalKeystore::SignWithOpKeypair (FabricIndex fabricIndex, const ByteSpan & message,
397
397
Crypto::P256ECDSASignature & outSignature) const
398
398
{
399
- VerifyOrReturnError (mIsInitialized , CHIP_ERROR_INCORRECT_STATE );
399
+ VerifyOrReturnError (mIsInitialized , CHIP_ERROR_WELL_UNINITIALIZED );
400
400
VerifyOrReturnError (IsValidFabricIndex (fabricIndex), CHIP_ERROR_INVALID_FABRIC_INDEX);
401
401
402
402
// Check to see whether the key is an activated pending key
0 commit comments