diff --git a/ssl/custom_extensions.c b/ssl/custom_extensions.c index 780cdc68..46b5efb4 100644 --- a/ssl/custom_extensions.c +++ b/ssl/custom_extensions.c @@ -90,7 +90,7 @@ static int custom_ext_add_hello(SSL *ssl, CBB *extensions) { !CBB_add_bytes(&contents_cbb, contents, contents_len) || !CBB_flush(extensions)) { OPENSSL_PUT_ERROR(SSL, ERR_R_INTERNAL_ERROR); - ERR_add_error_dataf("extension: %u", (unsigned) ext->value); + ERR_add_error_dataf("extension %u", (unsigned) ext->value); if (ext->free_callback && 0 < contents_len) { ext->free_callback(ssl, ext->value, contents, ext->add_arg); } @@ -113,7 +113,7 @@ static int custom_ext_add_hello(SSL *ssl, CBB *extensions) { default: ssl3_send_alert(ssl, SSL3_AL_FATAL, alert); OPENSSL_PUT_ERROR(SSL, SSL_R_CUSTOM_EXTENSION_ERROR); - ERR_add_error_dataf("extension: %u", (unsigned) ext->value); + ERR_add_error_dataf("extension %u", (unsigned) ext->value); return 0; } } @@ -136,7 +136,7 @@ int custom_ext_parse_serverhello(SSL *ssl, int *out_alert, uint16_t value, /* Also, if we didn't send the extension, that's also unacceptable. */ !(ssl->s3->hs->custom_extensions.sent & (1u << index))) { OPENSSL_PUT_ERROR(SSL, SSL_R_UNEXPECTED_EXTENSION); - ERR_add_error_dataf("extension: %u", (unsigned)value); + ERR_add_error_dataf("extension %u", (unsigned)value); *out_alert = SSL_AD_UNSUPPORTED_EXTENSION; return 0; } @@ -145,7 +145,7 @@ int custom_ext_parse_serverhello(SSL *ssl, int *out_alert, uint16_t value, !ext->parse_callback(ssl, value, CBS_data(extension), CBS_len(extension), out_alert, ext->parse_arg)) { OPENSSL_PUT_ERROR(SSL, SSL_R_CUSTOM_EXTENSION_ERROR); - ERR_add_error_dataf("extension: %u", (unsigned)ext->value); + ERR_add_error_dataf("extension %u", (unsigned)ext->value); return 0; } @@ -169,7 +169,7 @@ int custom_ext_parse_clienthello(SSL *ssl, int *out_alert, uint16_t value, !ext->parse_callback(ssl, value, CBS_data(extension), CBS_len(extension), out_alert, ext->parse_arg)) { OPENSSL_PUT_ERROR(SSL, SSL_R_CUSTOM_EXTENSION_ERROR); - ERR_add_error_dataf("extension: %u", (unsigned)ext->value); + ERR_add_error_dataf("extension %u", (unsigned)ext->value); return 0; } diff --git a/ssl/t1_lib.c b/ssl/t1_lib.c index bc39440f..3679f8d7 100644 --- a/ssl/t1_lib.c +++ b/ssl/t1_lib.c @@ -2651,7 +2651,7 @@ int ssl_add_clienthello_tlsext(SSL *ssl, CBB *out, size_t header_len) { const size_t len_before = CBB_len(&extensions); if (!kExtensions[i].add_clienthello(ssl, &extensions)) { OPENSSL_PUT_ERROR(SSL, SSL_R_ERROR_ADDING_EXTENSION); - ERR_add_error_dataf("extension: %u", (unsigned)kExtensions[i].value); + ERR_add_error_dataf("extension %u", (unsigned)kExtensions[i].value); goto err; } @@ -2744,7 +2744,7 @@ int ssl_add_serverhello_tlsext(SSL *ssl, CBB *out) { if (!kExtensions[i].add_serverhello(ssl, &extensions)) { OPENSSL_PUT_ERROR(SSL, SSL_R_ERROR_ADDING_EXTENSION); - ERR_add_error_dataf("extension: %u", (unsigned)kExtensions[i].value); + ERR_add_error_dataf("extension %u", (unsigned)kExtensions[i].value); goto err; } } @@ -2814,7 +2814,7 @@ static int ssl_scan_clienthello_tlsext( if (!ext->parse_clienthello(ssl, &alert, &extension)) { *out_alert = alert; OPENSSL_PUT_ERROR(SSL, SSL_R_ERROR_PARSING_EXTENSION); - ERR_add_error_dataf("extension: %u", (unsigned)type); + ERR_add_error_dataf("extension %u", (unsigned)type); return 0; } } @@ -2842,7 +2842,7 @@ static int ssl_scan_clienthello_tlsext( uint8_t alert = SSL_AD_DECODE_ERROR; if (!kExtensions[i].parse_clienthello(ssl, &alert, contents)) { OPENSSL_PUT_ERROR(SSL, SSL_R_MISSING_EXTENSION); - ERR_add_error_dataf("extension: %u", (unsigned)kExtensions[i].value); + ERR_add_error_dataf("extension %u", (unsigned)kExtensions[i].value); *out_alert = alert; return 0; } @@ -2921,7 +2921,7 @@ static int ssl_scan_serverhello_tlsext(SSL *ssl, CBS *cbs, int *out_alert) { uint8_t alert = SSL_AD_DECODE_ERROR; if (!ext->parse_serverhello(ssl, &alert, &extension)) { OPENSSL_PUT_ERROR(SSL, SSL_R_ERROR_PARSING_EXTENSION); - ERR_add_error_dataf("extension: %u", (unsigned)type); + ERR_add_error_dataf("extension %u", (unsigned)type); *out_alert = alert; return 0; } @@ -2934,7 +2934,7 @@ static int ssl_scan_serverhello_tlsext(SSL *ssl, CBS *cbs, int *out_alert) { uint8_t alert = SSL_AD_DECODE_ERROR; if (!kExtensions[i].parse_serverhello(ssl, &alert, NULL)) { OPENSSL_PUT_ERROR(SSL, SSL_R_MISSING_EXTENSION); - ERR_add_error_dataf("extension: %u", (unsigned)kExtensions[i].value); + ERR_add_error_dataf("extension %u", (unsigned)kExtensions[i].value); *out_alert = alert; return 0; }