mySQL 5.0.11 sources for tomato
[tomato.git] / release / src / router / mysql / mysql-test / r / openssl_1.result
blobb95c4bb0e7638d1417f17be1e335b82846f09a68
1 drop table if exists t1;
2 create table t1(f1 int);
3 insert into t1 values (5);
4 grant select on test.* to ssl_user1@localhost require SSL;
5 grant select on test.* to ssl_user2@localhost require cipher "DHE-RSA-AES256-SHA";
6 grant select on test.* to ssl_user3@localhost require cipher "DHE-RSA-AES256-SHA" AND SUBJECT "/C=SE/ST=Uppsala/O=MySQL AB";
7 grant select on test.* to ssl_user4@localhost require cipher "DHE-RSA-AES256-SHA" AND SUBJECT "/C=SE/ST=Uppsala/O=MySQL AB" ISSUER "/C=SE/ST=Uppsala/L=Uppsala/O=MySQL AB";
8 grant select on test.* to ssl_user5@localhost require cipher "DHE-RSA-AES256-SHA" AND SUBJECT "xxx";
9 flush privileges;
10 connect(localhost,ssl_user5,,test,MASTER_PORT,MASTER_SOCKET);
11 ERROR 28000: Access denied for user 'ssl_user5'@'localhost' (using password: NO)
12 SHOW STATUS LIKE 'Ssl_cipher';
13 Variable_name   Value
14 Ssl_cipher      DHE-RSA-AES256-SHA
15 select * from t1;
18 delete from t1;
19 ERROR 42000: DELETE command denied to user 'ssl_user1'@'localhost' for table 't1'
20 SHOW STATUS LIKE 'Ssl_cipher';
21 Variable_name   Value
22 Ssl_cipher      DHE-RSA-AES256-SHA
23 select * from t1;
26 delete from t1;
27 ERROR 42000: DELETE command denied to user 'ssl_user2'@'localhost' for table 't1'
28 SHOW STATUS LIKE 'Ssl_cipher';
29 Variable_name   Value
30 Ssl_cipher      DHE-RSA-AES256-SHA
31 select * from t1;
34 delete from t1;
35 ERROR 42000: DELETE command denied to user 'ssl_user3'@'localhost' for table 't1'
36 SHOW STATUS LIKE 'Ssl_cipher';
37 Variable_name   Value
38 Ssl_cipher      DHE-RSA-AES256-SHA
39 select * from t1;
42 delete from t1;
43 ERROR 42000: DELETE command denied to user 'ssl_user4'@'localhost' for table 't1'
44 drop user ssl_user1@localhost, ssl_user2@localhost,
45 ssl_user3@localhost, ssl_user4@localhost, ssl_user5@localhost;
46 drop table t1;
47 mysqltest: Could not open connection 'default': 2026 SSL connection error: xxxx
48 mysqltest: Could not open connection 'default': 2026 SSL connection error: xxxx
49 mysqltest: Could not open connection 'default': 2026 SSL connection error: xxxx
50 SSL error: Unable to get private key from ''
51 mysqltest: Could not open connection 'default': 2026 SSL connection error
52 SSL error: Unable to get certificate from ''
53 mysqltest: Could not open connection 'default': 2026 SSL connection error
54 SHOW STATUS LIKE 'Ssl_cipher';
55 Variable_name   Value
56 Ssl_cipher      DHE-RSA-AES256-SHA
57 Variable_name   Value
58 Ssl_cipher      DHE-RSA-AES256-SHA
59 End of 5.0 tests
60 DROP TABLE IF EXISTS thread_status;
61 DROP EVENT IF EXISTS event_status;
62 SET GLOBAL event_scheduler=1;
63 CREATE EVENT event_status
64 ON SCHEDULE AT NOW()
65 ON COMPLETION NOT PRESERVE
67 BEGIN
68 CREATE TABLE thread_status
69 SELECT variable_name, variable_value
70 FROM information_schema.session_status
71 WHERE variable_name LIKE 'SSL_ACCEPTS' OR
72 variable_name LIKE 'SSL_CALLBACK_CACHE_HITS';
73 END$$
74 SELECT variable_name, variable_value FROM thread_status;
75 variable_name   variable_value
76 SSL_ACCEPTS     #
77 SSL_CALLBACK_CACHE_HITS #
78 DROP TABLE thread_status;
79 SET GLOBAL event_scheduler=0;
80 SHOW STATUS LIKE 'Ssl_cipher';
81 Variable_name   Value
82 Ssl_cipher      AES128-SHA
83 SHOW STATUS LIKE 'Ssl_cipher';
84 Variable_name   Value
85 Ssl_cipher      AES128-SHA
86 mysqltest: Could not open connection 'default': 2026 SSL connection error
87 CREATE TABLE t1(a int);
88 INSERT INTO t1 VALUES (1), (2);
90 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
91 /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
92 /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
93 /*!40101 SET NAMES utf8 */;
94 /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
95 /*!40103 SET TIME_ZONE='+00:00' */;
96 /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
97 /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
98 /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
99 /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
100 DROP TABLE IF EXISTS `t1`;
101 /*!40101 SET @saved_cs_client     = @@character_set_client */;
102 /*!40101 SET character_set_client = utf8 */;
103 CREATE TABLE `t1` (
104   `a` int(11) DEFAULT NULL
106 /*!40101 SET character_set_client = @saved_cs_client */;
108 LOCK TABLES `t1` WRITE;
109 /*!40000 ALTER TABLE `t1` DISABLE KEYS */;
110 INSERT INTO `t1` VALUES (1),(2);
111 /*!40000 ALTER TABLE `t1` ENABLE KEYS */;
112 UNLOCK TABLES;
113 /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
115 /*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
116 /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
117 /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
118 /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
119 /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
120 /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
121 /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
124 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
125 /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
126 /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
127 /*!40101 SET NAMES utf8 */;
128 /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
129 /*!40103 SET TIME_ZONE='+00:00' */;
130 /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
131 /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
132 /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
133 /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
134 DROP TABLE IF EXISTS `t1`;
135 /*!40101 SET @saved_cs_client     = @@character_set_client */;
136 /*!40101 SET character_set_client = utf8 */;
137 CREATE TABLE `t1` (
138   `a` int(11) DEFAULT NULL
140 /*!40101 SET character_set_client = @saved_cs_client */;
142 LOCK TABLES `t1` WRITE;
143 /*!40000 ALTER TABLE `t1` DISABLE KEYS */;
144 INSERT INTO `t1` VALUES (1),(2);
145 /*!40000 ALTER TABLE `t1` ENABLE KEYS */;
146 UNLOCK TABLES;
147 /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
149 /*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
150 /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
151 /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
152 /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
153 /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
154 /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
155 /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
158 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
159 /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
160 /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
161 /*!40101 SET NAMES utf8 */;
162 /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
163 /*!40103 SET TIME_ZONE='+00:00' */;
164 /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
165 /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
166 /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
167 /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
168 DROP TABLE IF EXISTS `t1`;
169 /*!40101 SET @saved_cs_client     = @@character_set_client */;
170 /*!40101 SET character_set_client = utf8 */;
171 CREATE TABLE `t1` (
172   `a` int(11) DEFAULT NULL
174 /*!40101 SET character_set_client = @saved_cs_client */;
176 LOCK TABLES `t1` WRITE;
177 /*!40000 ALTER TABLE `t1` DISABLE KEYS */;
178 INSERT INTO `t1` VALUES (1),(2);
179 /*!40000 ALTER TABLE `t1` ENABLE KEYS */;
180 UNLOCK TABLES;
181 /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
183 /*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
184 /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
185 /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
186 /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
187 /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
188 /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
189 /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
191 SSL error: Unable to get private key from 'MYSQL_TEST_DIR/std_data/client-cert.pem'
192 mysqldump: Got error: 2026: SSL connection error when trying to connect
193 DROP TABLE t1;
194 Variable_name   Value
195 Ssl_cipher      DHE-RSA-AES256-SHA
196 Variable_name   Value
197 Ssl_cipher      EDH-RSA-DES-CBC3-SHA
198 Variable_name   Value
199 Ssl_cipher      EDH-RSA-DES-CBC-SHA
200 Variable_name   Value
201 Ssl_cipher      RC4-SHA
202 select 'is still running; no cipher request crashed the server' as result from dual;
203 result
204 is still running; no cipher request crashed the server
205 GRANT SELECT ON test.* TO bug42158@localhost REQUIRE X509;
206 FLUSH PRIVILEGES;
207 SHOW STATUS LIKE 'Ssl_cipher';
208 Variable_name   Value
209 Ssl_cipher      DHE-RSA-AES256-SHA
210 DROP USER bug42158@localhost;
211 End of 5.1 tests