Wykres commitów

66 Commity (5f07ed87f6c3c8c4de97ef4f9afca83398c2f3cf)

Autor SHA1 Wiadomość Data
Laukik Hase 3565a9ba89
fix(esp-tls): Add explicit inclusion of header `mbedtls/x509_crt.h`
- Closes https://github.com/espressif/esp-idf/issues/11761
2023-07-03 14:24:38 +05:30
yuanjianmin f74447103f esp-tls: Add config and api to set and get ciphersuites list 2023-04-27 19:22:27 +08:00
Aditya Patwardhan 2dd280f126
esp-tls: Added getter/setter function for the conn_state.
* Added the setter function to set the connection sockfd value
Closes https://github.com/espressif/esp-idf/issues/10871
2023-04-13 20:03:50 +05:30
Mahavir Jain 8d90249829 Merge branch 'contrib/github_pr_10967' into 'master'
[esp-tls] Add addr_family option to esp_tls_cfg_t (GitHub PR)

Closes IDFGH-9620

See merge request espressif/esp-idf!22892
2023-03-24 18:02:31 +08:00
Mark H. Spatz 0abd1cb51f [esp-tls] Add addr_family option to esp_tls_cfg_t 2023-03-12 17:41:30 -04:00
Aditya Patwardhan 0d20f8816f esp-tls: Fix build issue when esp-tls server session tickets have been enabled.
Closes https://github.com/espressif/esp-idf/issues/10765
2023-02-24 04:45:23 +00:00
Aditya Patwardhan 8ad4de7991 esp-tls: Add changes to the Cert selection callback PR. 2022-11-03 07:17:05 +00:00
Akos Vandra e9e3dc7904 esp-tls: Add support for the CERTIFICATE SELECTION HOOK. The hook has access to required information so that the application can make a more informed decision on which certificate to serve (such as alpn value, server certificate type, etc.)
Closes https://github.com/espressif/esp-idf/pull/9833

Signed-off-by: Aditya Patwardhan <aditya.patwardhan@espressif.com>
2022-11-03 07:17:05 +00:00
Aditya Patwardhan 8785d1687c esp_tls.h: Add note regarding default timeout_ms value 2022-06-21 16:33:52 +05:30
Li Jingyi 6d58008119 esp-tls: add api to free client session
Free session with mbedtls api to avoid mem-leak
2022-05-23 16:28:40 +08:00
Aditya Patwardhan aa9de02259 esp_tls.h: Clean up included header files. 2022-05-11 07:09:34 +00:00
Aditya Patwardhan 788c9ddf8d esp_tls: Added getter function for esp_tls ssl ctx. 2022-05-11 07:09:34 +00:00
Aditya Patwardhan 434e74ff73 esp_tls: Make esp_tls_t as private structure. 2022-05-11 07:09:34 +00:00
Laukik Hase 864c59c091
esp_tls: Remove deprecated API
- Removed deprecated esp_tls_conn_new() viz. duplicated by
  esp_tls_conn_new_sync()
- Removed deprecated esp_tls_conn_delete()
- Marked esp_tls_conn_http_new() as deprecated, added alternative
  esp_tls_conn_http_new_sync() (similar to esp_tls_conn_http_new_async())
2022-04-20 12:18:25 +05:30
Aditya Patwardhan 4c58685c00 esp_https_server: Enable secure element support.
Closes https://github.com/espressif/esp-idf/issues/8286
2022-03-27 14:35:25 +05:30
Aditya Patwardhan f31d8dd295 mbedtls: Remove certs.c and certs.h from port directory 2022-03-15 17:16:07 +05:30
Mahavir Jain c26500cd5a esp-tls: mark esp_tls_conn_delete API as deprecated
It is recommended to use `esp_tls_conn_destroy` API instead
2022-01-04 15:40:07 +05:30
Mahavir Jain 8b4c0e71a9 Merge branch 'feature/mbedtls_session_ticket_support' into 'master'
Feature/mbedtls session ticket support

Closes IDFGH-5288 and IDF-3242

See merge request espressif/esp-idf!14496
2021-09-17 09:59:02 +00:00
Aditya Patwardhan b4e4b9f20d Added support for client session tickets in esp-tls (with mbedtls)
* client session tickets for individual tls connections are supported
* reorganize the esp-tls error codes.
* Update esp_err_to_name.c
* Fix styling
2021-09-15 22:19:04 +05:30
Daniel Bahrdt 7e886ca9ed Implement server session ticket support with mbedtls
Closes https://github.com/espressif/esp-idf/pull/7048

Signed-off-by: Aditya Patwardhan <aditya.patwardhan@espressif.com>
2021-09-15 22:19:04 +05:30
Aditya Patwardhan c6c2ea975f Fix esp_mbedtls_write API
Fix esp_wolfssl_write API
Closes https://github.com/espressif/esp-idf/issues/7461
2021-09-15 21:40:54 +05:30
Jan Brudny 967e057906 esp-tls, esp_http_client and esp_http_server: update copyright notice 2021-05-31 20:06:09 +08:00
David Cermak f68d7d7023 esp_tls: Renamed public API to indicate the Plain TCP connection
Also added parameter checks if used from as a public API
and updated the `is_plein_tcp` description that it's possible to connect
directly using plain tcp transport with the new API.
2021-05-25 10:55:50 +02:00
David Cermak f249ddd9ae esp_transport: Use tcp_connect from esp_tls for plain TCP
so we don't have to allocate esp_tls structure (~2KB) to save heap when using plain TCP connection

Closes https://github.com/espressif/esp-idf/issues/6940
2021-05-25 07:04:02 +02:00
yuanjm c62cbd1254 transport: Support bind socket to specified interface in transport and esp-tls 2021-03-10 02:19:29 +00:00
David Cermak 6b318fe583 esp_tls: Updated connection method to use non-blocking connect
For better control over connection timeouts
To be in line with former tcp_transport, as esp-tls is not used for
plain tcp transports
2021-02-16 09:00:43 +01:00
David Cermak 2c28ffffee tcp_transport/esp_tls: Use common TCP transport to reduce code duplication
For high level review of the changes.
2021-02-16 09:00:43 +01:00
David Cermak 391d7bf271 tcp_transport: Add TCP transport connection errors
Transport's error_handle is used to capture different types of errors
including esp_err_t from esp-tls and socket/system errors.
This change adds the following error codes for TCP transport:
* connection closed by a FIN flag (clean closure from server)
* DNS resolution problem
* connection timeout
These errors are already defined in esp-tls component and since this
component will be used in the future for both TCP and SSL transport, we
currently report these issues in transport::error_handle::esp_tls_last_error
of standard esp error type (esp_err_t)

Closes https://github.com/espressif/esp-mqtt/issues/182
2021-02-16 09:00:43 +01:00
yuanjm 044c3e3e74 Modify esp-tls and tcp_transport to support keep alive for tcp and ssl connection
Closes IDFGH-4543
2021-01-22 06:56:28 +00:00
David Cermak ce519ee783 tcp_transport: Extend transport error storage for socket error
Everytime we report error and log errno, we also capture the actual
errno to an internal storage so that user application can retrieve
its value.
2020-11-12 12:46:22 +00:00
Aditya Patwardhan 47f7c6a991 esp32s2/esp_ds: Digital Signature software support
1)Added support for alt rsa sign implementation with DS peripheral (
through ESP-TLS - mbedTLS SSL/TLS stack)
2020-09-22 18:31:31 +05:30
Aditya Patwardhan 423e600d46 secure_element: atecc608_ecdsa example
* Replaced crypotoauthlib with esp-cryptoauthlib
* Added menuconfig option for esp-tls about using HSM
* Added error codes for HSM in esp-tls,
* Added support to select different type of ATECC608A chips
* Added README, updated docs
* tcp_transport: Added option to enable secure_element for ssl

Closes https://github.com/espressif/esp-idf/issues/4432
2020-05-21 13:08:30 +05:30
Mahavir Jain 7a2ea9b7f7 esp-tls: add support for using hardware security module 2020-05-20 22:52:37 +05:30
David Cermak 6182e6f303 tcp_transport: close to return error only for socket error or invalid args
Closes https://github.com/espressif/esp-idf/issues/4872
2020-05-05 15:53:09 +02:00
Vikram Dattu 60dc4285f4 Fixed `esp_tls_conn_write` documentation.
Return value `0` in actual is case of partial write and not error as per `mbedtls_ssl_write`
Modified documentation of `esp_tls_conn_write` accordingly.

Even `esp_wolfssl_write` API considers just negative returns as errors.

Signed-off-by: Vikram Dattu <vikram.dattu@espressif.com>
2020-04-01 11:04:09 +00:00
Aditya Patwardhan 874e987a3b esp_tls: change argument pointer type to (void *) for esp_crt_bundle_attach 2020-03-11 15:54:05 +05:30
Marius Vikhammer 947e3e94ed Add ESP certificate bundle feature
Adds the ESP certificate bundle feature that enables users to bundle a
root certificate bundle together with their application.

Default bundle includes all Mozilla root certificates

Closes IDF-296
2020-03-04 10:51:43 +08:00
Aditya Patwardhan 0a25922043 esp_tls_wolfssl: 1) Fix SNI for wolfSSL
2) Fix error captures
3) Add error flags specific wolfSSL
4) make respective changes to esp_err_to_name.c
2020-02-27 15:20:22 +05:30
Aditya Patwardhan d35862b662 esp-tls: Add support for https_server using wolfSSL 2020-02-27 15:20:22 +05:30
Angus Gratton 3f532c8895 Merge branch 'bugfix/esp_tls_blocking_timeout' into 'master'
esp-tls: add timeout for blocking connection

See merge request espressif/esp-idf!7316
2020-01-20 09:35:23 +08:00
David Cermak aa3b1da384 esp_tls: added connection timeout to esp_tls_conn_new_sync() 2020-01-16 07:32:19 +00:00
Aditya Patwardhan c7418042b4 esp32/esp-tls: provide API to retrieve sockfd value from esp_tls_t 2020-01-16 12:27:44 +05:30
Aditya Patwardhan 988f0c8feb ESP_TLS: Generalizing error messages for esp_tls
:Replace mbedtls specific error messages
2019-10-28 16:05:31 +05:30
Aditya Patwardhan f7eaa5f946 ESP_TLS: Restructuring esp_tls
1)Segregating mbedtls API into seperate file and cleaned esp_tls.c
2)Added support for wolfssl for CMake and make
3)Added support for debug_wolfssl (with menuconfig option)
4)Added info on wolfssl in ESP-TLS docs
2019-10-28 16:05:22 +05:30
Aditya Patwardhan 9f86f969b2 ESP32/esp-tls: include esp_err.h in esp_tls.h
Closes https://github.com/espressif/esp-idf/issues/4100
2019-10-07 19:47:32 +08:00
David Cermak f3d6a34e7d esp_tls: enable psk verification mode, added mqtt example using psk authentication 2019-08-07 14:27:40 +10:00
Angus Gratton 7ef5fa8a0a Merge branch 'feature/transport_support_der_certs' into 'master'
tcp transport ssl DER-support

See merge request espressif/esp-idf!5627
2019-08-05 09:52:08 +08:00
David Cermak 25dd5e39af esp-tls: Naming variables refering to certificates and keys in a neutral way to suggest that both PEM and DER format could be used, added comments descibing important details about using these formats 2019-08-02 09:25:16 +02:00
Henning Fleddermann 73624e8560 modify comments on esp_tls_cfg, to clarify that other formats besides PEM (such as DER) might be used as well depending on mbedtls-support
Signed-off-by: David Cermak <cermak@espressif.com>
2019-08-02 09:25:16 +02:00
Anton Maklakov afbaf74007 tools: Mass fixing of empty prototypes (for -Wstrict-prototypes) 2019-08-01 16:28:56 +07:00