1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-10 14:42:08 +03:00
Commit Graph

350 Commits

Author SHA1 Message Date
4ab89d07fc ESP8266WiFiMulti: Add count function (#3073)
Return total number of AP added

Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2017-12-30 13:16:47 -03:00
28803540a2 Added String hostname support to WiFiClient and WiFiClientSecure (#3349)
* Added String hostname support to WiFiClient and WiFiClientSecure

* Typo in WiFi
2017-12-29 01:58:36 -03:00
7dd50360b9 Fix bug in WiFiClientBasic.ino (#3902) 2017-12-28 09:47:10 -03:00
3838e58f62 WiFiClientSecure: don't use the broken max_fragment_length extension (#4033)
axTLS does not correctly implement max_fragment_length extension. This
causes servers which understand this extension (currently GnuTLS- and
WolfSSL-based) to reject the client hello.

Until this is fixed in axTLS, remove the call to enable this extension
from WiFiClientSecure.

Fixes https://github.com/esp8266/Arduino/issues/3932.
2017-12-28 01:45:49 -03:00
7fc23c6f7a WiFiUDP: fix crash when calling destinationIP with no packet available (#4036)
Fixes https://github.com/esp8266/Arduino/issues/3989.
2017-12-27 23:15:11 -03:00
fac64900dd Configurable WiFiClientSecure connect timeout, better default value (#4027)
* WiFiClientSecure: use _timeout setting when connecting

This timeout value can be customized via a call to setTimeout function.

Closes https://github.com/esp8266/Arduino/issues/3944.

* WiFiClientSecure: increase default connection timeout to 15 sec
2017-12-26 14:01:28 -03:00
ddda374985 WiFiClientSecure: don't trash unread decrypted data when writing (#4024)
* WiFiClientSecure: don't decrypt when testing for 'connected'

* WiFiClientSecure: don't trash unread decrypted data when writing

When application requests to write data, check if there is any unread
decrypted data left. If there is, don't write immediately, but save the
data to be written. When all decrypted data has been consumed by the
application, send out the saved outgoing data.

Fixes https://github.com/esp8266/Arduino/issues/2256.
2017-12-26 11:28:18 -03:00
d5bb4a99f6 in example properly wait for NTP to be set (#4000)
fix #3905
2017-12-21 16:27:58 -03:00
022ea5a872 consequence of ::flush() update: fix potential double free (#3990) 2017-12-18 08:56:18 -03:00
f8b577b6c3 fix WiFiClient::availableForWrite() with no connexion (#3985)
fix #3983
2017-12-18 00:47:56 -03:00
26980b39e3 fix #1002 ::Flush() wait for empty send buffer (#3967)
* fix #1002 ::Flush() wait for empty send buffer

* WiFiClient::Flush() guarantees that the data has been delivered
option 1 of https://github.com/esp8266/Arduino/pull/3967#discussion_r156901071
10ms max wait according to loaded tcp echo/reply scheme
2017-12-17 13:16:41 -03:00
7df2858285 Fix comment misnomer (#3939) 2017-12-08 15:58:46 -03:00
31abb6e5e1 [doc] update HTTPSRequest.ino (#3925)
add limitations of https connections
2017-12-08 03:38:19 -03:00
7b09ae5f69 Bug #3795 (#3858)
* fixes #3795

* adds beacon_interval and authmode to softap_config_equal
2017-11-22 19:01:22 -03:00
c40d8a990e adds WiFi.getPersistent() (#3857) 2017-11-22 18:08:28 -03:00
9dcc580aef Add compatibility check for ::config() method with arduino arg order (#3860) 2017-11-22 10:22:11 -03:00
2f09ea7117 refactor of WiFiMulti::run to reduce complexity and remove dead code (#3847) 2017-11-20 21:46:12 -03:00
78b0f44348 fixes #3795 (#3796)
don't ignore ret when handling AP enable/disable in softAPdisconnect
2017-11-17 20:28:34 -03:00
397592fce7 fixes #3793 (#3794)
wifi_softap_set_config always fails, password cannot be 0 unless authmode is open, no documentation found, trial and error.
2017-11-17 15:20:40 -03:00
2abbc36da4 Put WiFi into station mode in examples (#3731) 2017-10-22 13:53:01 +08:00
c83e17b31e WiFiUpd: fix warning 2017-10-15 14:41:50 +08:00
5116a46f09 WiFiClient,WiFiServer: update to match new err_t definition 2017-10-15 01:40:10 -05:00
e04903225e sdk: update to v2.1.0-10-g509eae8 2017-10-15 01:40:10 -05:00
2c2d6a3bad Don't remove persistent WiFi settings when doing scan (#2946) 2017-10-13 02:27:10 +08:00
526f4fbb6c WiFiClientSecure: add option to allow self-signed certificates
Mainly useful for testing WiFiClientSecure in local environments.

If allowSelfSignedCerts is called before verifyCertChain, then the
certificate chain will be verified, but the final certificate may be
self-signed.
2017-10-08 07:08:51 +08:00
84b046f98c WiFiClientSecure: add support for keys and certificates in PROGMEM 2017-10-08 05:04:04 +08:00
507a15910e WiFiClientSecure: display certificates when debugging is enabled 2017-10-02 00:27:22 +08:00
eb891cd6e4 Revert "Added support for user-supplied DHCP range, with basic sanity checks (#3562)"
This reverts commit bdf2296a7d.
2017-09-26 04:31:45 +08:00
13c1e8b293 UdpContext: check that pbuf_alloc doesn't return nullptr (#3354) 2017-09-22 03:56:27 -05:00
NdK
bdf2296a7d Added support for user-supplied DHCP range, with basic sanity checks (#3562) 2017-09-21 03:52:30 -05:00
41a8fdb4a9 Add the ESP8266WiFiMulti to KEYWORD1 to make it highlight in the ino file (#3624) 2017-09-20 22:17:09 -05:00
2d3b7b9759 WiFiClientSecure: add loadCACert function (#3610)
Added loadCACert function
2017-09-19 22:49:38 -05:00
8f04be4c5b Remove unused ax_port_*alloc() functions (#3482)
The ax_port_malloc, ax_port_calloc, ax_port_realloc, and ax_port_free
functions in WiFiClientSecure are not actually used by the AXTLS library.
It's directly using the library routines, and these function are never
used.  Remove these dead bits of code to make the axtls operation clearer.
2017-08-01 18:38:35 +03:00
8c3bb69530 WiFiClientSecure: don’t send close alert when opening new session
When WiFiClientSecure::connect was called, it would first tear down and
existing and set up new TCP session, then tear down existing TLS session
(using ssl_free), and then set up a new one. This caused TLS close-
notify alert to be sent to the new TCP session, preventing new session
from being established. This change postpones setting IO ctx to the new
TCP connection, fixing this issue.

Ref https://github.com/esp8266/Arduino/issues/3330
2017-06-05 17:30:57 +08:00
d6f1f0d5d7 WiFiClient: apply write timeout to single chunk (#3273)
WiFiClient write timeouts introduced in #3257 applied to the whole write
operation, which could take long time if data size was large. This
change makes the timeout happen per chunk. Timeout now happens if no
data has been delivered within a given interval.
2017-05-22 20:08:16 +08:00
f6d232f1ac WiFiClientSecure: match CN and SANs ignoring case
Some websites have certificates with uppercase letters in CN. This change
makes _verifyDN function accept such certificates by converting all names
to lower case before comparing them.

Resolves #2978
2017-05-21 22:00:33 -05:00
a8e8ecb687 WiFiClientSecure: add example of setCACert/verifyCertChain
Ref #1851
2017-05-21 22:00:33 -05:00
79cfad5d46 WiFiClientSecure: initialize ssl_ctx when loading certificate
Fixes #2470
2017-05-21 22:00:33 -05:00
4812cae8e2 WiFiClient: initialize _timeout properly 2017-05-20 12:20:03 +08:00
684b5f1629 WiFiClient: set default timeout to 5000ms for compatibility 2017-05-19 09:35:01 -05:00
71512653ca WiFiClient: use Stream::_timeout for write operations 2017-05-19 09:35:01 -05:00
eebcc656ed WiFiClient: add support for connect timeout 2017-05-19 09:35:01 -05:00
2aeac91c90 ESP8266WiFi: support timeout for WiFi.hostByName 2017-05-19 09:35:01 -05:00
7de81270a3 ClientContext: don’t read DataSource in TCP callback
Previously, _write_some function would be called each time TCP stack
notifies the application that some data was delivered (via the `sent`
callback). In turn, _write_some would obtain more data to be sent from
the DataSource. In case of a DataSource backed by a Stream, this would
read from a stream. Some libraries (such as SD) may call `yield` and
other blocking operations from Stream read function, which can not be
used in TCP stack callbacks.

This change moves the data sending loop back into the Arduino task, with
a negligible loss of performance. TCP callback now wakes the main task
via `esp_schedule`, which performs stream read and provides more data
to the TCP stack.

Possible future optimization would be to buffer Stream data ahead of
time. That way, buffered data could be sent immediately from the TCP
callback. On the other hand, this optimization would need extra TCP_MSS
of temporary storage, per connection.

Fixes #2399.
2017-05-09 06:17:32 -05:00
2d9e767630 Fixing a few compiler warnings to allow compilation with -Wall -Wextra and -Werror. (#3153) 2017-05-08 04:56:08 -05:00
c5c138ec5a axtls: update to bddda2a0
- update ssl_client_new signature
- add max fragment length negotiation support (hardcoded to 4096 bytes)
- build axtls with -f{function,data}-sections, ~1k less DRAM usage,
  ~3k less flash
- strip prefix from build paths in debug symbols
2017-04-29 22:58:19 +08:00
a41f55c469 prepare lwip2 (#3129)
* minimum changes for libraries to compile with lwip2

* add WiFiClient::availableForWrite() (similar to Serial::) which indicates how much data can be sent without buffering
2017-04-25 08:55:01 -05:00
93413efcf4 Remove queue.h contents originating from BSD (#2982)
fixes #2981
2017-02-19 05:36:30 +03:00
af58a74cc0 Allow usage of byte arrays to set RootCAs (#2968) 2017-02-15 14:22:23 +03:00
e9dea9af99 Update keywords.txt for coloring syntax (#2892)
Add ESP keywords and update ESP8266Wifi library
2017-02-06 13:25:27 +03:00