Debian Codegraph @

plugin/auth_mysql_sha2/mysql-test/mysql_sha2/ssl_manual.result

raw
1 call mtr.add_suppression('failed to read private_key.pem: 2 "No such file or directory"');
2 show status like 'caching_sha2_password%';
3 Variable_name Value
4 Caching_sha2_password_rsa_public_key
5 create user test1@'%' identified via caching_sha2_password using PASSWORD('pwd');
6 create user test2@'%' identified via caching_sha2_password;
7 show grants for test2@'%';
8 Grants for test2@%
9 GRANT USAGE ON *.* TO `test2`@`%` IDENTIFIED VIA caching_sha2_password
10 create procedure checkme() sql security invoker
11 select user(), current_user(), variable_value > '' as 'have_ssl'
12 from information_schema.session_status
13 where variable_name='ssl_cipher';
14 grant execute on test.* to test1@'%', test2@'%';
15 connect con1, localhost,test1,pwd,,,,TCP SSL;
16 call checkme();
17 user() current_user() have_ssl
18 test1@localhost test1@% 1
19 disconnect con1;
20 connect con2, localhost,test1,pwd,,,,TCP SSL;
21 call checkme();
22 user() current_user() have_ssl
23 test1@localhost test1@% 1
24 disconnect con2;
25 connect(localhost,test1,wrong_pwd,test,MASTER_MYPORT,MASTER_MYSOCK);
26 connect con3, localhost,test1,wrong_pwd,,,,TCP SSL;
27 ERROR 28000: Access denied for user 'test1'@'localhost' (using password: YES)
28 connect con4, localhost,test2,,,,,TCP SSL;
29 call checkme();
30 user() current_user() have_ssl
31 test2@localhost test2@% 1
32 disconnect con4;
33 connect(localhost,test2 pwd,,test,MASTER_MYPORT,MASTER_MYSOCK);
34 connect con5, localhost,test2 pwd,,,,,TCP SSL;
35 ERROR 28000: Access denied for user 'test2 pwd'@'localhost' (using password: NO)
36 connection default;
37 drop procedure checkme;
38 drop user test1@'%';
39 drop user test2@'%';