A HTTP/HTTPS Client for the mbed networking/CyaSSL ssl library
Dependents: Anpi dropbox_access php_access_auth TwitterReader ... more
Fork of HTTPClient by
HTTP and HTTPS Client Class with wolfSSL, embedded SSL library.
The class was forked from http://mbed.org/users/donatien/code/HTTPClient/
It, now, accepts url both with "http://" and "https://".
Allocate caller thread with 16kbytes or larger stack for "https" requests.
Rest of the API stays compatible with HTTPClient.
For more about the library, see http://www.wolfssl.com. http://wolfssl.com/yaSSL/Docs.html.
Extended methods:
- HTTPResult basicAuth(const char* user, const char* password); /* set id/passwd for basic Authentication */
- void setHeader(char *header) ; /* set http headers */
- HTTPResult setSSLversion(int minorV) ; /* set SSL/TLS version. 0: SSL3, 1: TLS1.0, 2: TLS1.1, 3: TLS1.2 */
Diff: HTTPClient.h
- Revision:
- 31:7fd621b83b60
- Parent:
- 27:5d4739eae63e
- Child:
- 33:77082c88748a
--- a/HTTPClient.h Fri Dec 05 07:03:47 2014 +0000 +++ b/HTTPClient.h Fri Jun 26 00:39:47 2015 +0000 @@ -140,7 +140,7 @@ HTTPResult send(char* buf, size_t len = 0); //0 on success, err code on failure HTTPResult flush(void); //0 on success, err code on failure HTTPResult parseURL(const char* url, char* scheme, size_t maxSchemeLen, char* host, size_t maxHostLen, uint16_t* port, char* path, size_t maxPathLen); //Parse URL - void cyassl_free(void) ; + void wolfssl_free(void) ; HTTPResult bAuth(void) ; HTTPResult readHeader(void) ; @@ -160,8 +160,8 @@ /* for CyaSSL */ int SSLver ; uint16_t port; - struct CYASSL_CTX* ctx ; - struct CYASSL * ssl ; + struct WOLFSSL_CTX* ctx ; + struct WOLFSSL * ssl ; }; //Including data containers here for more convenience