comparison src/event/ngx_event_openssl.c @ 7395:9ca82f273967

Core: ngx_explicit_memzero().
author Maxim Dounin <mdounin@mdounin.ru>
date Thu, 15 Nov 2018 21:28:02 +0300
parents ed8738b1c7c4
children 294162223c7c
comparison
equal deleted inserted replaced
7394:650574a44505 7395:9ca82f273967
1049 if (ngx_close_file(fd) == NGX_FILE_ERROR) { 1049 if (ngx_close_file(fd) == NGX_FILE_ERROR) {
1050 ngx_conf_log_error(NGX_LOG_ALERT, cf, ngx_errno, 1050 ngx_conf_log_error(NGX_LOG_ALERT, cf, ngx_errno,
1051 ngx_close_file_n " \"%s\" failed", file->data); 1051 ngx_close_file_n " \"%s\" failed", file->data);
1052 } 1052 }
1053 1053
1054 ngx_memzero(buf, NGX_SSL_PASSWORD_BUFFER_SIZE); 1054 ngx_explicit_memzero(buf, NGX_SSL_PASSWORD_BUFFER_SIZE);
1055 1055
1056 return passwords; 1056 return passwords;
1057 } 1057 }
1058 1058
1059 1059
1066 ngx_uint_t i; 1066 ngx_uint_t i;
1067 1067
1068 pwd = passwords->elts; 1068 pwd = passwords->elts;
1069 1069
1070 for (i = 0; i < passwords->nelts; i++) { 1070 for (i = 0; i < passwords->nelts; i++) {
1071 ngx_memzero(pwd[i].data, pwd[i].len); 1071 ngx_explicit_memzero(pwd[i].data, pwd[i].len);
1072 } 1072 }
1073 } 1073 }
1074 1074
1075 1075
1076 ngx_int_t 1076 ngx_int_t