/third_party/mbedtls/programs/cipher/ |
D | cipher_aead_demo.c | 128 size_t *tag_len) in aead_prepare() argument 136 *tag_len = 16; in aead_prepare() 139 *tag_len = 16; in aead_prepare() 142 *tag_len = 8; in aead_prepare() 145 *tag_len = 16; in aead_prepare() 169 static void aead_info(const mbedtls_cipher_context_t *ctx, size_t tag_len) in aead_info() argument 182 ciph, key_bits, mode_str, (unsigned) tag_len); in aead_info() 188 static int aead_encrypt(mbedtls_cipher_context_t *ctx, size_t tag_len, in aead_encrypt() argument 209 CHK(mbedtls_cipher_write_tag(ctx, p, tag_len)); in aead_encrypt() 210 p += tag_len; in aead_encrypt() [all …]
|
/third_party/libsnd/src/ |
D | ogg_vcomment.c | 76 size_t tag_size, tag_len = 0 ; in vorbiscomment_read_tags() local 111 tag_len = read_32bit_size_t (p) ; in vorbiscomment_read_tags() 113 if (tag_len > 0) in vorbiscomment_read_tags() 115 if (p + tag_len + 4 > ep) in vorbiscomment_read_tags() 119 if (tag_len > tag_size - 1) in vorbiscomment_read_tags() 121 tag_size = tag_len + 1 ; in vorbiscomment_read_tags() 127 memcpy (tag, p, tag_len) ; p += tag_len ; in vorbiscomment_read_tags() 128 tag [tag_len] = '\0' ; in vorbiscomment_read_tags() 143 tag_len = read_32bit_size_t (p) ; in vorbiscomment_read_tags() 145 if (p + tag_len > ep) in vorbiscomment_read_tags() [all …]
|
/third_party/mbedtls/library/ |
D | ccm.c | 158 if (ctx->tag_len == 0) { in ccm_calculate_first_block_if_ready() 179 ctx->y[0] |= ((ctx->tag_len - 2) / 2) << 3; in ccm_calculate_first_block_if_ready() 241 size_t tag_len) in mbedtls_ccm_set_lengths() argument 250 if (tag_len == 2 || tag_len > 16 || tag_len % 2 != 0) { in mbedtls_ccm_set_lengths() 260 ctx->tag_len = tag_len; in mbedtls_ccm_set_lengths() 347 if (ctx->tag_len != 0 && ctx->processed + input_len > ctx->plaintext_len) { in mbedtls_ccm_update() 434 unsigned char *tag, size_t tag_len) in mbedtls_ccm_finish() argument 463 memcpy(tag, ctx->y, tag_len); in mbedtls_ccm_finish() 477 unsigned char *tag, size_t tag_len) in ccm_auth_crypt() argument 486 if ((ret = mbedtls_ccm_set_lengths(ctx, add_len, length, tag_len)) != 0) { in ccm_auth_crypt() [all …]
|
D | cipher.c | 1085 unsigned char *tag, size_t tag_len) in mbedtls_cipher_write_tag() argument 1111 tag, tag_len); in mbedtls_cipher_write_tag() 1118 if (tag_len != 16U) { in mbedtls_cipher_write_tag() 1131 const unsigned char *tag, size_t tag_len) in mbedtls_cipher_check_tag() argument 1162 if (tag_len > sizeof(check_tag)) { in mbedtls_cipher_check_tag() 1169 check_tag, tag_len))) { in mbedtls_cipher_check_tag() 1174 if (mbedtls_ct_memcmp(tag, check_tag, tag_len) != 0) { in mbedtls_cipher_check_tag() 1184 if (tag_len != sizeof(check_tag)) { in mbedtls_cipher_check_tag() 1195 if (mbedtls_ct_memcmp(tag, check_tag, tag_len) != 0) { in mbedtls_cipher_check_tag() 1203 mbedtls_platform_zeroize(check_tag, tag_len); in mbedtls_cipher_check_tag() [all …]
|
D | gcm.c | 509 unsigned char *tag, size_t tag_len) in mbedtls_gcm_finish() argument 528 if (tag_len > 16 || tag_len < 4) { in mbedtls_gcm_finish() 536 memcpy(tag, ctx->base_ectr, tag_len); in mbedtls_gcm_finish() 550 mbedtls_xor(tag, tag, ctx->buf, tag_len); in mbedtls_gcm_finish() 565 size_t tag_len, in mbedtls_gcm_crypt_and_tag() argument 584 if ((ret = mbedtls_gcm_finish(ctx, NULL, 0, &olen, tag, tag_len)) != 0) { in mbedtls_gcm_crypt_and_tag() 598 size_t tag_len, in mbedtls_gcm_auth_decrypt() argument 609 input, output, tag_len, check_tag)) != 0) { in mbedtls_gcm_auth_decrypt() 614 for (diff = 0, i = 0; i < tag_len; i++) { in mbedtls_gcm_auth_decrypt()
|
/third_party/mbedtls/include/mbedtls/ |
D | ccm.h | 83 size_t MBEDTLS_PRIVATE(tag_len); /*!< Total tag length */ 182 unsigned char *tag, size_t tag_len); 231 unsigned char *tag, size_t tag_len); 268 const unsigned char *tag, size_t tag_len); 314 const unsigned char *tag, size_t tag_len); 379 size_t tag_len); 515 unsigned char *tag, size_t tag_len);
|
D | gcm.h | 173 size_t tag_len, 216 size_t tag_len, 354 unsigned char *tag, size_t tag_len);
|
D | cipher.h | 1012 unsigned char *tag, size_t tag_len); 1028 const unsigned char *tag, size_t tag_len); 1119 size_t *olen, size_t tag_len); 1175 size_t *olen, size_t tag_len);
|
/third_party/libcoap/src/oscore/ |
D | oscore_cose.c | 425 size_t tag_len = cose_tag_len(ptr->alg); in cose_encrypt0_encrypt() local 426 size_t max_result_len = ptr->plaintext.length + tag_len; in cose_encrypt0_encrypt() 439 (ptr->plaintext.length + tag_len) > ciphertext_len) { in cose_encrypt0_encrypt() 447 params.params.aes.tag_len = tag_len; in cose_encrypt0_encrypt() 465 size_t tag_len = cose_tag_len(ptr->alg); in cose_encrypt0_decrypt() local 466 size_t max_result_len = ptr->ciphertext.length - tag_len; in cose_encrypt0_decrypt() 479 ptr->ciphertext.length > (plaintext_len + tag_len)) { in cose_encrypt0_decrypt() 487 params.params.aes.tag_len = tag_len; in cose_encrypt0_decrypt()
|
/third_party/mbedtls/tests/scripts/ |
D | gen_gcm_encrypt.pl | 67 my $tag_len = get_suite_val("Taglen"); 79 print("GCM NIST Validation (AES-$key_len,$iv_len,$pt_len,$add_len,$tag_len) #$Count\n"); 86 print(":$tag_len");
|
D | gen_gcm_decrypt.pl | 84 my $tag_len = get_suite_val("Taglen"); 96 print("GCM NIST Validation (AES-$key_len,$iv_len,$pt_len,$add_len,$tag_len) #$Count\n"); 102 print(":$tag_len");
|
/third_party/openssl/test/ |
D | aesgcmtest.c | 39 unsigned char *tag, int *tag_len) in do_encrypt() argument 46 *tag_len = 16; in do_encrypt() 67 int ct_len, const unsigned char *tag, int tag_len) in do_decrypt() argument 85 tag_len, (void *)tag) > 0) in do_decrypt()
|
D | acvp_test.c | 722 const unsigned char *tag, size_t tag_len, in aes_ccm_enc_dec() argument 739 || !TEST_int_gt(EVP_CIPHER_CTX_ctrl(ctx, EVP_CTRL_AEAD_SET_TAG, tag_len, in aes_ccm_enc_dec() 757 tag_len, out + out_len), 0) in aes_ccm_enc_dec() 759 || !TEST_mem_eq(out + out_len, tag_len, tag, tag_len)) in aes_ccm_enc_dec() 778 const size_t tag_len = tst->ct_len - tst->pt_len; in aes_ccm_enc_dec_test() local 779 const size_t ct_len = tst->ct_len - tag_len; in aes_ccm_enc_dec_test() 790 tst->ct, ct_len, tag, tag_len, enc, pass) in aes_ccm_enc_dec_test() 794 tst->pt, tst->pt_len, tag, tag_len, !enc, pass) in aes_ccm_enc_dec_test() 800 tag - 1, tag_len, !enc, !pass); in aes_ccm_enc_dec_test() 809 const unsigned char *tag, size_t tag_len, in aes_gcm_enc_dec() argument [all …]
|
/third_party/protobuf/python/google/protobuf/internal/ |
D | decoder.py | 234 tag_len = len(tag_bytes) 244 pos = new_pos + tag_len 448 tag_len = len(tag_bytes) 482 pos = new_pos + tag_len 593 tag_len = len(tag_bytes) 605 pos = new_pos + tag_len 634 tag_len = len(tag_bytes) 646 pos = new_pos + tag_len 676 tag_len = len(tag_bytes) 692 pos = new_pos + tag_len [all …]
|
/third_party/openssl/crypto/x509/ |
D | v3_cpols.c | 35 static int displaytext_str2tag(const char *tagstr, unsigned int *tag_len); 254 static int displaytext_str2tag(const char *tagstr, unsigned int *tag_len) in displaytext_str2tag() argument 258 *tag_len = 0; in displaytext_str2tag() 263 *tag_len = len; in displaytext_str2tag() 276 *tag_len = 0; in displaytext_str2tag() 284 unsigned int tag_len; in notice_section() local 304 tag = displaytext_str2tag(value, &tag_len); in notice_section() 307 if (tag_len != 0) in notice_section() 308 value += tag_len + 1; in notice_section()
|
/third_party/node/deps/openssl/openssl/crypto/x509/ |
D | v3_cpols.c | 35 static int displaytext_str2tag(const char *tagstr, unsigned int *tag_len); 254 static int displaytext_str2tag(const char *tagstr, unsigned int *tag_len) in displaytext_str2tag() argument 258 *tag_len = 0; in displaytext_str2tag() 263 *tag_len = len; in displaytext_str2tag() 276 *tag_len = 0; in displaytext_str2tag() 284 unsigned int tag_len; in notice_section() local 304 tag = displaytext_str2tag(value, &tag_len); in notice_section() 307 if (tag_len != 0) in notice_section() 308 value += tag_len + 1; in notice_section()
|
/third_party/node/src/crypto/ |
D | crypto_cipher.cc | 50 bool IsValidGCMTagLength(unsigned int tag_len) { in IsValidGCMTagLength() argument 51 return tag_len == 4 || tag_len == 8 || (tag_len >= 12 && tag_len <= 16); in IsValidGCMTagLength() 690 unsigned int tag_len = auth_tag.size(); in Init() local 697 cipher->auth_tag_len_ == tag_len) && in Init() 698 IsValidGCMTagLength(tag_len); in Init() 704 is_valid = cipher->auth_tag_len_ == tag_len; in Init() 709 env, "Invalid authentication tag length: %u", tag_len); in Init() 712 cipher->auth_tag_len_ = tag_len; in Init()
|
D | crypto_aes.cc | 85 size_t tag_len = 0; in AES_Cipher() local 105 tag_len = params.length; in AES_Cipher() 113 int buf_len = in.size() + EVP_CIPHER_CTX_block_size(ctx.get()) + tag_len; in AES_Cipher() 161 tag_len, in AES_Cipher() 164 total += tag_len; in AES_Cipher()
|
/third_party/mbedtls/tests/suites/ |
D | test_suite_gcm.function | 172 size_t tag_len = tag_len_bits / 8; 181 add_str->x, add_str->len, src_str->x, output, tag_len, 199 size_t tag_len = tag_len_bits / 8; 213 output, tag_len, tag_output) == 0); 216 ASSERT_COMPARE(tag_output, tag_len, tag->x, tag->len); 246 size_t tag_len = tag_len_bits / 8; 264 tag_len,
|
/third_party/rust/crates/nom/src/bytes/ |
D | streaming.rs | 39 let tag_len = tag.input_len(); in tag() localVariable 43 CompareResult::Ok => Ok(i.take_split(tag_len)), in tag() 44 CompareResult::Incomplete => Err(Err::Incomplete(Needed::new(tag_len - i.input_len()))), in tag() 81 let tag_len = tag.input_len(); in tag_no_case() localVariable 85 CompareResult::Ok => Ok(i.take_split(tag_len)), in tag_no_case() 86 CompareResult::Incomplete => Err(Err::Incomplete(Needed::new(tag_len - i.input_len()))), in tag_no_case()
|
/third_party/libwebsockets/lib/misc/cache-ttl/ |
D | lws-cache-ttl.c | 267 walk_ctx->tag_len = lws_ser_ru32be(walk_ctx->ptr + 4); in lws_cache_results_walk() 270 walk_ctx->ptr += walk_ctx->tag_len + 1 + 8; in lws_cache_results_walk() 271 walk_ctx->size -= walk_ctx->tag_len + 1 + 8; in lws_cache_results_walk()
|
/third_party/ffmpeg/libavformat/ |
D | swfenc.c | 69 int tag_len, tag; in put_swf_end_tag() local 72 tag_len = pos - swf->tag_pos - 2; in put_swf_end_tag() 78 avio_wl32(pb, tag_len - 4); in put_swf_end_tag() 80 av_assert0(tag_len < 0x3f); in put_swf_end_tag() 81 avio_wl16(pb, (tag << 6) | tag_len); in put_swf_end_tag()
|
D | omadec.c | 560 unsigned tag_len = 0; in oma_read_probe() local 563 tag_len = ff_id3v2_tag_len(buf); in oma_read_probe() 566 if (p->buf_size < tag_len + 5) in oma_read_probe() 568 return tag_len ? AVPROBE_SCORE_EXTENSION/2 : 0; in oma_read_probe() 570 buf += tag_len; in oma_read_probe()
|
/third_party/musl/Benchmark/musl/ |
D | libc_hilog.cpp | 55 uint16_t tag_len : 6; /* include '\0' */ member 118 header->tag_len = tagLen; in SendMessage()
|
/third_party/libwebsockets/lib/tls/mbedtls/ |
D | mbedtls-extensions.c | 286 size_t len, tag_len; in lws_x509_get_general_names() local 306 r = mbedtls_asn1_get_len(p, end, &tag_len); in lws_x509_get_general_names() 359 buf->MBEDTLS_PRIVATE_V30_ONLY(len) = tag_len; in lws_x509_get_general_names()
|