Home
last modified time | relevance | path

Searched refs:olen (Results 1 – 14 of 14) sorted by relevance

/ohos5.0/foundation/communication/dsoftbus/adapter/common/openssl/
H A Dsoftbus_adapter_crypto.c239 *olen = 0; in SoftBusBase64Encode()
259 *olen += outlen; in SoftBusBase64Encode()
261 *olen += outlen; in SoftBusBase64Encode()
263 if (*olen > dlen) { in SoftBusBase64Encode()
277 if ((*olen > 0) && (dst[*olen - 1] == '\n')) { in SoftBusBase64Encode()
278 (*olen)--; in SoftBusBase64Encode()
279 dst[*olen] = 0; in SoftBusBase64Encode()
292 *olen = 0; in SoftBusBase64Decode()
311 *olen += outlen; in SoftBusBase64Decode()
318 *olen += outlen; in SoftBusBase64Decode()
[all …]
/ohos5.0/foundation/communication/dsoftbus/tests/adapter/unittest/
H A Ddsoftbus_crypto_test.cpp58 size_t olen = 10; variable
62 encodeLen = olen;
63 memcpy_s(encodeStr, olen, dst, olen);
76 size_t olen = 10; variable
97 size_t olen = 10; variable
116 size_t olen = 10; variable
132 size_t olen = 10; variable
135 int32_t ret = SoftBusBase64Decode(NULL, dlen, &olen, (unsigned char *)src, slen);
141 ret = SoftBusBase64Decode((unsigned char *)dst, dlen, &olen, NULL, slen);
156 size_t olen = 10; variable
[all …]
/ohos5.0/foundation/communication/dhcp/test/unittest/services/dhcp_server/unittest/
H A Ddhcp_message_sim.cpp183 uint8_t *current = msg->packet.options, olen = MAGIC_COOKIE_LENGTH; in ParseDhcpOptions() local
185 if (memcpy_s(current, olen, &cookie, olen) != EOK) { in ParseDhcpOptions()
189 replyOptsLength += olen; in ParseDhcpOptions()
190 current += olen; in ParseDhcpOptions()
194 olen = OPT_HEADER_LENGTH + 1; in ParseDhcpOptions()
196 olen = OPT_HEADER_LENGTH + pNode->option.length; in ParseDhcpOptions()
198 if (memcpy_s(current, olen, &pNode->option, olen) != EOK) { in ParseDhcpOptions()
203 current += olen; in ParseDhcpOptions()
204 replyOptsLength += olen; in ParseDhcpOptions()
/ohos5.0/foundation/communication/dsoftbus/tests/core/transmission/common/mock/src/
H A Dtrans_common_mock.cpp51 int32_t SoftBusBase64Encode(unsigned char *dst, size_t dlen, size_t *olen, const unsigned char *src… in SoftBusBase64Encode() argument
53 return GetCommonInterface()->SoftBusBase64Encode(dst, dlen, olen, src, slen); in SoftBusBase64Encode()
56 int32_t SoftBusBase64Decode(unsigned char *dst, size_t dlen, size_t *olen, const unsigned char *src… in SoftBusBase64Decode() argument
58 return GetCommonInterface()->SoftBusBase64Decode(dst, dlen, olen, src, slen); in SoftBusBase64Decode()
/ohos5.0/foundation/communication/dsoftbus/adapter/common/mbedtls/
H A Dsoftbus_adapter_crypto.c164 size_t *olen, const unsigned char *src, size_t slen) in SoftBusBase64Encode() argument
166 if (dst == NULL || dlen == 0 || olen == NULL || src == NULL || slen == 0) { in SoftBusBase64Encode()
170 return mbedtls_base64_encode(dst, dlen, olen, src, slen); in SoftBusBase64Encode()
174 size_t *olen, const unsigned char *src, size_t slen) in SoftBusBase64Decode() argument
176 if (dst == NULL || dlen == 0 || olen == NULL || src == NULL || slen == 0) { in SoftBusBase64Decode()
180 return mbedtls_base64_decode(dst, dlen, olen, src, slen); in SoftBusBase64Decode()
/ohos5.0/base/security/huks/frameworks/crypto_lite/cipher/src/
H A Dcipher_aes.c60 static char *MallocDecodeData(const char *text, size_t *olen) in MallocDecodeData() argument
77 if (mbedtls_base64_decode((unsigned char *)decData, decodeLen + 1, olen, in MallocDecodeData()
86 static char *MallocEncodeData(const unsigned char *text, size_t *olen) in MallocEncodeData() argument
89 int32_t ret = mbedtls_base64_encode(NULL, 0, &dataLen, text, *olen); in MallocEncodeData()
103 if (mbedtls_base64_encode((unsigned char *)(encData), dataLen, olen, text, *olen) != 0) { in MallocEncodeData()
/ohos5.0/foundation/communication/dsoftbus/tests/core/transmission/common/mock/include/
H A Dtrans_common_mock.h34 size_t *olen, const unsigned char *src, size_t slen) = 0;
36 size_t *olen, const unsigned char *src, size_t slen) = 0;
/ohos5.0/foundation/communication/dsoftbus/adapter/common/include/
H A Dsoftbus_adapter_crypto.h66 size_t *olen, const unsigned char *src, size_t slen);
69 size_t *olen, const unsigned char *src, size_t slen);
/ohos5.0/base/security/huks/frameworks/huks_standard/main/crypto_engine/mbedtls/src/
H A Dhks_mbedtls_aes.c443 size_t olen = (size_t)cipherText->size; in AesCbcPkcs7CryptFinal() local
451 cipherText->size = olen + finish_olen; in AesCbcPkcs7CryptFinal()
1083 size_t olen; in AesCtrCryptUpdate()
1090 cipherText->size = olen; in AesCtrCryptUpdate()
1106 size_t olen = (size_t)cipherText->size; in AesCtrCryptFinal() local
1117 ret = mbedtls_cipher_finish(ctrCtx, cipherText->data + olen, &finish_olen); in AesCtrCryptFinal()
1123 cipherText->size = (uint32_t)(olen + finish_olen); in AesCtrCryptFinal()
1279 size_t olen; in AesEcbNoPaddingData() local
1286 *olenTotal += olen; in AesEcbNoPaddingData()
1351 size_t olen = olenTotal; in AesEcbNoPaddingCryptFinal() local
[all …]
/ohos5.0/foundation/communication/dsoftbus/tests/core/connection/wifi_direct_cpp/
H A Dwifi_direct_mock.cpp167 int32_t SoftBusBase64Encode(unsigned char *dst, size_t dlen, size_t *olen, const unsigned char *src… in SoftBusBase64Encode() argument
169 …return OHOS::SoftBus::WifiDirectInterfaceMock::GetMock()->SoftBusBase64Encode(dst, dlen, olen, src… in SoftBusBase64Encode()
197 int32_t SoftBusBase64Decode(unsigned char *dst, size_t dlen, size_t *olen, const unsigned char *src… in SoftBusBase64Decode() argument
199 …return OHOS::SoftBus::WifiDirectInterfaceMock::GetMock()->SoftBusBase64Decode(dst, dlen, olen, src… in SoftBusBase64Decode()
H A Dwifi_direct_mock.h69 virtual int32_t SoftBusBase64Encode(unsigned char *dst, size_t dlen, size_t *olen,
82 virtual int32_t SoftBusBase64Decode(unsigned char *dst, size_t dlen, size_t *olen,
/ohos5.0/foundation/communication/dhcp/services/dhcp_server/src/
H A Ddhcp_s_server.cpp1810 uint8_t *current = reply->packet.options, olen = MAGIC_COOKIE_LENGTH; in ParseReplyOptions() local
1813 if (memcpy_s(current, remainingSize, &cookie, olen) != EOK) { in ParseReplyOptions()
1817 replyOptsLength += olen; in ParseReplyOptions()
1818 remainingSize -= olen; in ParseReplyOptions()
1819 current += olen; in ParseReplyOptions()
1823 olen = OPT_HEADER_LENGTH + 1; in ParseReplyOptions()
1825 olen = OPT_HEADER_LENGTH + pNode->option.length; in ParseReplyOptions()
1827 if (memcpy_s(current, remainingSize, &pNode->option, olen) != EOK) { in ParseReplyOptions()
1832 remainingSize -= olen; in ParseReplyOptions()
1833 current += olen; in ParseReplyOptions()
[all …]
/ohos5.0/docs/zh-cn/device-dev/porting/
H A Dporting-minichip-subsys-security.md77 int mbedtls_hardware_poll( void *data,unsigned char *output, size_t len, size_t *olen );
/ohos5.0/docs/en/device-dev/porting/
H A Dporting-minichip-subsys-security.md80 int mbedtls_hardware_poll( void *data,unsigned char *output, size_t len, size_t *olen );