nl:: Weave:: WeaveFabricState
#include <src/lib/core/WeaveFabricState.h>
WeaveFabricState için ileriye dönük beyan.
Özet
Oluşturucular ve Yıkıcılar |
|
---|---|
WeaveFabricState(void)
|
Herkese açık türler |
|
---|---|
PeerIndexType
|
typedefuint8_t
|
SessionEndCbFunct)(uint16_t keyId, uint64_t peerNodeId, void *context)
|
typedefvoid(*
|
State
|
enum |
Herkese açık özellikler |
|
---|---|
AutoCreateKeys
|
bool
|
DebugFabricId
|
uint64_t
|
DefaultSubnet
|
uint16_t
|
FabricId
|
uint64_t
|
GroupKeyStore
|
|
ListenIPv4Addr
|
IPAddress
|
ListenIPv6Addr
|
IPAddress
|
LocalNodeId
|
uint64_t
|
LogKeys
|
bool
|
MaxUnencUDPMsgIdRcvd[WEAVE_CONFIG_MAX_PEER_NODES]
|
uint32_t
|
MessageLayer
|
|
MostRecentlyUsedIndexes[WEAVE_CONFIG_MAX_PEER_NODES]
|
PeerIndexType
|
NodeId[WEAVE_CONFIG_MAX_PEER_NODES]
|
uint64_t
|
PairingCode
|
const char *
|
State
|
uint8_t
|
UnencRcvFlags[WEAVE_CONFIG_MAX_PEER_NODES]
|
WeaveSessionState::ReceiveFlagsType
|
UseTestKey
|
bool
|
Kamu işlevleri |
|
---|---|
AddSharedSessionEndNode(uint64_t endNodeId, uint64_t terminatingNodeId, uint16_t keyId)
|
|
AddSharedSessionEndNode(WeaveSessionKey *sessionKey, uint64_t endNodeId)
|
Bu yöntem, paylaşılan uç düğüm kaydına yeni uç düğüm ekler.
|
AllocSessionKey(uint64_t peerNodeId, uint16_t keyId, WeaveConnection *boundCon, WeaveSessionKey *& sessionKey)
|
|
ClearFabricState(void)
|
void
|
CreateFabric(void)
|
|
FindSessionKey(uint16_t keyId, uint64_t peerNodeId, bool create, WeaveSessionKey *& retRec)
|
Bu yöntem oturum anahtarı girişini bulur.
|
FindSharedSession(uint64_t terminatingNodeId, WeaveAuthMode authMode, uint8_t encType)
|
Oturum anahtarları tablosunda, belirtilen sonlandırma düğümünü hedefleyen ve belirtilen kimlik doğrulama modu ve şifreleme türüyle eşleşen, oluşturulmuş paylaşılan bir oturum anahtarını arayın.
|
GetFabricState(uint8_t *buf, uint32_t bufSize, uint32_t & fabricStateLen)
|
|
GetPassword(uint8_t pwSrc, const char *& ps, uint16_t & pwLen)
|
|
GetSessionKey(uint16_t keyId, uint64_t peerNodeId, WeaveSessionKey *& outSessionKey)
|
|
GetSessionState(uint64_t remoteNodeId, uint16_t keyId, uint8_t encType, WeaveConnection *con, WeaveSessionState & outSessionState)
|
|
GetSharedSessionEndNodeIds(const WeaveSessionKey *sessionKey, uint64_t *endNodeIds, uint8_t endNodeIdsBufSize, uint8_t & endNodeIdsCount)
|
Bu yöntem, belirtilen oturumu paylaşan tüm son düğüm kimliklerini döndürür.
|
HandleConnectionClosed(WeaveConnection *con)
|
void
|
Init(void)
|
|
Init(nl::Weave::Profiles::Security::AppKeys::GroupKeyStoreBase *groupKeyStore)
|
|
IsFabricAddress(const IPAddress & addr) const
|
bool
Bir IP adresinin, yerel Weave yapısında bir düğümün adresini temsil edip etmediğini belirler.
|
IsLocalFabricAddress(const IPAddress & addr) const
|
bool
Bir IP adresinin yerel düğüm için bir Weave yapı adresini temsil edip etmediğini belirler.
|
IsSharedSession(uint16_t keyId, uint64_t peerNodeId)
|
bool
Bu yöntem, belirtilen eş ve keyId ile ilişkilendirilmiş güvenli oturumun paylaşılıp paylaşılmadığını kontrol eder.
|
JoinExistingFabric(const uint8_t *fabricState, uint32_t fabricStateLen)
|
|
RegisterSessionEndCallback(SessionEndCbCtxt *sessionEndCb)
|
|
RemoveIdleSessionKeys()
|
bool
|
RemoveSessionKey(uint16_t keyId, uint64_t peerNodeId)
|
|
RemoveSessionKey(WeaveSessionKey *sessionKey, bool wasIdle)
|
void
|
RemoveSharedSessionEndNodes(const WeaveSessionKey *sessionKey)
|
void
|
RestoreSession(uint8_t *serializedSession, uint16_t serializedSessionLen)
|
Daha önce askıya alınmış bir Weave Security Session'ı seri durumdan geri yükleyin.
|
SelectNodeAddress(uint64_t nodeId, uint16_t subnet) const
|
Belirtilen düğüm için Weave ULA içeren bir IPAddress döndürür.
|
SelectNodeAddress(uint64_t nodeId) const
|
Belirtilen düğüm için Weave ULA içeren bir IPAddress döndürür.
|
SetDelegate(FabricStateDelegate *aDelegate)
|
void
Bu yöntem, yetki nesnesini ayarlar.
|
SetSessionKey(uint16_t keyId, uint64_t peerNodeId, uint8_t encType, WeaveAuthMode authMode, const WeaveEncryptionKey *encKey)
|
|
SetSessionKey(WeaveSessionKey *sessionKey, uint8_t encType, WeaveAuthMode authMode, const WeaveEncryptionKey *encKey)
|
|
Shutdown(void)
|
|
SuspendSession(uint16_t keyId, uint64_t peerNodeId, uint8_t *buf, uint16_t bufSize, uint16_t & serializedSessionLen)
|
Etkin bir Weave güvenlik oturumunun durumunu askıya alın ve serileştirin.
|
Yapılar |
|
---|---|
nl:: |
Herkese açık türler
PeerIndexType
uint8_t PeerIndexType
SessionEndCbFunct
void(* SessionEndCbFunct)(uint16_t keyId, uint64_t peerNodeId, void *context)
Eyalet
State
Herkese açık özellikler
AutoCreateKeys
bool AutoCreateKeys
DebugFabricId
uint64_t DebugFabricId
DefaultSubnet
uint16_t DefaultSubnet
FabricId
uint64_t FabricId
GroupKeyStore
nl::Weave::Profiles::Security::AppKeys::GroupKeyStoreBase * GroupKeyStore
ListenIPv4Addr
IPAddress ListenIPv4Addr
ListenIPv6Addr
IPAddress ListenIPv6Addr
LocalNodeId
uint64_t LocalNodeId
LogKeys
bool LogKeys
MaxUnencUDPMsgIdRcvd
uint32_t MaxUnencUDPMsgIdRcvd[WEAVE_CONFIG_MAX_PEER_NODES]
MessageLayer
WeaveMessageLayer * MessageLayer
MostRecentlyUsedIndexes
PeerIndexType MostRecentlyUsedIndexes[WEAVE_CONFIG_MAX_PEER_NODES]
NodeId
uint64_t NodeId[WEAVE_CONFIG_MAX_PEER_NODES]
PairingCode
const char * PairingCode
Eyalet
uint8_t State
UnencRcvFlags
WeaveSessionState::ReceiveFlagsType UnencRcvFlags[WEAVE_CONFIG_MAX_PEER_NODES]
UseTestKey
bool UseTestKey
Kamu işlevleri
AddSharedSessionEndNode
WEAVE_ERROR AddSharedSessionEndNode( uint64_t endNodeId, uint64_t terminatingNodeId, uint16_t keyId )
AddSharedSessionEndNode
WEAVE_ERROR AddSharedSessionEndNode( WeaveSessionKey *sessionKey, uint64_t endNodeId )
Bu yöntem, paylaşılan uç düğüm kaydına yeni uç düğüm ekler.
Ayrıntılar | |||||
---|---|---|---|---|---|
Parametreler |
|
||||
Döndürülen Değerler |
|
AllocSessionKey
WEAVE_ERROR AllocSessionKey( uint64_t peerNodeId, uint16_t keyId, WeaveConnection *boundCon, WeaveSessionKey *& sessionKey )
ClearFabricState
void ClearFabricState( void )
CreateFabric
WEAVE_ERROR CreateFabric( void )
FindSessionKey
WEAVE_ERROR FindSessionKey( uint16_t keyId, uint64_t peerNodeId, bool create, WeaveSessionKey *& retRec )
Bu yöntem oturum anahtarı girişini bulur.
Ayrıntılar | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Parametreler |
|
||||||||||
Döndürülen Değerler |
|
FindSharedSession
WeaveSessionKey * FindSharedSession( uint64_t terminatingNodeId, WeaveAuthMode authMode, uint8_t encType )
Oturum anahtarları tablosunda, belirtilen sonlandırma düğümünü hedefleyen ve belirtilen kimlik doğrulama modu ve şifreleme türüyle eşleşen, oluşturulmuş paylaşılan bir oturum anahtarını arayın.
Ayrıntılar | |||||||
---|---|---|---|---|---|---|---|
Parametreler |
|
||||||
Döndürülen Değerler |
|
GetFabricState
WEAVE_ERROR GetFabricState( uint8_t *buf, uint32_t bufSize, uint32_t & fabricStateLen )
GetPassword
WEAVE_ERROR GetPassword( uint8_t pwSrc, const char *& ps, uint16_t & pwLen )
GetSessionKey
WEAVE_ERROR GetSessionKey( uint16_t keyId, uint64_t peerNodeId, WeaveSessionKey *& outSessionKey )
GetSessionState
WEAVE_ERROR GetSessionState( uint64_t remoteNodeId, uint16_t keyId, uint8_t encType, WeaveConnection *con, WeaveSessionState & outSessionState )
GetSharedSessionEndNodeIds
WEAVE_ERROR GetSharedSessionEndNodeIds( const WeaveSessionKey *sessionKey, uint64_t *endNodeIds, uint8_t endNodeIdsBufSize, uint8_t & endNodeIdsCount )
Bu yöntem, belirtilen oturumu paylaşan tüm son düğüm kimliklerini döndürür.
Ayrıntılar | |||||||||
---|---|---|---|---|---|---|---|---|---|
Parametreler |
|
||||||||
Döndürülen Değerler |
|
HandleConnectionClosed
void HandleConnectionClosed( WeaveConnection *con )
Başlat
WEAVE_ERROR Init( void )
Başlat
WEAVE_ERROR Init( nl::Weave::Profiles::Security::AppKeys::GroupKeyStoreBase *groupKeyStore )
IsFabricAddress
bool IsFabricAddress( const IPAddress & addr ) const
Bir IP adresinin, yerel Weave yapısında bir düğümün adresini temsil edip etmediğini belirler.
IsLocalFabricAddress
bool IsLocalFabricAddress( const IPAddress & addr ) const
Bir IP adresinin yerel düğüm için bir Weave yapı adresini temsil edip etmediğini belirler.
IsSharedSession
bool IsSharedSession( uint16_t keyId, uint64_t peerNodeId )
Bu yöntem, belirtilen eş ve keyId ile ilişkilendirilmiş güvenli oturumun paylaşılıp paylaşılmadığını kontrol eder.
Ayrıntılar | |||||
---|---|---|---|---|---|
Parametreler |
|
||||
Döndürülen Değerler |
|
JoinExistingFabric
WEAVE_ERROR JoinExistingFabric( const uint8_t *fabricState, uint32_t fabricStateLen )
RegisterSessionEndCallback
WEAVE_ERROR RegisterSessionEndCallback( SessionEndCbCtxt *sessionEndCb )
RemoveIdleSessionKeys
bool RemoveIdleSessionKeys()
RemoveSessionKey
WEAVE_ERROR RemoveSessionKey( uint16_t keyId, uint64_t peerNodeId )
RemoveSessionKey
void RemoveSessionKey( WeaveSessionKey *sessionKey, bool wasIdle )
RemoveSharedSessionEndNodes
void RemoveSharedSessionEndNodes( const WeaveSessionKey *sessionKey )
RestoreSession
WEAVE_ERROR RestoreSession( uint8_t *serializedSession, uint16_t serializedSessionLen )
Daha önce askıya alınmış bir Weave Security Session'ı seri durumdan geri yükleyin.
SelectNodeAddress
IPAddress SelectNodeAddress( uint64_t nodeId, uint16_t subnet ) const
Belirtilen düğüm için Weave ULA içeren bir IPAddress döndürür.
Bu varyant, alt ağın belirtilmesini sağlar.
Ayrıntılar | |||||
---|---|---|---|---|---|
Parametreler |
|
||||
Döndürülen Değerler |
|
SelectNodeAddress
IPAddress SelectNodeAddress( uint64_t nodeId ) const
Belirtilen düğüm için Weave ULA içeren bir IPAddress döndürür.
Bu varyant, yerel düğümün varsayılan alt ağını kullanır.
Ayrıntılar | |||
---|---|---|---|
Parametreler |
|
||
Döndürülen Değerler |
|
SetDelegate
void SetDelegate( FabricStateDelegate *aDelegate )
Bu yöntem, yetki nesnesini ayarlar.
FabricId değiştirildiğinde (ör.bir kumaşa katıldığımızda/oluşturduğumuzda veya bir kumaştan ayrıldığımızda) (şeffaf kumaş durumu) yetki geri çağırma yöntemleri çağrılır.
Yetki verilmiş kullanıcı daha önce ayarlandıysa bu yönteme yapılan ikinci bir çağrı, önceki yetkinin üzerine yazılır.
Ayrıntılar | |||
---|---|---|---|
Parametreler |
|
SetSessionKey
WEAVE_ERROR SetSessionKey( uint16_t keyId, uint64_t peerNodeId, uint8_t encType, WeaveAuthMode authMode, const WeaveEncryptionKey *encKey )
SetSessionKey
WEAVE_ERROR SetSessionKey( WeaveSessionKey *sessionKey, uint8_t encType, WeaveAuthMode authMode, const WeaveEncryptionKey *encKey )
Kapat
WEAVE_ERROR Shutdown( void )
SuspendSession
WEAVE_ERROR SuspendSession( uint16_t keyId, uint64_t peerNodeId, uint8_t *buf, uint16_t bufSize, uint16_t & serializedSessionLen )
Etkin bir Weave güvenlik oturumunun durumunu askıya alın ve serileştirin.
Tanımlanmış bir Weave güvenlik oturumunun durumunu, sağlanan arabelleğe alır ve başka ileti gönderilemeyecek ya da alınamayacak şekilde oturumu askıya alır.
Bu yöntem, uyku sırasında RAM'i korumayan cihazlar tarafından kullanılmak üzere tasarlanmıştır. Böylece, etkin oturumun durumunu koruyabilir ve böylece, uyandıklarında oturumu yeniden kurma ihtiyacını ortadan kaldırabilirler.
WeaveFabricState
WeaveFabricState( void )