/hal_espressif-3.6.0/components/bt/common/btc/profile/esp/blufi/ |
D | blufi_prf.c | 121 ret = blufi_env.cbs->decrypt_func(hdr->seq, hdr->data, hdr->data_len); in btc_blufi_recv_handler() 122 if (ret != hdr->data_len) { /* enc must be success and enc len must equal to plain len */ in btc_blufi_recv_handler() 132 checksum = blufi_env.cbs->checksum_func(hdr->seq, &hdr->seq, hdr->data_len + 2); in btc_blufi_recv_handler() 133 checksum_pkt = hdr->data[hdr->data_len] | (((uint16_t) hdr->data[hdr->data_len + 1]) << 8); in btc_blufi_recv_handler() 155 if (blufi_env.offset + hdr->data_len - 2 <= blufi_env.total_len){ in btc_blufi_recv_handler() 156 memcpy(blufi_env.aggr_buf + blufi_env.offset, hdr->data + 2, hdr->data_len - 2); in btc_blufi_recv_handler() 157 blufi_env.offset += (hdr->data_len - 2); in btc_blufi_recv_handler() 166 memcpy(blufi_env.aggr_buf + blufi_env.offset, hdr->data, hdr->data_len); in btc_blufi_recv_handler() 173 btc_blufi_protocol_handler(hdr->type, hdr->data, hdr->data_len); in btc_blufi_recv_handler() 198 hdr->data_len = blufi_env.frag_size + 2; in btc_blufi_send_encap() [all …]
|
/hal_espressif-3.6.0/components/esp_wifi/include/ |
D | esp_wifi_crypto_types.h | 65 …8_encrypt_t)(const unsigned char *key, const unsigned char *iv, unsigned char *data, int data_len); 76 …8_decrypt_t)(const unsigned char *key, const unsigned char *iv, unsigned char *data, int data_len); 127 … const unsigned char *data, int data_len, unsigned char *buf, int buf_len); 140 unsigned int data_len, unsigned char *mac); 167 unsigned int data_len, unsigned char *mac); 199 … const unsigned char *data, unsigned int data_len, unsigned char *buf, unsigned int buf_len); 246 unsigned char *data, unsigned int data_len); 319 typedef int (*esp_omac1_aes_128_t)(const uint8_t *key, const uint8_t *data, size_t data_len, 335 const uint8_t *data, size_t data_len,
|
/hal_espressif-3.6.0/components/espcoredump/src/ |
D | core_dump_elf.c | 164 int data_len = data_sz; in elf_add_segment() local 169 ALIGN(4, data_len); in elf_add_segment() 173 return data_len + sizeof(elf_phdr); in elf_add_segment() 179 seg_hdr.p_filesz = data_len; in elf_add_segment() 180 seg_hdr.p_memsz = data_len; in elf_add_segment() 185 self->elf_next_data_offset += data_len; in elf_add_segment() 189 (uint32_t)data_len, self->elf_next_data_offset); in elf_add_segment() 192 err = self->write_cfg->write(self->write_cfg->priv, data, (uint32_t)data_len); in elf_add_segment() 195 self->elf_next_data_offset += data_len; in elf_add_segment() 196 return data_len; in elf_add_segment() [all …]
|
D | core_dump_binary.c | 96 uint32_t data_len = 0; in esp_core_dump_write_binary() local 122 data_len += esp_core_dump_get_memory_len(stk_vaddr, stk_vaddr+stk_len); in esp_core_dump_write_binary() 124 data_len += (tcb_sz + sizeof(core_dump_task_header_t)); in esp_core_dump_write_binary() 128 data_len += esp_core_dump_get_memory_len(mem_seg.start, mem_seg.start+mem_seg.size); in esp_core_dump_write_binary() 129 data_len += sizeof(core_dump_mem_seg_header_t); in esp_core_dump_write_binary() 155 …data_len += sizeof(core_dump_mem_seg_header_t) + esp_core_dump_get_memory_len(start, start + data_… in esp_core_dump_write_binary() 160 data_len += sizeof(core_dump_header_t); in esp_core_dump_write_binary() 163 data_len, hdr.tasks_num, bad_tasks_num); in esp_core_dump_write_binary() 166 err = write_cfg->prepare(write_cfg->priv, &data_len); in esp_core_dump_write_binary() 183 hdr.data_len = data_len; in esp_core_dump_write_binary()
|
D | core_dump_uart.c | 68 static esp_err_t esp_core_dump_uart_write_prepare(core_dump_write_data_t *priv, uint32_t *data_len) in esp_core_dump_uart_write_prepare() argument 70 ESP_COREDUMP_ASSERT(data_len != NULL); in esp_core_dump_uart_write_prepare() 71 *data_len += esp_core_dump_checksum_size(); in esp_core_dump_uart_write_prepare() 96 …p_err_t esp_core_dump_uart_write_data(core_dump_write_data_t *priv, void * data, uint32_t data_len) in esp_core_dump_uart_write_data() argument 101 char *end = addr + data_len; in esp_core_dump_uart_write_data() 118 wr_data->off += data_len; in esp_core_dump_uart_write_data() 119 esp_core_dump_checksum_update(wr_data->checksum_ctx, data, data_len); in esp_core_dump_uart_write_data()
|
/hal_espressif-3.6.0/components/bootloader_support/src/ |
D | esp_image_format.c | 80 static esp_err_t process_segment_data(intptr_t load_addr, uint32_t data_addr, uint32_t data_len, bo… 217 for (size_t j = 0; j < data->segments[i].data_len / sizeof(uint32_t); j++) { in image_load() 489 next_addr += header->data_len; in process_segments() 522 uint32_t data_len = header->data_len; in process_segment() local 525 ESP_LOGV(TAG, "segment data length 0x%x data starts 0x%x", data_len, data_addr); in process_segment() 529 if (data_len % 4 != 0) { in process_segment() 530 FAIL_LOAD("unaligned segment length 0x%x", data_len); in process_segment() 539 data_len, data_len, in process_segment() 546 if (do_load && data_len > 0) { in process_segment() 547 if (!verify_load_addresses(index, load_addr, load_addr + data_len, true, false)) { in process_segment() [all …]
|
/hal_espressif-3.6.0/components/esptool_py/esptool/flasher_stub/ |
D | stub_flasher.c | 148 return (command->data_len == len) ? ESP_OK : ESP_BAD_DATA_LEN; in verify_data_len() 173 if (command->data_len == 4) { in cmd_loop() 193 if(command->data_len > MAX_WRITE_BLOCK+16) { in cmd_loop() 264 if (command->data_len == 16 && data_words[2] > MAX_WRITE_BLOCK) { in cmd_loop() 277 if (command->data_len == 16 && data_words[2] > MAX_WRITE_BLOCK) { in cmd_loop() 293 int payload_len = command->data_len - 16; in cmd_loop() 321 if (command->data_len % sizeof(write_reg_args_t) != 0) { in cmd_loop() 324 …error = handle_write_reg((const write_reg_args_t *)data_words, command->data_len/sizeof(write_reg_… in cmd_loop() 335 error = handle_mem_data(command->data_buf + 16, command->data_len - 16); in cmd_loop() 365 handle_flash_data(command->data_buf + 16, command->data_len - 16); in cmd_loop() [all …]
|
/hal_espressif-3.6.0/components/wpa_supplicant/src/crypto/ |
D | aes_wrap.h | 31 int __must_check omac1_aes_128(const u8 *key, const u8 *data, size_t data_len, 33 int __must_check omac1_aes_256(const u8 *key, const u8 *data, size_t data_len, 37 u8 *data, size_t data_len); 39 u8 *data, size_t data_len); 43 u8 *data, size_t data_len, u8 *tag); 47 u8 *data, size_t data_len, const u8 *tag); 49 size_t data_len); 51 size_t data_len);
|
D | crypto_mbedtls.c | 230 size_t data_len, u8 *mac) in hmac_sha384() argument 232 return hmac_sha384_vector(key, key_len, 1, &data, &data_len, mac); in hmac_sha384() 243 size_t data_len, u8 *mac) in hmac_sha256() argument 245 return hmac_sha256_vector(key, key_len, 1, &data, &data_len, mac); in hmac_sha256() 255 int hmac_md5(const u8 *key, size_t key_len, const u8 *data, size_t data_len, in hmac_md5() argument 258 return hmac_md5_vector(key, key_len, 1, &data, &data_len, mac); in hmac_md5() 268 int hmac_sha1(const u8 *key, size_t key_len, const u8 *data, size_t data_len, in hmac_sha1() argument 271 return hmac_sha1_vector(key, key_len, 1, &data, &data_len, mac); in hmac_sha1() 340 int aes_128_cbc_encrypt(const u8 *key, const u8 *iv, u8 *data, size_t data_len) in aes_128_cbc_encrypt() argument 356 data_len, cbc, data, data); in aes_128_cbc_encrypt() [all …]
|
D | aes-ctr.c | 26 u8 *data, size_t data_len) in aes_ctr_encrypt() argument 29 size_t j, len, left = data_len; in aes_ctr_encrypt() 68 u8 *data, size_t data_len) in aes_128_ctr_encrypt() argument 70 return aes_ctr_encrypt(key, 16, nonce, data, data_len); in aes_128_ctr_encrypt()
|
D | aes-siv.c | 72 size_t data_len[1]; in aes_s2v() local 78 data_len[0] = sizeof(tmp); in aes_s2v() 79 return omac1_aes_vector(key, key_len, 1, data, data_len, mac); in aes_s2v() 83 data_len[0] = sizeof(zero); in aes_s2v() 84 ret = omac1_aes_vector(key, key_len, 1, data, data_len, tmp); in aes_s2v() 114 data_len[0] = sizeof(tmp); in aes_s2v() 115 return omac1_aes_vector(key, key_len, 1, data, data_len, mac); in aes_s2v()
|
D | sha256-prf.c | 31 const u8 *data, size_t data_len, u8 *buf, size_t buf_len) in sha256_prf() argument 33 return sha256_prf_bits(key, key_len, label, data, data_len, buf, in sha256_prf() 55 const u8 *data, size_t data_len, u8 *buf, in sha256_prf_bits() argument 71 len[2] = data_len; in sha256_prf_bits()
|
D | sha384-prf.c | 31 const u8 *data, size_t data_len, u8 *buf, size_t buf_len) in sha384_prf() argument 33 return sha384_prf_bits(key, key_len, label, data, data_len, buf, in sha384_prf() 55 const u8 *data, size_t data_len, u8 *buf, in sha384_prf_bits() argument 71 len[2] = data_len; in sha384_prf_bits()
|
D | aes-cbc.c | 24 int aes_128_cbc_encrypt(const u8 *key, const u8 *iv, u8 *data, size_t data_len) in aes_128_cbc_encrypt() argument 39 blocks = data_len / AES_BLOCK_SIZE; in aes_128_cbc_encrypt() 60 int aes_128_cbc_decrypt(const u8 *key, const u8 *iv, u8 *data, size_t data_len) in aes_128_cbc_decrypt() argument 75 blocks = data_len / AES_BLOCK_SIZE; in aes_128_cbc_decrypt()
|
/hal_espressif-3.6.0/examples/bluetooth/hci/ble_adv_scan_combined/main/ |
D | app_bt.c | 190 static esp_err_t get_local_name (uint8_t *data_msg, uint8_t data_len, ble_scan_local_name_t *scanne… in get_local_name() argument 193 while (curr_ptr < data_len) { in get_local_name() 226 …uint8_t *queue_data = NULL, *event_type = NULL, *addr_type = NULL, *addr = NULL, *data_len = NULL,… in hci_evt_process() local 286 data_len = (uint8_t *)malloc(sizeof(uint8_t) * num_responses); in hci_evt_process() 287 if (data_len == NULL) { in hci_evt_process() 292 data_len[i] = queue_data[data_ptr]; in hci_evt_process() 304 for (uint8_t j = 0; j < data_len[i]; j += 1) { in hci_evt_process() 312 if (data_len == NULL) { in hci_evt_process() 323 if (data_len == NULL) { in hci_evt_process() 328 ret = get_local_name(&data_msg[data_msg_ptr], data_len[i], scanned_name); in hci_evt_process() [all …]
|
/hal_espressif-3.6.0/components/bt/host/bluedroid/stack/btm/ |
D | btm_ble_batchscan.c | 176 ble_batchscan_cb.main_rep_q.data_len[ble_batchscan_cb.main_rep_q.next_idx] = 0; in btm_ble_batchscan_enq_rep_q() 196 UINT8 data_len) in btm_ble_batchscan_enq_rep_data() argument 208 index, report_format, num_records, data_len); in btm_ble_batchscan_enq_rep_data() 210 if (index < BTM_BLE_BATCH_REP_MAIN_Q_SIZE && data_len > 0 && num_records > 0) { in btm_ble_batchscan_enq_rep_data() 211 len = ble_batchscan_cb.main_rep_q.data_len[index]; in btm_ble_batchscan_enq_rep_data() 214 p_app_data = osi_malloc(len + data_len); in btm_ble_batchscan_enq_rep_data() 216 memcpy(p_app_data + len, p_data, data_len); in btm_ble_batchscan_enq_rep_data() 220 ble_batchscan_cb.main_rep_q.data_len[index] += data_len; in btm_ble_batchscan_enq_rep_data() 222 p_app_data = osi_malloc(data_len); in btm_ble_batchscan_enq_rep_data() 223 memcpy(p_app_data, p_data, data_len); in btm_ble_batchscan_enq_rep_data() [all …]
|
D | btm_ble_adv_filter.c | 479 if (p_local_name->data_len > BTM_BLE_PF_STR_LEN_MAX) { in btm_ble_update_pf_local_name() 480 p_local_name->data_len = BTM_BLE_PF_STR_LEN_MAX; in btm_ble_update_pf_local_name() 483 ARRAY_TO_STREAM(p, p_local_name->p_data, p_local_name->data_len); in btm_ble_update_pf_local_name() 484 len += p_local_name->data_len; in btm_ble_update_pf_local_name() 579 if (p_srvc_data->data_len > (BTM_BLE_PF_STR_LEN_MAX - 2)) { in btm_ble_update_pf_manu_data() 580 p_srvc_data->data_len = (BTM_BLE_PF_STR_LEN_MAX - 2); in btm_ble_update_pf_manu_data() 583 if (p_srvc_data->data_len > 0) { in btm_ble_update_pf_manu_data() 584 ARRAY_TO_STREAM(p, p_srvc_data->p_pattern, p_srvc_data->data_len); in btm_ble_update_pf_manu_data() 585 len += (p_srvc_data->data_len); in btm_ble_update_pf_manu_data() 586 ARRAY_TO_STREAM(p, p_srvc_data->p_pattern_mask, p_srvc_data->data_len); in btm_ble_update_pf_manu_data() [all …]
|
/hal_espressif-3.6.0/components/wpa_supplicant/esp_supplicant/src/ |
D | esp_wpas_glue.c | 24 const void *data, u16 data_len, in wpa_sm_alloc_eapol() argument 30 *msg_len = sizeof(struct ieee802_1x_hdr) + data_len; in wpa_sm_alloc_eapol() 43 hdr->length = host_to_be16(data_len); in wpa_sm_alloc_eapol() 46 memcpy(hdr + 1, data, data_len); in wpa_sm_alloc_eapol() 48 memset(hdr + 1, 0, data_len); in wpa_sm_alloc_eapol()
|
/hal_espressif-3.6.0/examples/bluetooth/hci/hci_common_component/ |
D | bt_hci_common.c | 86 uint16_t make_cmd_ble_set_adv_data(uint8_t *buf, uint8_t data_len, uint8_t *p_data) in make_cmd_ble_set_adv_data() argument 94 if (p_data != NULL && data_len > 0) { in make_cmd_ble_set_adv_data() 95 if (data_len > HCIC_PARAM_SIZE_BLE_WRITE_ADV_DATA) { in make_cmd_ble_set_adv_data() 96 data_len = HCIC_PARAM_SIZE_BLE_WRITE_ADV_DATA; in make_cmd_ble_set_adv_data() 99 UINT8_TO_STREAM (buf, data_len); in make_cmd_ble_set_adv_data() 101 ARRAY_TO_STREAM (buf, p_data, data_len); in make_cmd_ble_set_adv_data()
|
/hal_espressif-3.6.0/components/esp_http_server/src/util/ |
D | ctrl_sock.c | 45 int cs_send_to_ctrl_sock(int send_fd, int port, void *data, unsigned int data_len) in cs_send_to_ctrl_sock() argument 52 ret = sendto(send_fd, data, data_len, 0, (struct sockaddr *)&to_addr, sizeof(to_addr)); in cs_send_to_ctrl_sock() 60 int cs_recv_from_ctrl_sock(int fd, void *data, unsigned int data_len) in cs_recv_from_ctrl_sock() argument 63 ret = recvfrom(fd, data, data_len, 0, NULL, NULL); in cs_recv_from_ctrl_sock()
|
/hal_espressif-3.6.0/components/esp_hw_support/port/esp32c3/ |
D | esp_hmac.c | 34 static void write_and_padd(uint8_t *block, const uint8_t *data, uint16_t data_len) in write_and_padd() argument 36 memcpy(block, data, data_len); in write_and_padd() 38 block[data_len] = 0x80; in write_and_padd() 39 bzero(block + data_len + 1, SHA256_BLOCK_SZ - data_len - 1); in write_and_padd()
|
/hal_espressif-3.6.0/components/esp_hw_support/port/esp32h2/ |
D | esp_hmac.c | 34 static void write_and_padd(uint8_t *block, const uint8_t *data, uint16_t data_len) in write_and_padd() argument 36 memcpy(block, data, data_len); in write_and_padd() 38 block[data_len] = 0x80; in write_and_padd() 39 bzero(block + data_len + 1, SHA256_BLOCK_SZ - data_len - 1); in write_and_padd()
|
/hal_espressif-3.6.0/components/esp_hw_support/port/esp32s3/ |
D | esp_hmac.c | 35 static void write_and_padd(uint8_t *block, const uint8_t *data, uint16_t data_len) in write_and_padd() argument 37 memcpy(block, data, data_len); in write_and_padd() 39 block[data_len] = 0x80; in write_and_padd() 40 bzero(block + data_len + 1, SHA256_BLOCK_SZ - data_len - 1); in write_and_padd()
|
/hal_espressif-3.6.0/components/bt/host/bluedroid/stack/hcic/ |
D | hciblecmds.c | 168 BOOLEAN btsnd_hcic_ble_set_adv_data (UINT8 data_len, UINT8 *p_data) in btsnd_hcic_ble_set_adv_data() argument 173 for (int i = 0; i < data_len; i++) { in btsnd_hcic_ble_set_adv_data() 191 if (p_data != NULL && data_len > 0) { in btsnd_hcic_ble_set_adv_data() 192 if (data_len > HCIC_PARAM_SIZE_BLE_WRITE_ADV_DATA) { in btsnd_hcic_ble_set_adv_data() 193 data_len = HCIC_PARAM_SIZE_BLE_WRITE_ADV_DATA; in btsnd_hcic_ble_set_adv_data() 197 UINT8_TO_STREAM (pp, data_len); in btsnd_hcic_ble_set_adv_data() 199 ARRAY_TO_STREAM (pp, p_data, data_len); in btsnd_hcic_ble_set_adv_data() 205 BOOLEAN btsnd_hcic_ble_set_scan_rsp_data (UINT8 data_len, UINT8 *p_scan_rsp) in btsnd_hcic_ble_set_scan_rsp_data() argument 224 if (p_scan_rsp != NULL && data_len > 0) { in btsnd_hcic_ble_set_scan_rsp_data() 226 if (data_len > HCIC_PARAM_SIZE_BLE_WRITE_SCAN_RSP ) { in btsnd_hcic_ble_set_scan_rsp_data() [all …]
|
/hal_espressif-3.6.0/examples/wifi/espnow/main/ |
D | espnow_example_main.c | 98 recv_cb->data_len = len; in example_espnow_recv_cb() 106 int example_espnow_data_parse(uint8_t *data, uint16_t data_len, uint8_t *state, uint16_t *seq, int … in example_espnow_data_parse() argument 111 if (data_len < sizeof(example_espnow_data_t)) { in example_espnow_data_parse() 112 ESP_LOGE(TAG, "Receive ESPNOW data too short, len:%d", data_len); in example_espnow_data_parse() 121 crc_cal = esp_crc16_le(UINT16_MAX, (uint8_t const *)buf, data_len); in example_espnow_data_parse() 211 …ret = example_espnow_data_parse(recv_cb->data, recv_cb->data_len, &recv_state, &recv_seq, &recv_ma… in example_espnow_task() 214 … broadcast data from: "MACSTR", len: %d", recv_seq, MAC2STR(recv_cb->mac_addr), recv_cb->data_len); in example_espnow_task() 268 …th unicast data from: "MACSTR", len: %d", recv_seq, MAC2STR(recv_cb->mac_addr), recv_cb->data_len); in example_espnow_task()
|