Commit Graph

27 Commits

Author SHA1 Message Date
me-no-dev
3d6e4e1b94 Use milliseconds for timeout 2019-04-15 17:27:54 +02:00
me-no-dev
582e6433e9 Add proper timeout handling to WiFiClientSecure 2019-04-15 17:19:49 +02:00
copercini
229d9b7366 [WiFiClientSecure] Shows only free internal heap on logs (#2252)
* Shows only free internal heap on logs

Since Mbedtls is running only on internal heap, show internal + PSRAM available memory on logs can confuse the users

* Clarify logs
2018-12-31 11:44:57 +02:00
me-no-dev
278fa0d87a Fix read(), peek() and available() in WiFiClientSecure
closes: https://github.com/espressif/arduino-esp32/pull/2151
2018-12-15 18:14:38 +01:00
Thorsten von Eicken
af7e489f01 WiFiClientSecure: add support for PSK (pre-shared key) ciphers (#2133)
* WiFiClientSecure: add support for PSK (pre-shared key) ciphers

* add example for WiFiClientSecure PSK

* WiFiClientSecure: added README
2018-12-03 16:17:55 +01:00
Luc
ce340faf94 Clean warnings when all warning enabled (#2112)
* Clean warnings when all warning enabled

Not used variables / functions due to debug log

Dual define with different values :
cores\esp32/binary.h
#define B110 6
#define B1000000 64

tools/sdk/include/newlib/sys/termios.h
#define B110        3
#define B1000000   23

Local variable returned in WiFiclient Secure

* change due to deprecated function

* Update with proper variable and label

* Update esp32-hal-i2c.c

* Apply changes requested

* Fix warnings due to #define conflict thanks @atanisoft
2018-11-29 11:34:55 +01:00
A C SREEDHAR REDDY
46257c03b3 handshake in ssl_client.cpp (#2044)
* issue #2041

* handshake timeout

* seconds to milliseconds
2018-11-26 23:25:08 +01:00
Martin
5d2460c74a Working example for HTTPS over Eduroam network - WifiClient secure library (#2022)
* Working example for HTTPS over Eduroam network

* Update WiFiClientSecureEnterprise.ino
2018-11-19 17:02:24 +01:00
lbernstone
65c861ad4c Added loadCert methods to WiFiClientSecure (#1959) 2018-11-19 16:50:08 +01:00
me-no-dev
873876d94c Fix peek, read and available logic in WiFiClientSecure 2018-06-27 22:09:21 +02:00
Me No Dev
a59eafbc9d
Update IDF to aaf1239 (#1539)
* 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)
2018-06-27 09:01:06 +02:00
chemicstry
00f962439a Port SSL fingerprint checking from ESP8266 WiFiClientSecure to ESP32 (#1397) 2018-05-14 13:00:40 +02:00
Craig Leres
c92b617397 Convert the few remaining cr/lf files to use lf for eol. (#1316)
If you develop on windows and need cr/lf files, see this:

    https://git-scm.com/book/en/v2/Customizing-Git-Git-Configuration#_formatting_and_whitespace

    Git can handle this by auto-converting CRLF line endings into LF
    when you add a file to the index, and vice versa when it checks out
    code onto your filesystem. You can turn on this functionality with
    the core.autocrlf setting. If you're on a Windows machine, set it
    to true - this converts LF endings into CRLF when you check out code:

    $ git config --global core.autocrlf true
2018-04-16 16:34:39 +02:00
copercini
febcda0095 add WiFiClientSecure::peek(); (#1310) 2018-04-14 09:44:21 +02:00
lbernstone
d650ac6c3c WiFiClientSecure::lastError() method (#945)
* Added a lastError method to WiFiClientSecure so that a connection error from mbedTLS can be retrieved if connection fails (and then presented to a user).

* Changed to dos CRLF

* Made buffer size a const\nMore cleanup to match source
2018-01-18 01:03:56 +02:00
Jason K
cfbb7300b7 Update to make use of SSL a bit less confusing by ensuring errors are generated if the wrong method is called to retrieve the data stream. (#934) 2017-12-19 14:06:45 +01:00
copercini
14dd44ad06 Reduce net_would_block calls in handshake verification (#795)
This reduce net_would_block calls and CPU utilization
2017-11-06 15:28:37 +02:00
me-no-dev
4470e28ca1 WiFiClientSecure fail if gethostbyname returns null 2017-10-23 16:19:46 +03:00
me-no-dev
e72895b722 Quiet SSL and HTTPClient debug 2017-09-29 20:31:45 +08:00
copercini
ad179548e4 SNI support (#592)
Server Name Indication (SNI) support for WiFiClientSecure

Fix https://github.com/espressif/arduino-esp32/issues/571 and https://github.com/espressif/arduino-esp32/issues/550
2017-08-23 21:33:26 -03:00
copercini
cfde557916 Heap optimization (#471)
* Remove duplicated include

* Clear certificates just after handshake

It can save up to 7k of heap
2017-06-29 09:30:59 +02:00
copercini
51a4432ca8 HTTPClient Port (#347)
* Fix possible infinite loop in the example

* Remove workaround of sockets always return -76 

Remove workaround of sockets always return -76 (because it's fixed on IDF now)
Remove delay during handshake (improving stability)

* Remove unusable mbedtls_net of context creation

* Fix bad destructor

* Compatibility with WiFiClient for HTTPClient

* Initial port from ESP8266

Changed SHA1 fingerprint by Root CA verification
Changed log system

* Remove deprecated function
2017-05-19 10:18:20 +02:00
copercini
b46f1e2e3c Support self signed certificates (#291)
* Support self signed certificates

Fix for https://github.com/espressif/arduino-esp32/issues/265

mbedtls_ssl_conf_authmode was defined before mbedtls_ssl_config_defaults causing several bugs when no CA certificate is defined.

* Implement Arduino's log facility

Replace printf by ESP log handling

* Remove \n from debug messages

log_ doesn't need \n to break line.
2017-03-31 00:01:09 +02:00
copercini
e30447449f WiFiSecureClient fixes and improvements (#255)
* Add CA certificate in example

SHA1 fingerprint is broken now: more info: https://shattered.io

* Best error handling

When occur an error in WiFiClientSecure library just return the error message
and clean the context avoiding crash - fix for https://github.com/espressif/arduino-esp32/issues/211

Translate MbedTLS error codes in messages for best understanding

* Declarate certificates as const

mbedtls_pk_parse_key needs a const unsigned char * certificate. In old implementation the certificate was declarated as char * so first it converts to unsigned and after to const.

When we convert signed to unsigned it may result in a +1 larger output.

Fix issue https://github.com/espressif/arduino-esp32/issues/223
2017-03-10 15:52:50 +01:00
me-no-dev
bcd6dcf5f6 Fix compile error with IDF and mbedtls debug off 2017-02-28 23:18:06 +02:00
wami
95cb54cede [fix] return add --- error: no return statement in function returning non-void (#205) 2017-02-17 00:43:59 +02:00
copercini
8ab3231e31 Add WiFiClient secure lib (#184)
* Provide SSL/TLS functions to ESP32 with Arduino IDE

* Generate a new random number in case of reconnection
2017-02-11 00:20:24 +02:00