class WeaveKeyId

Defined at line 40 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

The definition of the Weave Key identifier. This class contains

key types, key flags, key ID fields definition, and API functions.

Public Methods

uint32_t ConvertToStaticAppKeyId (uint32_t keyId)
const char * DescribeKey (uint32_t keyId)
uint32_t GetType (uint32_t keyId)

Get Weave key type of the specified key ID.

Parameters

keyId [in] Weave key identifier.

Returns

type of the key ID.

Defined at line 146 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IsAppGroupKey (uint32_t keyId)
bool IsGeneralKey (uint32_t keyId)

Determine whether the specified key ID is of a general type.

Parameters

keyId [in] Weave key identifier.

Returns

true if the keyId has General type.

Defined at line 158 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IsSessionKey (uint32_t keyId)

Determine whether the specified key ID is of a session type.

Parameters

keyId [in] Weave key identifier.

Returns

true if the keyId of a session type.

Defined at line 170 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IsAppRotatingKey (uint32_t keyId)

Determine whether the specified key ID is of an application rotating type.

Parameters

keyId [in] Weave key identifier.

Returns

true if the keyId of an application rotating type.

Defined at line 194 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IsAppRootKey (uint32_t keyId)

Determine whether the specified key ID is of an application root key type.

Parameters

keyId [in] Weave key identifier.

Returns

true if the keyId of an application root key type.

Defined at line 208 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IsAppEpochKey (uint32_t keyId)

Determine whether the specified key ID is of an application epoch key type.

Parameters

keyId [in] Weave key identifier.

Returns

true if the keyId of an application epoch key type.

Defined at line 220 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IsAppGroupMasterKey (uint32_t keyId)

Determine whether the specified key ID is of an application group master key type.

Parameters

keyId [in] Weave key identifier.

Returns

true if the keyId of an application group master key type.

Defined at line 232 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t GetRootKeyId (uint32_t keyId)

Get application group root key ID that was used to derive specified application key.

Parameters

keyId [in] Weave application group key identifier.

Returns

root key ID.

Defined at line 268 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t GetEpochKeyId (uint32_t keyId)

Get application group epoch key ID that was used to derive specified application key.

Parameters

keyId [in] Weave application group key identifier.

Returns

epoch key ID.

Defined at line 280 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t GetAppGroupMasterKeyId (uint32_t keyId)

Get application group master key ID that was used to derive specified application key.

Parameters

keyId [in] Weave application group key identifier.

Returns

application group master key ID.

Defined at line 292 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint8_t GetRootKeyNumber (uint32_t keyId)

Get application group root key number that was used to derive specified application key.

Parameters

keyId [in] Weave application group key identifier.

Returns

root key number.

Defined at line 304 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint8_t GetEpochKeyNumber (uint32_t keyId)

Get application group epoch key number that was used to derive specified application key.

Parameters

keyId [in] Weave application group key identifier.

Returns

epoch key number.

Defined at line 316 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint8_t GetAppGroupLocalNumber (uint32_t keyId)

Get application group local number that was used to derive specified application key.

Parameters

keyId [in] Weave application group key identifier.

Returns

application group local number.

Defined at line 328 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IncorporatesRootKey (uint32_t keyId)
bool IncorporatesAppGroupMasterKey (uint32_t keyId)
bool IsAppStaticKey (uint32_t keyId)

Determine whether the specified key ID is of an application static type.

Parameters

keyId [in] Weave key identifier.

Returns

true if the keyId of an application static type.

Defined at line 182 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t MakeAppKeyId (uint32_t keyType, uint32_t rootKeyId, uint32_t epochKeyId, uint32_t appGroupMasterKeyId, bool useCurrentEpochKey)
uint32_t MakeAppIntermediateKeyId (uint32_t rootKeyId, uint32_t epochKeyId, bool useCurrentEpochKey)
uint32_t MakeAppRotatingKeyId (uint32_t rootKeyId, uint32_t epochKeyId, uint32_t appGroupMasterKeyId, bool useCurrentEpochKey)
uint32_t MakeAppStaticKeyId (uint32_t rootKeyId, uint32_t appGroupMasterKeyId)
bool IsValidKeyId (uint32_t keyId)
bool IsMessageEncryptionKeyId (uint32_t keyId, bool allowLogicalKeys)
bool IsSameKeyOrGroup (uint32_t keyId1, uint32_t keyId2)
uint16_t MakeSessionKeyId (uint16_t sessionKeyNumber)

Construct session key ID given session key number.

Parameters

sessionKeyNumber [in] Session key number.

Returns

session key ID.

Defined at line 244 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint16_t MakeGeneralKeyId (uint16_t generalKeyNumber)

Construct general key ID given general key number.

Parameters

generalKeyNumber [in] General key number.

Returns

general key ID.

Defined at line 256 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t MakeRootKeyId (uint8_t rootKeyNumber)

Construct application group root key ID given root key number.

Parameters

rootKeyNumber [in] Root key number.

Returns

root key ID.

Defined at line 340 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t MakeEpochKeyId (uint8_t epochKeyNumber)

Construct application group root key ID given epoch key number.

Parameters

epochKeyNumber [in] Epoch key number.

Returns

epoch key ID.

Defined at line 352 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t MakeAppGroupMasterKeyId (uint8_t appGroupLocalNumber)

Construct application group master key ID given application group local number.

Parameters

appGroupLocalNumber [in] Application group local number.

Returns

application group master key ID.

Defined at line 364 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

uint32_t ConvertToCurrentAppKeyId (uint32_t keyId)

Convert application group key ID to application current key ID.

Parameters

keyId [in] Application key ID.

Returns

application current key ID.

Defined at line 376 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool IncorporatesEpochKey (uint32_t keyId)

Determine whether the specified application group key ID incorporates epoch key.

Parameters

keyId [in] Weave application group key identifier.

Returns

true if the keyId incorporates epoch key.

Defined at line 388 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h

bool UsesCurrentEpochKey (uint32_t keyId)
uint32_t UpdateEpochKeyId (uint32_t keyId, uint32_t epochKeyId)

Enumerations

enum 
Name Value
kType_None 0x00000000
kType_General 0x00001000
kType_Session 0x00002000
kType_AppStaticKey 0x00004000
kType_AppRotatingKey kType_AppStaticKey | kTypeModifier_IncorporatesEpochKey
kType_AppRootKey 0x00010000
kType_AppEpochKey 0x00020000 | kTypeModifier_IncorporatesEpochKey
kType_AppGroupMasterKey 0x00030000
kType_AppIntermediateKey kType_AppRootKey | kTypeModifier_IncorporatesEpochKey
kNone kType_None | 0x0000
kFabricSecret kType_General | 0x0001
kFabricRootKey kType_AppRootKey | (0 << kShift_RootKeyNumber)
kClientRootKey kType_AppRootKey | (1 << kShift_RootKeyNumber)
kServiceRootKey kType_AppRootKey | (2 << kShift_RootKeyNumber)
kKeyNumber_Max kMask_KeyNumber
kRootKeyNumber_Max (kMask_RootKeyNumber >> kShift_RootKeyNumber)
kEpochKeyNumber_Max (kMask_EpochKeyNumber >> kShift_EpochKeyNumber)
kGroupLocalNumber_Max (kMask_GroupLocalNumber >> kShift_GroupLocalNumber)

Public Weave key ID fields, flags, and types.

Defined at line 71 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Core/WeaveKeyIds.h