Bug #98223 Conditional jump or move depends on uninitialised value(s) in sha256_password_au
| Submitted: | 14 Jan 2020 15:03 | Modified: | 17 Jan 2020 15:16 |
|---|---|---|---|
| Reporter: | Marcelo Altmann (OCA) | Email Updates: | |
| Status: | Verified | Impact on me: | |
| Category: | MySQL Server: Pluggable Authentication | Severity: | S7 (Test Cases) |
| Version: | 5.7.29, 8.0.19 | OS: | Any |
| Assigned to: | CPU Architecture: | Any | |
| Tags: | Contribution | ||
[14 Jan 2020 15:03]
Marcelo Altmann
[17 Jan 2020 9:13]
MySQL Verification Team
Hello Marcelo, Thank you for the report and feedback. Verified as described. regards, Umesh
[17 Jan 2020 11:57]
MySQL Verification Team
Typo in the earlier provided results file, will upload later on after correcting.
[17 Jan 2020 12:49]
MySQL Verification Team
Test results - 8.0.19
Attachment: 98223_8.0.19.results (application/octet-stream, text), 358.79 KiB.
[17 Jan 2020 15:16]
Marcelo Altmann
Proposed solution: Initialize plain_text with empty string. (*) I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it. diff --git a/sql/auth/sql_authentication.cc b/sql/auth/sql_authentication.cc index 05f1cb14358..1883a3c3f9e 100644 --- a/sql/auth/sql_authentication.cc +++ b/sql/auth/sql_authentication.cc @@ -4192,7 +4192,7 @@ static int sha256_password_authenticate(MYSQL_PLUGIN_VIO *vio, int pkt_len; String scramble_response_packet; int cipher_length = 0; - unsigned char plain_text[MAX_CIPHER_LENGTH + 1]; + unsigned char plain_text[MAX_CIPHER_LENGTH + 1] = ""; RSA *private_key = NULL; RSA *public_key = NULL;
[20 Jan 2020 11:56]
MySQL Verification Team
Thank you for the contribution. regards, Umesh
Portions of this website are copyright © 2001, 2002 The PHP Group
Page generated in 0.040 sec. using MySQL 8.4.7-u6-cloud
Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the
respective copyright holders.
It is not reviewed in advance
by Oracle and does not necessarily represent the opinion of
Oracle or any other party.