1. 16 2月, 2021 1 次提交
    • M
      Speed up upload by a factor of 17 (#4787) · 7e8993fc
      Mitch Bradley 提交于
      * Speed up upload by a factor of 17
      
      Uploads are very slow because of an unnecessary "client.connected()" check in _uploadReadByte().
      
      Here is what happens:
      client.connected() is called for every byte read.  WiFiClient::connected() calls recv(fd(), &dummy, 0, MSG_DONTWAIT); which takes a relatively long time, so the optimized path of returning a buffered byte via client.read() is effectively nullified.
      
      Removing the one line changed the upload speed for a 2 MB file (discarding the received data) from 22 KB/sec (before) to 367 KB/sec (after).
      
      The change is safe in the face of disconnects because client.read(), when it no longer has buffered data, calls (WiFiClient)  fillBuffer(), which calls recv(), so the disconnection will be detected in due course.
      
      * Move disconnect check into the timeout loop
      7e8993fc
  2. 01 10月, 2020 1 次提交
    • N
      Update Parsing.cpp (#4217) · 663effa0
      nicolaser15 提交于
      * Update Parsing.cpp
      
      When uploading TLS cert files the end of file "-----END CERTIFICATE-----" (or any kind of file with the sequence "CRLF--") is taken as posible end boundary. Then it is compared to the start boundary string. As it is expected, comparison turns to be false, and the whole end boundary string is put to _currentUpload->buf through _uploadWriteByte(). Here you have the problem: if you read boundary.length() bytes from HTTP request and you have some of the actual end boundary bytes in it, when you put all those bytes into _currentUpload->buf you are making a mistake. You will miss the actual end boundary string because some of those bytes were put in _currentUpload->buf.
      
      * Update Parsing.cpp
      663effa0
  3. 30 9月, 2020 1 次提交
    • E
      WebServer: Fix OOB write (#4088) · 494061af
      Emil Sandstø 提交于
      Successful exploitation could lead to arbitrary code execution.
      
      The bug can be reproduced by running the following in a browser:
      ```
      const formData = new FormData();
      for (let i = 0;i < 33;++i) { formData.append("foo", i.toString()); }
      await fetch("http://esp.local", { method: 'POST', body: formData });
      ```
      494061af
  4. 10 7月, 2019 1 次提交
  5. 12 4月, 2019 1 次提交
    • V
      Alternative Improve _uploadReadByte (#2656) · 25c0b522
      Victor Aprea 提交于
      * add opportunity for more than one retry to _uploadReadByte
      
      * an alternative timeout-based method to making _uploadReadByte more resilient
      
      * move timing variables in the correct scope
      
      * implement and use client.getTimeout instead of hard-coded timeout in _uploadReadByte
      
      * add missing return
      
      * some refactoring to address respecting the timeout in a potentially deadlocked connection
      
      * fix spelling in comment
      
      * address review comments; move impl to cpp file for getTimeout, and remove local variable for currentMillis
      
      * remove redundant cast
      
      * need to check for timeout outside the inner while as well
      
      * update WebUpdate example to print something in unexpected callback condition
      
      * update log_e messages per review comments
      25c0b522
  6. 22 1月, 2019 1 次提交
    • N
      Webserver library - fix logging (#2355) (#2359) · 29d59876
      Neal MIller 提交于
      * Webserver fix logging (#1)
      
      * Change logging to use esp32-hal-log.h
      
      fixes #2355
      
      * adjust log parameter output positions, reduce lines
      
      The DEBUG_ESP method used less lines than I originally set `log_v` to use when displaying the details of the received params ("@" and "=" indexes, and File info on a single line)
      29d59876
  7. 26 7月, 2018 1 次提交
  8. 25 7月, 2018 1 次提交
  9. 17 7月, 2018 1 次提交
  10. 06 7月, 2018 1 次提交
  11. 27 6月, 2018 1 次提交
    • M
      Update IDF to aaf1239 (#1539) · a59eafbc
      Me No Dev 提交于
      * fix sdmmc config
      
      * Fix warnings in EEPROM
      
      from @Curclamas
      
      * remove leftover TAG in EEPROM
      
      * Initial add of @stickbreaker i2c
      
      * Add log_n
      
      * fix warnings when log is off
      
      * i2c code clean up and reorganization
      
      * add flags to interrupt allocator
      
      * fix sdmmc config
      
      * Fix warnings in EEPROM
      
      from @Curclamas
      
      * remove leftover TAG in EEPROM
      
      * fix errors with latest IDF
      
      * fix debug optimization (#1365)
      
      incorrect optimization for debugging tick markers.
      
      * Fix some missing BT header
      
      * Change BTSerial log calls
      
      * Update BLE lib
      
      * Arduino-ESP32 release management scripted (#1515)
      
      * Calculate an absolute path for a custom partitions table (#1452)
      
      * * Arduino-ESP32 release management scripted
      (ready-to-merge)
      
      * * secure env for espressif/arduino-esp32
      
      * * build tests enabled
      * gitter webhook enabled
      
      * * gitter room link fixed
      * better comment
      
      * * filepaths fixed
      
      * BT Serial adjustments
      
      * * don't run sketch builds & tests for tagged builds
      
      * Return false from WiFi.hostByName() if hostname is not resolved
      
      * Free BT Memory when BT is not used
      
      * WIFI_MODE_NULL is not supported anymore
      
      * Select some key examples to build with PlatformIO to save some time
      
      * Update BLE lib
      
      * Fixed BLE lib
      
      * Major WiFi overhaul
      
      - auto reconnect on connection loss now works
      - moved to event groups
      - some code clean up and procedure optimizations
      - new methods to get a more elaborate system ststus
      
      * Add cmake tests to travis
      
      * Add initial AsyncUDP
      
      * Add NetBIOS lib and fix CMake includes
      
      * Add Initial WebServer
      
      * Fix WebServer and examples
      
      * travis not quiting on build fail
      
      * Try different travis build
      
      * Update IDF to aaf1239
      
      * Fix WPS Example
      
      * fix script permission and add some fail tests to sketch builder
      
      * Add missing space in WiFiClient::write(Stream &stream)
      a59eafbc