Commit 8a8b871d37476046e859f74ff22ece6b17464400
1 parent
f69b8b9a
Exists in
master
and in
5 other branches
Iniciando implementação de validação de certificados revogados.
Showing
2 changed files
with
18 additions
and
2 deletions
Show diff stats
locale/pw3270.pot
... | ... | @@ -9,7 +9,7 @@ msgstr "" |
9 | 9 | "#-#-#-#-# lib3270.pot (PACKAGE VERSION) #-#-#-#-#\n" |
10 | 10 | "Project-Id-Version: PACKAGE VERSION\n" |
11 | 11 | "Report-Msgid-Bugs-To: \n" |
12 | -"POT-Creation-Date: 2018-10-18 15:19-0300\n" | |
12 | +"POT-Creation-Date: 2018-10-19 09:56-0300\n" | |
13 | 13 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
14 | 14 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
15 | 15 | "Language-Team: LANGUAGE <LL@li.org>\n" |
... | ... | @@ -20,7 +20,7 @@ msgstr "" |
20 | 20 | "#-#-#-#-# pw3270.pot (PACKAGE VERSION) #-#-#-#-#\n" |
21 | 21 | "Project-Id-Version: PACKAGE VERSION\n" |
22 | 22 | "Report-Msgid-Bugs-To: \n" |
23 | -"POT-Creation-Date: 2018-10-18 15:19-0300\n" | |
23 | +"POT-Creation-Date: 2018-10-19 09:56-0300\n" | |
24 | 24 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
25 | 25 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
26 | 26 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
src/lib3270/ssl.c
... | ... | @@ -39,6 +39,7 @@ |
39 | 39 | #if defined(HAVE_LIBSSL) |
40 | 40 | #include <openssl/ssl.h> |
41 | 41 | #include <openssl/err.h> |
42 | + #include <openssl/x509_vfy.h> | |
42 | 43 | |
43 | 44 | #ifndef SSL_ST_OK |
44 | 45 | #define SSL_ST_OK 3 |
... | ... | @@ -54,6 +55,7 @@ |
54 | 55 | #include "trace_dsc.h" |
55 | 56 | |
56 | 57 | #if defined(HAVE_LIBSSL) |
58 | + | |
57 | 59 | static int ssl_3270_ex_index = -1; /**< Index of h3270 handle in SSL session */ |
58 | 60 | #endif // HAVE_LIBSSL |
59 | 61 | |
... | ... | @@ -253,6 +255,20 @@ int ssl_init(H3270 *hSession) |
253 | 255 | SSL_CTX_set_info_callback(ssl_ctx, ssl_info_callback); |
254 | 256 | SSL_CTX_set_default_verify_paths(ssl_ctx); |
255 | 257 | |
258 | + /* | |
259 | + // Set up CRL validation | |
260 | + // https://stackoverflow.com/questions/4389954/does-openssl-automatically-handle-crls-certificate-revocation-lists-now | |
261 | + X509_STORE *store = SSL_CTX_get_cert_store(ssl_ctx); | |
262 | + | |
263 | + // Enable CRL checking | |
264 | + X509_VERIFY_PARAM *param = X509_VERIFY_PARAM_new(); | |
265 | + X509_VERIFY_PARAM_set_flags(param, X509_V_FLAG_CRL_CHECK); | |
266 | + X509_STORE_set1_param(store, param); | |
267 | + X509_VERIFY_PARAM_free(param); | |
268 | + */ | |
269 | + | |
270 | + // X509_STORE_free(store); | |
271 | + | |
256 | 272 | #if defined(_WIN32) |
257 | 273 | { |
258 | 274 | HKEY hKey = 0; | ... | ... |