OpenSSL-APIs
-============
+------------
All original source code in this repository is Copyright (C) 2015-2016
Espressif Systems. This source code is licensed under the Apache
License 2.0 as described in the file LICENSE.
+OpenSSL APIs not mentioned in this article are not open to public for the time,
+also do not have the corresponding function.
+If user calls it directly, it will always return an error or may show cannot link
+at compile time.
+
Chapter Introduction
====================
Chapter 1. SSL Context Method Create
====================================
-
-1.1 const SSL_METHOD* ``SSLv23_client_method`` (void)
+1.1 const SSL_METHOD* ``SSLv3_client_method`` (void)
Arguments::
Return::
- SSLV2 and 3 version SSL context client method point
+ SSLV3.0 version SSL context client method point
Description::
void example(void)
{
- const SSL_METHOD *method = SSLv23_client_method();
+ const SSL_METHOD *method = SSLv3_client_method();
...
}
-
1.2 const SSL_METHOD* ``TLSv1_client_method`` (void)
Arguments::
...
}
-
-1.3 const SSL_METHOD* ``SSLv3_client_method`` (void)
+1.3 const SSL_METHOD* ``TLSv1_1_client_method`` (void)
Arguments::
Return::
- SSLV3.0 version SSL context client method point
+ TLSV1.1 version SSL context client method point
Description::
void example(void)
{
- const SSL_METHOD *method = SSLv3_client_method();
+ const SSL_METHOD *method = TLSv1_1_client_method();
...
}
-
-1.4 const SSL_METHOD* ``TLSv1_1_client_method`` (void)
+1.4 const SSL_METHOD* ``TLSv1_2_client_method`` (void)
Arguments::
- none
+ none
Return::
- TLSV1.1 version SSL context client method point
+ TLSV1.2 version SSL context client method point
Description::
- create the target SSL context method
+ create the target SSL context method
Example::
void example(void)
{
- const SSL_METHOD *method = TLSv1_1_client_method();
+ const SSL_METHOD *method = TLSv1_2_client_method();
...
}
-
-
-1.5 const SSL_METHOD* ``TLSv1_2_client_method`` (void)
+
+1.5 const SSL_METHOD* ``TLS_client_method`` (void)
Arguments::
Description::
- create the target SSL context method
+ create the default SSL context method, it's always to be TLSV1.2
Example::
const SSL_METHOD *method = TLSv1_2_client_method();
...
- }
-
+ }
-1.6 const SSL_METHOD* ``SSLv23_server_method`` (void)
+1.6 const SSL_METHOD* ``SSLv3_server_method`` (void)
Arguments::
Return::
- SSLV2 and 3 version SSL context server method point
+ SSLV3.0 version SSL context server method point
Description::
void example(void)
{
- const SSL_METHOD *method = SSLv23_server_method();
+ const SSL_METHOD *method = SSLv3_server_method();
...
}
-
-1.7 const SSL_METHOD* ``TLSv1_1_server_method`` (void)
+1.7 const SSL_METHOD* ``TLSv1_server_method`` (void)
Arguments::
Return::
- TLSV1.1 version SSL context server method point
+ TLSV1.0 version SSL context server method point
Description::
create the target SSL context method
- Example :
+ Example::
void example(void)
{
- const SSL_METHOD *method = TLSv1_1_server_method();
+ const SSL_METHOD *method = TLSv1_server_method();
...
}
-
-1.8 const SSL_METHOD* ``TLSv1_2_server_method`` (void)
+1.8 const SSL_METHOD* ``TLSv1_1_server_method`` (void)
Arguments::
Return::
- TLSV1.2 version SSL context server method point
+ TLSV1.1 version SSL context server method point
Description::
create the target SSL context method
- Example::
+ Example :
void example(void)
{
- const SSL_METHOD *method = TLSv1_2_server_method();
+ const SSL_METHOD *method = TLSv1_1_server_method();
...
}
-1.9 const SSL_METHOD* ``TLSv1_server_method`` (void)
+1.9 const SSL_METHOD* ``TLSv1_2_server_method`` (void)
Arguments::
Return::
- TLSV1.0 version SSL context server method point
+ TLSV1.2 version SSL context server method point
Description::
void example(void)
{
- const SSL_METHOD *method = TLSv1_server_method();
+ const SSL_METHOD *method = TLSv1_2_server_method();
...
}
-
-1.10 const SSL_METHOD* ``SSLv3_server_method`` (void)
+1.10 const SSL_METHOD* ``TLS_server_method`` (void)
Arguments::
Return::
- SSLV3.0 version SSL context server method point
+ TLSV1.2 version SSL context server method point
Description::
- create the target SSL context method
+ create the default SSL context method, it's always to be TLSV1.2
Example::
void example(void)
{
- const SSL_METHOD *method = SSLv3_server_method();
+ const SSL_METHOD *method = TLSv1_2_server_method();
...
}
-
Chapter 2. SSL Context Fucntion
===============================
err = SSL_get_error(ssl, ret);
}
-
-3.35 void ``SSL_CTX_set_default_read_buffer_len`` (SSL_CTX *ctx, size_t len)
-
- Arguments::
-
- ctx - SSL context point
- len - read buffer length
-
- Return::
-
- none
-
- Description::
-
- set the SSL context read buffer length
-
- Example::
-
- void example(void)
- {
- SSL_CTX *ctx;
- size_t len;
-
- ... ...
-
- SSL_CTX_set_default_read_buffer_len(ctx, len);
- }
-
-
-3.36 void ``SSL_set_default_read_buffer_len`` (SSL *ssl, size_t len)
-
- Arguments::
-
- ssl - SSL point
- len - read buffer length
-
- Return::
-
- none
-
- Description::
-
- set the SSL read buffer length
-
- Example::
-
- void example(void)
- {
- SSL *ssl;
- size_t len;
-
- ... ...
-
- SSL_set_default_read_buffer_len(ctx, len);
- }
-
-3.37 int ``SSL_want`` (const SSL *ssl)
+3.35 int ``SSL_want`` (const SSL *ssl)
Arguments::
}
-3.38 int ``SSL_want_nothing`` (const SSL *ssl)
+3.36 int ``SSL_want_nothing`` (const SSL *ssl)
Arguments::
}
-3.39 int ``SSL_want_read`` (const SSL *ssl)
+3.37 int ``SSL_want_read`` (const SSL *ssl)
Arguments::
}
-3.40 int ``SSL_want_write`` (const SSL *ssl)
+3.38 int ``SSL_want_write`` (const SSL *ssl)
Arguments::