Issue: https://github.com/php/php-src/issues/11440
Author: weigon
### Description
The following code:
```
mysql --user=root -e "CREATE USER sha256_19 IDENTIFIED WITH sha256_password BY
'0123456789012345678'"
php -r 'mysqli_real_connect(mysqli_init(), "127.0.0.1", "sha256_19",
"0123456789012345678", "", 6000, "", MYSQLI_CLIENT_SSL);' //
throws
```
Resulted in this output:
```
PHP Fatal error: Uncaught mysqli_sql_exception: Access denied for user
'sha256_19'@'localhost' (using password: YES) in Command line code:1
Stack trace:
#0 Command line code(1): mysqli_real_connect()
#1 {main}
thrown in Command line code on line 1
```
But I expected this output instead:
```
```
Without forcing SSL it works:
```
php -r 'mysqli_real_connect(mysqli_init(), "127.0.0.1", "sha256_19",
"0123456789012345678", "", 6000, "");'
```
### PHP Version
PHP 8.1.2
### Operating System
Ubuntu 22.04