9428 Commits

Author SHA1 Message Date
Angus Gratton
8d1a99e026 paritition_table: Verify the partition table md5sum when loading the app
Additionally, always enable the partition MD5 check if flash encryption is on in
Release mode. This ensures the partition table ciphertext has not been modified
(CVE-2021-27926).

The exception is pre-V3.1 ESP-IDF bootloaders and partition tables, which
don't have support for the MD5 entry.
2021-06-02 16:31:19 +10:00
Jakob Hasse
aba87df4f2 [system]: Made longjmp save for context switch
* Patched longjmp to be context-switch safe
  longjmp modifies the windowbase and windowstart
  registers, which isn't safe if a context switch
  occurs during the modification. After a context
  switch, windowstart and windowbase will be
  different, leading to a wrongly set windowstart
  bit due to longjmp writing it based on the
  windowbase before the context switch. This
  corrupts the registers at the next window
  overflow reaching that wrongly set bit.

  The solution is to disable interrupts during
  this code. It is only 6 instructions long,
  the impact shouldn't be significant.

  The fix is implemented as a wrapper which
  replaces the original first instructions of
  longjmp which are buggy. Then, it jumps back
  to execute the rest of the original longjmp
  function.

  Added a comparably reliable test to the
  test apps.
2021-06-01 07:38:50 +00:00
Jakob Hasse
ba11976efb [C++]: wrapper functions around unwind code
* Replaced all C++ exception related
  functions with wrappers if -fno-exception
  is used. This prevents linking of the
  corresponding code in libgcc. The code
  size will decrease by around 7-9 KB when
  building with -fno-exception.
* added no except test app

Closes https://github.com/espressif/esp-idf/pull/5380
Closes https://github.com/espressif/esp-idf/issues/5363
Closes https://github.com/espressif/esp-idf/issues/5224
Closes IDFGH-3153
Closes IDF-2577
2021-06-01 14:51:15 +08:00
aleks
998b67094b freemodbus: increase max priority of modbus tasks
allows to avoid issues with modbus processing when higher priority tasks are used in user application
2021-05-31 12:20:15 +02:00
Michael (XIAO Xufeng)
1ddac24b0a ci: decrease the flash performance threshold 2021-05-27 14:07:01 +08:00
Jiang Jiang Jian
3c3eab0bd8 Merge branch 'bugfix/fix_set_channel_error_after_wifi_stop_v4.1' into 'release/v4.1'
esp_wifi: Fix setting channel error after WiFi stop (backport v4.1)

See merge request espressif/esp-idf!13449
2021-05-25 14:53:11 +00:00
Jiang Jiang Jian
2a63d1058e Merge branch 'nimble/fix_ble_sm_sc_pub_key_v4.1' into 'release/v4.1'
NimBLE: Fix MITM vulnerability and free AES context (v4.1)

See merge request espressif/esp-idf!13598
2021-05-25 14:52:59 +00:00
Prasad Alatkar
3319702355 NimBLE: Fix MITM vulnerability and free AES context (v4.1) 2021-05-25 14:47:22 +05:30
xiongweichao
7c53e88b05 Remove btc_hf_idx_by_bdaddr in both btc_hf_init and btc_hf_deinit functions 2021-05-25 09:00:09 +00:00
xiongweichao
5b5a36a7b2 fix ag use dynamic memory error 2021-05-25 09:00:09 +00:00
David Cermak
6aa902c509 MQTT: Update submodule reference to support new config modes
* Queueing publish messages to outbox when the client is not connected (default=off -> messages are queued if disconnected)
* Use of incremental msg-id instead of random id (default=off -> msg-id uses platform_random())
* Posting a new event-id if a queued message gets deleted from the outbox (default=off -> events are not posted)

Detailed description of included `esp-mqtt` changes
(da850b0add1e71b3659bfac5d797cc834dc3e89b...9ea804e0ab5368d5ab53ae2301a5fec9d1f12f1a)
* mqtt: Remove unused mqtt_header_state_t
  - esp-mqtt commit: b7158a4aea
  - esp-mqtt MR: espressif/esp-mqtt!84
  - Merges https://github.com/espressif/esp-mqtt/pull/180
* Cleanup public include dirs
  - esp-mqtt commit: f65d5d05db
  - esp-mqtt MR: espressif/esp-mqtt!85
* Config: Add a new option to use incremental message id
  - esp-mqtt commit: 8bb4a26f46
  - esp-mqtt MR: espressif/esp-mqtt!85
  - Closes https://github.com/espressif/esp-mqtt/issues/176
* Publish: Add new API to enqueue qos>0 messages
  - esp-mqtt commit: dc7fd5c0b1
  - esp-mqtt MR: espressif/esp-mqtt!85
  - Closes https://github.com/espressif/esp-mqtt/issues/155
* Config: Add a new option to disable publishing when disconnected
  - esp-mqtt commit: f44dcb1c26
  - esp-mqtt MR: espressif/esp-mqtt!85
  - Related https://github.com/espressif/esp-mqtt/issues/177
* Events: Add new event to report deleted messages from outbox
  - esp-mqtt commit: 2e35d4d4d5
  - esp-mqtt MR: espressif/esp-mqtt!85
* Publish: Allow for qos=0 messages to be stored using esp_mqtt_client_enqueue()
  - esp-mqtt commit: e2de0f3e3e
  - esp-mqtt MR: espressif/esp-mqtt!85
2021-05-25 09:56:29 +02:00
morris
bf9587132b esp_eth: restart negotiation in esp_eth_start 2021-05-25 15:26:09 +08:00
Prasad Alatkar
98116a627e NimBLE: Update submodule to fix host flow control bugs. 2021-05-18 18:46:26 +05:30
Prasad Alatkar
842a55cda3 NimBLE: Fix host flow control in NimBLE porting layer.
- Register `ble_hs_flow_acl_free` callback in NimBLE porting layer.
2021-05-17 19:53:37 +05:30
Marius Vikhammer
5241d68bf4 timer: add IRAM_ATTR to spinlock give/take API
Closes https://github.com/espressif/esp-idf/issues/6824
2021-05-13 16:07:01 +08:00
Jiang Jiang Jian
b1a5c00ee7 Merge branch 'bugfix/gtk_reinstallation_fix_v4.1' into 'release/v4.1'
wpa_supplicant: Prevent reinstallation of an already in-use group key (v4.1)

See merge request espressif/esp-idf!13183
2021-05-13 07:35:05 +00:00
Hrudaynath Dhabe
e1af1fe126 wpa_supplicant: Group key reinstallation fixes
This commit reverts previous commit for GTK reinstallation fix
and corrects original fix.
2021-05-13 15:34:58 +08:00
Angus Gratton
966e45598b Merge branch 'bugfix/otatool_wrong_switch_ota_partition_slots_v4.1' into 'release/v4.1'
otatool: Fix incorrect using otadata.seq&crc in switch_ota_partition cmd (v4.1)

See merge request espressif/esp-idf!13369
2021-05-11 02:10:07 +00:00
Ivan Grokhotkov
ad9987f859 esp_pm: fix formatting issues in esp_pm_dump_locks
- line was truncated because 64 characters were not sufficient
- length passed to snprintf should be full buffer length, not -1
- make the width of lock name field fixed
- fix alignment of lock type column
2021-05-10 16:29:29 +00:00
Jiang Jiang Jian
0f1801d6b4 Merge branch 'bugfix/backport_some_lwip_bugs_0428_v4.1' into 'release/v4.1'
lw-ip:backport bugfix lwip for v4.1(backport 4.1)

See merge request espressif/esp-idf!13377
2021-05-10 05:37:29 +00:00
Jiang Jiang Jian
d3f11b1e9d Merge branch 'bugfix/fix_uart_set_rx_timeout_feature_v41' into 'release/v4.1'
Bugfix/fix uart set rx timeout feature (backport v4.1)

See merge request espressif/esp-idf!11538
2021-05-10 03:41:08 +00:00
Alex Lisitsyn
538117a904 Bugfix/fix uart set rx timeout feature (backport v4.1) 2021-05-10 11:41:02 +08:00
Jiang Jiang Jian
099daf7873 Merge branch 'bugfix/fix_gpio_wakeup_light_sleep_backport_v4.1' into 'release/v4.1'
bugfix: gpio can't wakeup light sleep (backport v4.1)

See merge request espressif/esp-idf!12884
2021-05-10 03:37:28 +00:00
Jiang Jiang Jian
932ac7abf1 Merge branch 'nimble/add_error_prints_acl_buf_v4.1' into 'release/v4.1'
NimBLE: Add error prints for ACL buffer exhaustion in NPL (v4.1)

See merge request espressif/esp-idf!12970
2021-05-10 03:28:06 +00:00
Jiang Jiang Jian
2ac583cd12 Merge branch 'bugfix/endianness_in_output_or_input_oob_v4.1' into 'release/v4.1'
ble_mesh: stack: Fix endianness error in output or input oob data of number (v4.1)

See merge request espressif/esp-idf!13256
2021-05-10 03:27:40 +00:00
Jiang Jiang Jian
db84ddc82f Merge branch 'bugfix/btdm_fix_multi-con_pair_failed_and_cancle_con_state_err_v4.1' into 'release/v4.1'
fix multi con pair failed and cancel con state error (backport v4.1)

See merge request espressif/esp-idf!13476
2021-05-08 13:01:33 +00:00
wangjialiang
f50680310e ble_mesh: stack: Fix provisioning input or output count number should be at least 1
Closes https://github.com/espressif/esp-idf/issues/6863
2021-05-08 12:01:11 +08:00
zwj
3d6b03d98c update con state when getting connection cancle complete 2021-05-07 20:51:55 +08:00
zwj
f4cadc56c0 fix multi-connection pair failed 2021-05-07 20:51:43 +08:00
Prasad Alatkar
13756c6a55 NimBLE: Add error prints for ACL buffer exhaustion in NPL 2021-05-07 09:47:01 +00:00
wangjialiang
1b3ac526a7 ble_mesh: stack: Fix endianness error in output or input oob data of number
Closes https://github.com/espressif/esp-idf/issues/6862
2021-05-07 03:35:42 +00:00
Michael (XIAO Xufeng)
9a8dbbc281 Merge branch 'bugfix/spi_fix_duplex_switch_v4.1' into 'release/v4.1'
spi_master: fix duplex mode switch issue for multi devices (4.1)

See merge request espressif/esp-idf!11234
2021-05-06 07:45:29 +00:00
xiehang
b8520d0c9c esp_wifi: Fix setting channel error after WiFi stop 2021-05-06 11:52:26 +08:00
Angus Gratton
189c04279c freertos: Check for arithmetic overflows on queue creation
Addition overflow check is from FreeRTOS kernel commit 47338393f1f79558f6144213409f09f81d7c4837
2021-05-04 18:35:38 +10:00
Angus Gratton
57ff3f92a5 esptool: Update to fix espsecure.py sign_data default version argument
Regression in Secure Boot signing, reported at https://github.com/espressif/esp-idf/issues/6831
2021-05-03 04:44:50 +00:00
Jiang Jiang Jian
da66ddd4c1 Merge branch 'bugfix/remove_redundant_other_core_cache_disable_v4.1' into 'release/v4.1'
[system]: Remove redundant othercore cache disable (backport v4.1)

See merge request espressif/esp-idf!13358
2021-04-30 09:18:03 +00:00
Jiang Jiang Jian
cc9d0e1e99 Merge branch 'bugfix/wifi_softap_deep_sleep_current_opt_v4.1' into 'release/v4.1'
backport v4.1: optimize deep sleep current in wifi softap mode

See merge request espressif/esp-idf!13396
2021-04-30 02:50:50 +00:00
xueyunfei
72b35dec11 backport bugfix lwip for v4.1 2021-04-29 13:03:26 +00:00
Li Shuai
f417181e62 deep sleep: optimize sleep current in wifi softap mode 2021-04-29 14:14:15 +08:00
Shubham Kulkarni
22ca7adccb esp_http_client_read: Add check for esp_http_client_is_complete_data_received before returning ESP_FAIL
Closes: https://github.com/espressif/esp-idf/issues/6772
2021-04-28 05:00:33 +00:00
KonstantinKondrashov
544fa05bd1 otatool: Fix incorrect using otadata.seq&crc in switch_ota_partition cmd
Closes: https://github.com/espressif/esp-idf/issues/6773
2021-04-27 19:41:17 +08:00
wuzhenghui
dcd6e82826 remove othercore cache disable 2021-04-27 14:37:45 +08:00
William Ferguson
13b0633e8d [cxx]: fixed extern "C" declarations
* Moving #includes above
  #ifdef __cplusplus extern "C" { #endif
  So that we can compile with CPP.

Signed-off-by: Jakob Hasse <jakob.hasse@espressif.com>

Merges https://github.com/espressif/esp-idf/pull/6634
2021-04-23 07:35:47 +00:00
Angus Gratton
fe5c9bb03e Merge branch 'bugfix/calc_8m_freq_test_v4.1' into 'release/v4.1'
rtc: increase CI acceptance range for calc 8M test (v4.1)

See merge request espressif/esp-idf!13087
2021-04-23 07:32:03 +00:00
baohongde
12b6656d90 Synchronize multiple branch of bt-lib 2021-04-21 05:29:48 +00:00
xiongweichao
c1215f27ed Modify E8192 ELx200 ELx40 log level to LOGD 2021-04-21 05:29:48 +00:00
Marius Vikhammer
7e839a82de docs: fix doxygen compile warnings for doxygen 1.9.1
Newer versions of doxygen will give warnings for comments in
INPUT lists

Delete all comment lines to fix these warnings, our folder structure
stil gives an OK overview of what we are including
2021-04-12 08:44:06 +08:00
Marius Vikhammer
02ce0744f0 rtc: increase CI acceptance range for calc 8M test 2021-04-09 15:06:37 +08:00
David Čermák
a92185263e Merge branch 'bugfix/esp_netif_ppp_event_data_v4.1' into 'release/v4.1'
esp-netif: Fix PPP netif event posting to include esp_netif data (v4.1)

See merge request espressif/esp-idf!11869
2021-03-31 14:25:04 +00:00
Shubham Kulkarni
9933037c0d Add options for esp_http_client and esp_websocket_client to support keepalive 2021-03-31 05:44:48 +00:00