/openthread-3.4.0/src/lib/hdlc/ |
D | hdlc.hpp | 135 template <uint16_t kSize> class FrameBuffer : public FrameWritePointer 184 uint8_t mBuffer[kSize]; 196 template <uint16_t kSize> class MultiFrameBuffer : public FrameWritePointer 219 mRemainingLength = kSize - kHeaderSize; in Clear() 249 mRemainingLength = static_cast<uint16_t>(mBuffer + kSize - mWritePointer); in SetLength() 281 mRemainingLength = static_cast<uint16_t>(mBuffer + kSize - mWritePointer); in SetSkipLength() 313 …uint16_t GetFrameMaxLength(void) const { return static_cast<uint16_t>(mBuffer + kSize - GetFrame()… in GetFrameMaxLength() 328 mRemainingLength = static_cast<uint16_t>(mBuffer + kSize - mWritePointer); in SaveFrame() 341 mRemainingLength = static_cast<uint16_t>(mBuffer + kSize - mWritePointer); in DiscardFrame() 454 uint8_t mBuffer[kSize];
|
/openthread-3.4.0/src/core/net/ |
D | ip6_address.cpp | 61 return Random::Crypto::FillBuffer(&m8[1], kSize - 1); in GenerateRandomUla() 96 (MatchLength(GetBytes(), aSubPrefix.m8, NetworkPrefix::kSize) >= NetworkPrefix::kLength); in ContainsPrefix() 145 OT_ASSERT(aMaxSize <= Address::kSize); in MatchLength() 225 if (GetBytesSize() < Address::kSize - 1) in ToString() 258 …dentifier::GenerateRandom(void) { SuccessOrAssert(Random::Crypto::FillBuffer(mFields.m8, kSize)); } in GenerateRandom() 260 void InterfaceIdentifier::SetBytes(const uint8_t *aBuffer) { memcpy(mFields.m8, aBuffer, kSize); } in SetBytes() 319 Address::CopyBits(mFields.m8, aPrefix.GetBytes() + NetworkPrefix::kSize, in ApplyPrefix() 328 string.AppendHexBytes(mFields.m8, kSize); in ToString() 525 for (uint8_t i = 0; i < Ip4::Address::kSize; i++) in SynthesizeFromIp4Address() 551 uint8_t endIndex = kSize / sizeof(uint16_t); in ParseFrom() [all …]
|
D | ip6_address.hpp | 76 static constexpr uint8_t kSize = OT_IP6_PREFIX_SIZE; ///< Size in bytes. member in ot::Ip6::NetworkPrefix 376 …static constexpr uint8_t kSize = OT_IP6_IID_SIZE; ///< Size of an IPv6 Interface Identifier (in by… member in ot::Ip6::InterfaceIdentifier 583 static constexpr uint8_t kSize = OT_IP6_ADDRESS_SIZE; ///< Size of an IPv6 Address (in bytes). member in ot::Ip6::Address 630 void SetBytes(const uint8_t *aBuffer) { memcpy(mFields.m8, aBuffer, kSize); } in SetBytes()
|
D | dhcp6.hpp | 101 static constexpr uint16_t kSize = 3; ///< Transaction Id size (in bytes). member in ot::Dhcp6::TransactionId 110 Error GenerateRandom(void) { return Random::Crypto::FillBuffer(m8, kSize); } in GenerateRandom() 113 uint8_t m8[kSize];
|
D | ip4_types.cpp | 181 … (Ip6::Prefix::MatchLength(GetBytes(), aOther.GetBytes(), Ip4::Address::kSize) >= mLength); in operator ==() 186 memcpy(mAddress.mFields.m8, aAddress, Ip4::Address::kSize); in Set()
|
D | ip4_types.hpp | 102 static constexpr uint16_t kSize = 4; ///< Size of an IPv4 Address (in bytes). member in ot::Ip4::Address 126 void SetBytes(const uint8_t *aBuffer) { memcpy(mFields.m8, aBuffer, kSize); } in SetBytes()
|
/openthread-3.4.0/src/core/meshcop/ |
D | dataset_local.cpp | 248 networkKeyTlv->GetNetworkKey().m8, NetworkKey::kSize)); in MoveKeysToSecureStorage() 259 pskcTlv->GetPskc().m8, Pskc::kSize)); in MoveKeysToSecureStorage() 282 error = ExportKey(networkKeyRef, networkKey.m8, NetworkKey::kSize, keyLen); in EmplaceSecurelyStoredKeys() 291 OT_ASSERT(keyLen == NetworkKey::kSize); in EmplaceSecurelyStoredKeys() 301 error = ExportKey(pskcRef, pskc.m8, Pskc::kSize, keyLen); in EmplaceSecurelyStoredKeys() 310 OT_ASSERT(keyLen == Pskc::kSize); in EmplaceSecurelyStoredKeys()
|
/openthread-3.4.0/src/core/thread/ |
D | key_manager.cpp | 296 cryptoKey.Set(mNetworkKey.m8, NetworkKey::kSize); in ComputeKeys() 318 cryptoKey.Set(mNetworkKey.m8, NetworkKey::kSize); in ComputeTrelKey() 325 hkdf.Expand(kTrelInfoString, sizeof(kTrelInfoString), aKey.m8, Mac::Key::kSize); in ComputeTrelKey() 523 …essOrAssert(Crypto::Storage::ExportKey(mNetworkKeyRef, aNetworkKey.m8, NetworkKey::kSize, keyLen)); in GetNetworkKey() 524 OT_ASSERT(keyLen == NetworkKey::kSize); in GetNetworkKey() 542 SuccessOrAssert(Crypto::Storage::ExportKey(mPskcRef, aPskc.m8, Pskc::kSize, keyLen)); in GetPskc() 543 OT_ASSERT(keyLen == Pskc::kSize); in GetPskc() 578 … Crypto::Storage::kTypePersistent, aNetworkKey.m8, NetworkKey::kSize)); in StoreNetworkKey() 597 … Crypto::Storage::kTypePersistent, aPskc.m8, Pskc::kSize)); in StorePskc()
|
D | key_manager.hpp | 141 …static constexpr uint8_t kSize = OT_NETWORK_KEY_SIZE; ///< Size of the Thread Network Key (in byte… member in ot::NetworkKey 172 static constexpr uint8_t kSize = OT_PSKC_MAX_SIZE; ///< Size (number of bytes) of the PSKc. member in ot::Pskc
|
D | network_diagnostic.cpp | 148 if (count * Ip6::Address::kSize <= Tlv::kBaseTlvMaxLength) in AppendIp6AddressList() 153 tlv.SetLength(static_cast<uint8_t>(count * Ip6::Address::kSize)); in AppendIp6AddressList() 161 extTlv.SetLength(count * Ip6::Address::kSize); in AppendIp6AddressList() 745 VerifyOrExit((tlvLength % Ip6::Address::kSize) == 0, error = kErrorParse); in GetNextDiagTlv() 758 valueOffset += Ip6::Address::kSize; in GetNextDiagTlv() 759 tlvLength -= Ip6::Address::kSize; in GetNextDiagTlv()
|
/openthread-3.4.0/src/cli/ |
D | cli_output.hpp | 212 static constexpr uint16_t kSize = 21; ///< Size of a buffer member 214 char mChars[kSize]; ///< Char array (do not access the array directly). 449 static constexpr uint16_t kSize = 7; ///< Size of a buffer member 451 char mChars[kSize]; ///< Char array (do not access the array directly).
|
/openthread-3.4.0/src/core/common/ |
D | string.hpp | 401 template <uint16_t kSize> class String : public StringWriter 403 static_assert(kSize > 0, "String buffer cannot be empty."); 424 char mBuffer[kSize];
|
/openthread-3.4.0/src/core/utils/ |
D | slaac_address.hpp | 74 … static constexpr uint16_t kSize = 32; ///< Secret key size for generating semantically opaque IID. member 76 uint8_t m8[kSize];
|
D | slaac_address.cpp | 285 static_assert(sizeof(hash) >= Ip6::InterfaceIdentifier::kSize, in GenerateIid()
|
/openthread-3.4.0/tests/unit/ |
D | test_ecdsa.cpp | 98 DumpBuffer("PublicKey", publicKey.GetBytes(), Ecdsa::P256::PublicKey::kSize); in TestEcdsaVector() 100 …VerifyOrQuit(sizeof(kPublicKey) == Ecdsa::P256::PublicKey::kSize, "Example public key is invalid"); in TestEcdsaVector() 155 DumpBuffer("PublicKey", publicKey.GetBytes(), Ecdsa::P256::PublicKey::kSize); in TestEcdsaKeyGenerationSignAndVerify()
|
D | test_lowpan.cpp | 1953 static constexpr uint16_t kSize = 0x7ef; in TestLowpanFragmentHeader() local 1975 firstFragHeader.Init(kSize, kTag); in TestLowpanFragmentHeader() 1989 VerifyOrQuit(fragHeader.GetDatagramSize() == kSize, "failed after ParseFrom()"); in TestLowpanFragmentHeader() 2002 nextFragHeader.Init(kSize, kTag, kOffset); in TestLowpanFragmentHeader() 2010 nextFragHeader.Init(kSize, kTag, kOffset + 1); in TestLowpanFragmentHeader() 2017 nextFragHeader.Init(kSize, kTag, kOffset + 7); in TestLowpanFragmentHeader() 2029 VerifyOrQuit(fragHeader.GetDatagramSize() == kSize, "failed after ParseFrom()"); in TestLowpanFragmentHeader() 2047 VerifyOrQuit(fragHeader.GetDatagramSize() == kSize, "failed after ParseFrom()"); in TestLowpanFragmentHeader()
|
D | test_string.cpp | 44 template <uint16_t kSize> void PrintString(const char *aName, const String<kSize> aString) in PrintString()
|
/openthread-3.4.0/src/core/mac/ |
D | mac_types.cpp | 292 … Crypto::Storage::kTypeVolatile, aKey.GetBytes(), Key::kSize)); in SetFrom() 311 SuccessOrAssert(Crypto::Storage::ExportKey(GetKeyRef(), aKey.m8, Key::kSize, keySize)); in ExtractKey() 323 aCryptoKey.Set(GetKey().GetBytes(), Key::kSize); in ConvertToCryptoKey()
|
D | mac_frame.hpp | 130 static constexpr uint8_t kSize = 2; member in ot::Mac::HeaderIe 137 uint8_t m8[kSize];
|
D | mac_types.hpp | 442 static constexpr uint16_t kSize = OT_MAC_KEY_SIZE; ///< Key size in bytes. member in ot::Mac::Key
|
/openthread-3.4.0/src/core/crypto/ |
D | ecdsa.hpp | 102 … static constexpr uint8_t kSize = OT_CRYPTO_ECDSA_SIGNATURE_SIZE; ///< Signature size in bytes. member in ot::Crypto::Ecdsa::P256::Signature 328 …static constexpr uint8_t kSize = OT_CRYPTO_ECDSA_PUBLIC_KEY_SIZE; ///< Size of the public key in b… member in ot::Crypto::Ecdsa::P256::PublicKey
|
D | sha256.hpp | 78 static const uint8_t kSize = OT_CRYPTO_SHA256_HASH_SIZE; ///< SHA-256 hash size (bytes) member in ot::Crypto::Sha256::Hash
|
D | sha256.cpp | 72 …inish(Hash &aHash) { SuccessOrAssert(otPlatCryptoSha256Finish(&mContext, aHash.m8, Hash::kSize)); } in Finish()
|
D | hmac_sha256.cpp | 61 SuccessOrAssert(otPlatCryptoHmacSha256Finish(&mContext, aHash.m8, Hash::kSize)); in Finish()
|
D | crypto_platform.cpp | 594 … Sha256::Hash::kSize, MBEDTLS_MD_SHA256, MbedTls::CryptoSecurePrng, nullptr); in otPlatCryptoEcdsaSign() 597 Sha256::Hash::kSize, MBEDTLS_MD_SHA256); in otPlatCryptoEcdsaSign() 649 …ret = mbedtls_ecdsa_verify(&ecdsa.MBEDTLS_PRIVATE(grp), aHash->m8, Sha256::Hash::kSize, &ecdsa.MBE… in otPlatCryptoEcdsaVerify()
|