1include/master-slave.inc 2Warnings: 3Note #### Sending passwords in plain text without SSL/TLS is extremely insecure. 4Note #### Storing MySQL user name or password information in the master info repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START SLAVE; see the 'START SLAVE Syntax' in the MySQL Manual for more information. 5[connection master] 6SHOW GLOBAL VARIABLES LIKE 'log_builtin_as_identified_by_password'; 7Variable_name Value 8log_builtin_as_identified_by_password OFF 9# 10# WL#6409: CREATE/ALTER USER 11# 12# CREATE USER 13 14CREATE USER user1; 15SELECT host,user,plugin,authentication_string 16FROM mysql.user WHERE user = 'user1'; 17host % 18user user1 19plugin mysql_native_password 20authentication_string 21 22CREATE USER user3@%; 23ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '%' at line 1 24CREATE USER user3@localhost BY 'auth_string' WITH 'mysql_native_password'; 25ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'BY 'auth_string' WITH 'mysql_native_password'' at line 1 26CREATE USER "user2"@'%'; 27SELECT host,user,plugin,authentication_string 28FROM mysql.user WHERE user='user2'; 29host % 30user user2 31plugin mysql_native_password 32authentication_string 33 34CREATE USER u1@localhost; 35SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='u1'; 36user u1 37plugin mysql_native_password 38authentication_string # 39CREATE USER u2@localhost IDENTIFIED BY 'auth_string' ACCOUNT LOCK; 40SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='u2'; 41user u2 42plugin mysql_native_password 43authentication_string # 44 45CREATE USER user5@localhost IDENTIFIED AS 'auth_string'; 46ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AS 'auth_string'' at line 1 47CREATE USER u3@localhost IDENTIFIED WITH 'mysql_native_password'; 48SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='u3'; 49user u3 50plugin mysql_native_password 51authentication_string # 52CREATE USER u4@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 53SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='u4'; 54user u4 55plugin mysql_native_password 56authentication_string # 57SELECT USER(); 58USER() 59u4@localhost 60 61CREATE USER user4@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 62SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='user4'; 63user user4 64plugin mysql_native_password 65authentication_string # 66 67CREATE USER user6@localhost IDENTIFIED WITH 'mysql_native_password'; 68SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='user6'; 69user user6 70plugin mysql_native_password 71authentication_string # 72 73CREATE USER user7@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#%y' 74 PASSWORD EXPIRE NEVER ACCOUNT UNLOCK; 75SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='user7'; 76user user7 77plugin mysql_native_password 78authentication_string # 79 80SELECT USER(); 81USER() 82user7@localhost 83CREATE USER user8@localhost IDENTIFIED WITH 'mysql_native_password' 84 AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF'; 85SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='user8'; 86user user8 87plugin mysql_native_password 88authentication_string # 89SELECT USER(); 90USER() 91user8@localhost 92CREATE USER tu1@localhost IDENTIFIED WITH 'mysql_native_password'; 93SELECT user,plugin,authentication_string,password_expired, 94password_expired FROM mysql.user WHERE USER='tu1'; 95user tu1 96plugin mysql_native_password 97authentication_string # 98password_expired N 99password_expired N 100CREATE USER tu2@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_@13*'; 101SELECT user,plugin,authentication_string, 102password_expired FROM mysql.user WHERE USER='tu2'; 103user tu2 104plugin mysql_native_password 105authentication_string # 106password_expired N 107 108CREATE USER tu3@localhost IDENTIFIED WITH 'mysql_native_password' BY '%auth_O0s-tring'; 109SELECT user,plugin,authentication_string,password_expired 110FROM mysql.user WHERE USER='tu3'; 111user tu3 112plugin mysql_native_password 113authentication_string # 114password_expired N 115 116CREATE USER u5@localhost REQUIRE SSL; 117SELECT user,plugin,authentication_string,ssl_type 118FROM mysql.user WHERE USER='u5'; 119user u5 120plugin mysql_native_password 121authentication_string # 122ssl_type ANY 123CREATE USER u6@localhost IDENTIFIED BY 'auth_string' REQUIRE X509; 124SELECT user,plugin,authentication_string,ssl_type 125FROM mysql.user WHERE USER='u6'; 126user u6 127plugin mysql_native_password 128authentication_string # 129ssl_type X509 130CREATE USER tu4@localhost IDENTIFIED WITH 'mysql_native_password' BY 'djgsj743$' REQUIRE SSL; 131SELECT user,plugin,authentication_string,ssl_type FROM mysql.user WHERE USER='tu4'; 132user tu4 133plugin mysql_native_password 134authentication_string # 135ssl_type ANY 136CREATE USER tu5@localhost IDENTIFIED WITH 'mysql_native_password' BY 'dwh@#ghd$!' REQUIRE X509; 137SELECT user,plugin,authentication_string,ssl_type FROM mysql.user WHERE USER='tu5'; 138user tu5 139plugin mysql_native_password 140authentication_string # 141ssl_type X509 142CREATE USER u7@localhost IDENTIFIED WITH 'mysql_native_password' 143 REQUIRE CIPHER 'cipher'; 144SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 145x509_issuer,x509_subject FROM mysql.user WHERE USER='u7'; 146user u7 147plugin mysql_native_password 148authentication_string # 149ssl_type SPECIFIED 150ssl_cipher cipher 151x509_issuer 152x509_subject 153CREATE USER u8@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 154 REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA'; 155SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 156x509_issuer,x509_subject FROM mysql.user WHERE USER='u8'; 157user u8 158plugin mysql_native_password 159authentication_string # 160ssl_type SPECIFIED 161ssl_cipher 162x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 163x509_subject 164CREATE USER u9@localhost REQUIRE SUBJECT 'sub'; 165SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 166x509_issuer,x509_subject FROM mysql.user WHERE USER='u9'; 167user u9 168plugin mysql_native_password 169authentication_string # 170ssl_type SPECIFIED 171ssl_cipher 172x509_issuer 173x509_subject sub 174CREATE USER u10@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string#y' 175 REQUIRE CIPHER "DHE-RSA-AES256-SHA" AND 176SUBJECT "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client" 177 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA"; 178SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 179x509_issuer,x509_subject FROM mysql.user WHERE USER='u10'; 180user u10 181plugin mysql_native_password 182authentication_string # 183ssl_type SPECIFIED 184ssl_cipher DHE-RSA-AES256-SHA 185x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 186x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 187SELECT USER(); 188USER() 189u10@localhost 190CREATE USER tu6@localhost IDENTIFIED WITH 'mysql_native_password' BY '#hGrt0O6' 191 REQUIRE CIPHER "DHE-RSA-AES256-SHA" AND 192SUBJECT "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client" 193 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA" 194 WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2; 195SELECT user,plugin,authentication_string,ssl_type,ssl_cipher,x509_issuer, 196x509_subject,max_questions,max_user_connections FROM mysql.user WHERE USER='tu6'; 197user tu6 198plugin mysql_native_password 199authentication_string # 200ssl_type SPECIFIED 201ssl_cipher DHE-RSA-AES256-SHA 202x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 203x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 204max_questions 2 205max_user_connections 2 206CREATE USER u11@localhost WITH MAX_QUERIES_PER_HOUR 2; 207SELECT user,plugin,authentication_string,max_questions 208FROM mysql.user WHERE USER='u11'; 209user u11 210plugin mysql_native_password 211authentication_string # 212max_questions 2 213CREATE USER u12@localhost IDENTIFIED BY 'auth_string' WITH MAX_QUERIES_PER_HOUR 2; 214SELECT user,plugin,authentication_string,max_questions 215FROM mysql.user WHERE USER='u12'; 216user u12 217plugin mysql_native_password 218authentication_string # 219max_questions 2 220CREATE USER u13@localhost IDENTIFIED WITH 'mysql_native_password' 221 WITH MAX_CONNECTIONS_PER_HOUR 2; 222SELECT user,plugin,authentication_string,max_connections 223FROM mysql.user WHERE USER='u13'; 224user u13 225plugin mysql_native_password 226authentication_string # 227max_connections 2 228CREATE USER u14@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 229 WITH MAX_USER_CONNECTIONS 2 ACCOUNT LOCK; 230SELECT user,plugin,authentication_string,max_user_connections 231FROM mysql.user WHERE USER='u14'; 232user u14 233plugin mysql_native_password 234authentication_string # 235max_user_connections 2 236CREATE USER u15@localhost, 237u16@localhost IDENTIFIED BY 'auth_string', 238u17@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 239SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='u15'; 240user u15 241plugin mysql_native_password 242authentication_string # 243SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='u16'; 244user u16 245plugin mysql_native_password 246authentication_string # 247SELECT user,plugin,authentication_string FROM mysql.user WHERE USER='u17'; 248user u17 249plugin mysql_native_password 250authentication_string # 251CREATE USER u18@localhost, 252u19@localhost IDENTIFIED BY 'auth_string', 253u20@localhost IDENTIFIED WITH 'mysql_native_password', 254u21@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string', 255u22@localhost IDENTIFIED WITH 'mysql_native_password', 256u23@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_&string' 257 REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 258 WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 ACCOUNT UNLOCK; 259SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 260x509_issuer,x509_subject,max_questions,max_user_connections FROM mysql.user WHERE USER='u18'; 261user u18 262plugin mysql_native_password 263authentication_string # 264ssl_type SPECIFIED 265ssl_cipher 266x509_issuer 267x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 268max_questions 2 269max_user_connections 2 270SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 271x509_issuer,x509_subject,max_questions,max_user_connections FROM mysql.user WHERE USER='u19'; 272user u19 273plugin mysql_native_password 274authentication_string # 275ssl_type SPECIFIED 276ssl_cipher 277x509_issuer 278x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 279max_questions 2 280max_user_connections 2 281SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 282x509_issuer,x509_subject,max_questions,max_user_connections FROM mysql.user WHERE USER='u20'; 283user u20 284plugin mysql_native_password 285authentication_string # 286ssl_type SPECIFIED 287ssl_cipher 288x509_issuer 289x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 290max_questions 2 291max_user_connections 2 292SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 293x509_issuer,x509_subject,max_questions,max_user_connections FROM mysql.user WHERE USER='u22'; 294user u22 295plugin mysql_native_password 296authentication_string # 297ssl_type SPECIFIED 298ssl_cipher 299x509_issuer 300x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 301max_questions 2 302max_user_connections 2 303SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 304x509_issuer,x509_subject,max_questions,max_user_connections FROM mysql.user WHERE USER='u23'; 305user u23 306plugin mysql_native_password 307authentication_string # 308ssl_type SPECIFIED 309ssl_cipher 310x509_issuer 311x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 312max_questions 2 313max_user_connections 2 314DROP USER tu1@localhost,tu2@localhost,tu3@localhost,tu4@localhost,tu5@localhost, 315tu6@localhost,user1@'%',user2@'%',user4@localhost,user6@localhost, 316user7@localhost,user8@localhost, u1@localhost,u2@localhost,u3@localhost, 317u4@localhost,u5@localhost,u6@localhost, u7@localhost, u8@localhost, 318u9@localhost, u10@localhost,u11@localhost, u12@localhost,u13@localhost, 319u14@localhost,u15@localhost,u16@localhost,u17@localhost,u18@localhost, 320u19@localhost, u20@localhost,u21@localhost,u22@localhost,u23@localhost; 321# ALTER USER 322CREATE USER u1@localhost; 323SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 324plugin,authentication_string,password_expired, 325password_last_changed,password_lifetime 326FROM mysql.user WHERE USER='u1'; 327user u1 328ssl_type 329ssl_cipher 330x509_issuer 331x509_subject 332plugin mysql_native_password 333authentication_string # 334password_expired N 335password_last_changed # 336password_lifetime NULL 337# Its a no op 338ALTER USER u1@localhost; 339SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 340plugin,authentication_string,password_expired, 341password_last_changed,password_lifetime 342FROM mysql.user WHERE USER='u1'; 343user u1 344ssl_type 345ssl_cipher 346x509_issuer 347x509_subject 348plugin mysql_native_password 349authentication_string # 350password_expired N 351password_last_changed # 352password_lifetime NULL 353CREATE USER u2@localhost IDENTIFIED BY 'password_string'; 354SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 355plugin,authentication_string,password_expired, 356password_last_changed,password_lifetime FROM mysql.user WHERE USER='u2'; 357user u2 358ssl_type 359ssl_cipher 360x509_issuer 361x509_subject 362plugin mysql_native_password 363authentication_string # 364password_expired N 365password_last_changed # 366password_lifetime NULL 367ALTER USER u2@localhost IDENTIFIED BY 'new_auth_string'; 368SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 369plugin,authentication_string,password_expired, 370password_last_changed,password_lifetime FROM mysql.user WHERE USER='u2'; 371user u2 372ssl_type 373ssl_cipher 374x509_issuer 375x509_subject 376plugin mysql_native_password 377authentication_string # 378password_expired N 379password_last_changed # 380password_lifetime NULL 381SELECT USER(); 382USER() 383u2@localhost 384 385CREATE USER u3@localhost IDENTIFIED WITH 'mysql_native_password' ACCOUNT LOCK; 386SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 387plugin,authentication_string,password_expired, 388password_last_changed,password_lifetime FROM mysql.user WHERE USER='u3'; 389user u3 390ssl_type 391ssl_cipher 392x509_issuer 393x509_subject 394plugin mysql_native_password 395authentication_string # 396password_expired N 397password_last_changed # 398password_lifetime NULL 399ALTER USER u3@localhost IDENTIFIED WITH 'mysql_native_password' 400 AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 401 PASSWORD EXPIRE NEVER ACCOUNT UNLOCK; 402SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 403plugin,authentication_string,password_expired, 404password_last_changed,password_lifetime FROM mysql.user WHERE USER='u3'; 405user u3 406ssl_type 407ssl_cipher 408x509_issuer 409x509_subject 410plugin mysql_native_password 411authentication_string # 412password_expired N 413password_last_changed # 414password_lifetime 0 415SELECT USER(); 416USER() 417u3@localhost 418ALTER USER u3@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 419SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 420plugin,authentication_string,password_expired, 421password_last_changed,password_lifetime FROM mysql.user WHERE USER='u3'; 422user u3 423ssl_type 424ssl_cipher 425x509_issuer 426x509_subject 427plugin mysql_native_password 428authentication_string # 429password_expired N 430password_last_changed # 431password_lifetime 0 432ALTER USER u3@localhost 433REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 434 WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 435PASSWORD EXPIRE NEVER; 436SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 437plugin,authentication_string,password_expired, 438password_last_changed,password_lifetime FROM mysql.user WHERE USER='u3'; 439user u3 440ssl_type SPECIFIED 441ssl_cipher 442x509_issuer 443x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 444plugin mysql_native_password 445authentication_string # 446password_expired N 447password_last_changed # 448password_lifetime 0 449CREATE USER u4@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 450 ACCOUNT LOCK PASSWORD EXPIRE DEFAULT; 451SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 452plugin,authentication_string,password_expired, 453password_last_changed,password_lifetime FROM mysql.user WHERE USER='u4'; 454user u4 455ssl_type 456ssl_cipher 457x509_issuer 458x509_subject 459plugin mysql_native_password 460authentication_string # 461password_expired N 462password_last_changed # 463password_lifetime NULL 464ALTER USER u4@localhost IDENTIFIED WITH 'mysql_native_password' 465 BY 'auth_string' ACCOUNT UNLOCK; 466SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 467plugin,authentication_string,password_expired, 468password_last_changed,password_lifetime FROM mysql.user WHERE USER='u4'; 469user u4 470ssl_type 471ssl_cipher 472x509_issuer 473x509_subject 474plugin mysql_native_password 475authentication_string # 476password_expired N 477password_last_changed # 478password_lifetime NULL 479CREATE USER u5@localhost REQUIRE SSL; 480SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 481plugin,authentication_string,password_expired, 482password_last_changed,password_lifetime FROM mysql.user WHERE USER='u5'; 483user u5 484ssl_type ANY 485ssl_cipher 486x509_issuer 487x509_subject 488plugin mysql_native_password 489authentication_string # 490password_expired N 491password_last_changed # 492password_lifetime NULL 493ALTER USER u5@localhost IDENTIFIED WITH 'mysql_native_password'; 494SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 495plugin,authentication_string,password_expired, 496password_last_changed,password_lifetime FROM mysql.user WHERE USER='u5'; 497user u5 498ssl_type ANY 499ssl_cipher 500x509_issuer 501x509_subject 502plugin mysql_native_password 503authentication_string # 504password_expired Y 505password_last_changed # 506password_lifetime NULL 507SET PASSWORD='new_auth_string'; 508SELECT USER(); 509USER() 510u5@localhost 511CREATE USER u6@localhost IDENTIFIED BY 'auth_string' REQUIRE X509 ACCOUNT UNLOCK ACCOUNT LOCK PASSWORD EXPIRE INTERVAL 80 DAY; 512SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 513plugin,authentication_string,password_expired, 514password_last_changed,password_lifetime FROM mysql.user WHERE USER='u6'; 515user u6 516ssl_type X509 517ssl_cipher 518x509_issuer 519x509_subject 520plugin mysql_native_password 521authentication_string # 522password_expired N 523password_last_changed # 524password_lifetime 80 525ALTER USER u6@localhost IDENTIFIED WITH 'mysql_native_password' BY 'new_auth_string' REQUIRE SSL ACCOUNT UNLOCK; 526SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 527plugin,authentication_string,password_expired, 528password_last_changed,password_lifetime FROM mysql.user WHERE USER='u6'; 529user u6 530ssl_type ANY 531ssl_cipher 532x509_issuer 533x509_subject 534plugin mysql_native_password 535authentication_string # 536password_expired N 537password_last_changed # 538password_lifetime 80 539CREATE USER u7@localhost IDENTIFIED WITH 'mysql_native_password' 540 BY 'auth_string' REQUIRE CIPHER 'DHE-RSA-AES256-SHA'; 541SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 542plugin,authentication_string,password_expired, 543password_last_changed,password_lifetime FROM mysql.user WHERE USER='u7'; 544user u7 545ssl_type SPECIFIED 546ssl_cipher DHE-RSA-AES256-SHA 547x509_issuer 548x509_subject 549plugin mysql_native_password 550authentication_string # 551password_expired N 552password_last_changed # 553password_lifetime NULL 554ALTER USER u7@localhost IDENTIFIED WITH 'mysql_native_password' BY 'new_auth_string' 555 REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' ACCOUNT UNLOCK; 556SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 557plugin,authentication_string,password_expired, 558password_last_changed,password_lifetime FROM mysql.user WHERE USER='u7'; 559user u7 560ssl_type SPECIFIED 561ssl_cipher 562x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 563x509_subject 564plugin mysql_native_password 565authentication_string # 566password_expired N 567password_last_changed # 568password_lifetime NULL 569SELECT USER(); 570USER() 571u7@localhost 572CREATE USER u8@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 573 REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA'; 574SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 575plugin,authentication_string,password_expired, 576password_last_changed,password_lifetime FROM mysql.user WHERE USER='u8'; 577user u8 578ssl_type SPECIFIED 579ssl_cipher 580x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 581x509_subject 582plugin mysql_native_password 583authentication_string # 584password_expired N 585password_last_changed # 586password_lifetime NULL 587ALTER USER u8@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 588 REQUIRE CIPHER "DHE-RSA-AES256-SHA"; 589SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 590plugin,authentication_string,password_expired, 591password_last_changed,password_lifetime FROM mysql.user WHERE USER='u8'; 592user u8 593ssl_type SPECIFIED 594ssl_cipher DHE-RSA-AES256-SHA 595x509_issuer 596x509_subject 597plugin mysql_native_password 598authentication_string # 599password_expired N 600password_last_changed # 601password_lifetime NULL 602SELECT USER(); 603USER() 604u8@localhost 605CREATE USER tu1@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 606 REQUIRE ISSUER 'issuer'; 607SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 608plugin,authentication_string,password_expired, 609password_last_changed,password_lifetime FROM mysql.user WHERE USER='tu1'; 610user tu1 611ssl_type SPECIFIED 612ssl_cipher 613x509_issuer issuer 614x509_subject 615plugin mysql_native_password 616authentication_string # 617password_expired N 618password_last_changed # 619password_lifetime NULL 620ALTER USER tu1@localhost IDENTIFIED WITH 'mysql_native_password' 621 REQUIRE CIPHER "DHE-RSA-AES256-SHA"; 622SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 623plugin,authentication_string,password_expired, 624password_last_changed,password_lifetime FROM mysql.user WHERE USER='tu1'; 625user tu1 626ssl_type SPECIFIED 627ssl_cipher DHE-RSA-AES256-SHA 628x509_issuer 629x509_subject 630plugin mysql_native_password 631authentication_string # 632password_expired Y 633password_last_changed # 634password_lifetime NULL 635CREATE USER u9@localhost REQUIRE SUBJECT 'sub'; 636SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 637plugin,authentication_string,password_expired, 638password_last_changed,password_lifetime FROM mysql.user WHERE USER='u9'; 639user u9 640ssl_type SPECIFIED 641ssl_cipher 642x509_issuer 643x509_subject sub 644plugin mysql_native_password 645authentication_string # 646password_expired N 647password_last_changed # 648password_lifetime NULL 649ALTER USER u9@localhost REQUIRE ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA"; 650SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 651plugin,authentication_string,password_expired, 652password_last_changed,password_lifetime FROM mysql.user WHERE USER='u9'; 653user u9 654ssl_type SPECIFIED 655ssl_cipher 656x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 657x509_subject 658plugin mysql_native_password 659authentication_string # 660password_expired N 661password_last_changed # 662password_lifetime NULL 663ALTER USER u9@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string77hg' 664 REQUIRE ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA"; 665SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 666plugin,authentication_string,password_expired, 667password_last_changed,password_lifetime FROM mysql.user WHERE USER='u9'; 668user u9 669ssl_type SPECIFIED 670ssl_cipher 671x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 672x509_subject 673plugin mysql_native_password 674authentication_string # 675password_expired N 676password_last_changed # 677password_lifetime NULL 678CREATE USER u10@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 679 REQUIRE CIPHER "DHE-RSA-AES256-SHA" AND 680SUBJECT "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client" 681 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA"; 682SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 683plugin,authentication_string,password_expired, 684password_last_changed,password_lifetime FROM mysql.user WHERE USER='u10'; 685user u10 686ssl_type SPECIFIED 687ssl_cipher DHE-RSA-AES256-SHA 688x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 689x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 690plugin mysql_native_password 691authentication_string # 692password_expired N 693password_last_changed # 694password_lifetime NULL 695ALTER USER u10@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 696 REQUIRE SSL; 697SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 698plugin,authentication_string,password_expired, 699password_last_changed,password_lifetime FROM mysql.user WHERE USER='u10'; 700user u10 701ssl_type ANY 702ssl_cipher 703x509_issuer 704x509_subject 705plugin mysql_native_password 706authentication_string # 707password_expired N 708password_last_changed # 709password_lifetime NULL 710SELECT USER(); 711USER() 712u10@localhost 713CREATE USER u11@localhost WITH MAX_QUERIES_PER_HOUR 2; 714SELECT user,max_questions FROM mysql.user WHERE USER='u11'; 715user u11 716max_questions 2 717ALTER USER u11@localhost WITH MAX_QUERIES_PER_HOUR 6; 718SELECT user,max_questions FROM mysql.user WHERE USER='u11'; 719user u11 720max_questions 6 721CREATE USER u12@localhost IDENTIFIED BY 'auth_string' 722 WITH MAX_QUERIES_PER_HOUR 2; 723SELECT user,max_questions FROM mysql.user WHERE USER='u12'; 724user u12 725max_questions 2 726ALTER USER u12@localhost IDENTIFIED WITH 'mysql_native_password' 727 WITH MAX_QUERIES_PER_HOUR 8; 728SELECT user,max_questions FROM mysql.user WHERE USER='u12'; 729user u12 730max_questions 8 731ALTER USER u12@localhost IDENTIFIED WITH 'mysql_native_password' 732 WITH MAX_QUERIES_PER_HOUR 1000; 733SELECT user,max_questions FROM mysql.user WHERE USER='u12'; 734user u12 735max_questions 1000 736CREATE USER u13@localhost IDENTIFIED WITH 'mysql_native_password' 737 WITH MAX_CONNECTIONS_PER_HOUR 2; 738SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 739plugin,authentication_string,password_expired, 740password_last_changed,password_lifetime FROM mysql.user WHERE USER='u13'; 741user u13 742ssl_type 743ssl_cipher 744x509_issuer 745x509_subject 746plugin mysql_native_password 747authentication_string # 748password_expired N 749password_last_changed # 750password_lifetime NULL 751ALTER USER u13@localhost PASSWORD EXPIRE; 752SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 753plugin,authentication_string,password_expired, 754password_last_changed,password_lifetime FROM mysql.user WHERE USER='u13'; 755user u13 756ssl_type 757ssl_cipher 758x509_issuer 759x509_subject 760plugin mysql_native_password 761authentication_string # 762password_expired Y 763password_last_changed # 764password_lifetime NULL 765CREATE USER u14@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 766 WITH MAX_USER_CONNECTIONS 2; 767SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 768plugin,authentication_string,password_expired,max_user_connections, 769password_last_changed,password_lifetime FROM mysql.user WHERE USER='u14'; 770user u14 771ssl_type 772ssl_cipher 773x509_issuer 774x509_subject 775plugin mysql_native_password 776authentication_string # 777password_expired N 778max_user_connections 2 779password_last_changed # 780password_lifetime NULL 781ALTER USER u14@localhost WITH MAX_USER_CONNECTIONS 12 782PASSWORD EXPIRE INTERVAL 365 DAY; 783SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 784plugin,authentication_string,password_expired,max_user_connections, 785password_last_changed,password_lifetime FROM mysql.user WHERE USER='u14'; 786user u14 787ssl_type 788ssl_cipher 789x509_issuer 790x509_subject 791plugin mysql_native_password 792authentication_string # 793password_expired N 794max_user_connections 12 795password_last_changed # 796password_lifetime 365 797CREATE USER tu2@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 798 WITH MAX_USER_CONNECTIONS 2 ; 799SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 800plugin,authentication_string,password_expired,max_user_connections,max_questions, 801password_last_changed,password_lifetime FROM mysql.user WHERE USER='tu2'; 802user tu2 803ssl_type 804ssl_cipher 805x509_issuer 806x509_subject 807plugin mysql_native_password 808authentication_string # 809password_expired N 810max_user_connections 2 811max_questions 0 812password_last_changed # 813password_lifetime NULL 814ALTER USER tu2@localhost WITH MAX_USER_CONNECTIONS 12 MAX_QUERIES_PER_HOUR 543 815PASSWORD EXPIRE INTERVAL 365 DAY; 816SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 817plugin,authentication_string,password_expired,max_user_connections,max_questions, 818password_last_changed,password_lifetime FROM mysql.user WHERE USER='tu2'; 819user tu2 820ssl_type 821ssl_cipher 822x509_issuer 823x509_subject 824plugin mysql_native_password 825authentication_string # 826password_expired N 827max_user_connections 12 828max_questions 543 829password_last_changed # 830password_lifetime 365 831SELECT USER(); 832USER() 833tu2@localhost 834CREATE USER u15@localhost, 835u16@localhost IDENTIFIED WITH 'mysql_native_password', 836u17@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 837SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 838plugin,authentication_string,password_expired, 839password_last_changed,password_lifetime FROM mysql.user 840WHERE USER='u15'; 841user u15 842ssl_type 843ssl_cipher 844x509_issuer 845x509_subject 846plugin mysql_native_password 847authentication_string # 848password_expired N 849password_last_changed # 850password_lifetime NULL 851SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 852plugin,authentication_string,password_expired, 853password_last_changed,password_lifetime FROM mysql.user 854WHERE USER='u16'; 855user u16 856ssl_type 857ssl_cipher 858x509_issuer 859x509_subject 860plugin mysql_native_password 861authentication_string # 862password_expired N 863password_last_changed # 864password_lifetime NULL 865SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 866plugin,authentication_string,password_expired, 867password_last_changed,password_lifetime FROM mysql.user 868WHERE USER='u17'; 869user u17 870ssl_type 871ssl_cipher 872x509_issuer 873x509_subject 874plugin mysql_native_password 875authentication_string # 876password_expired N 877password_last_changed # 878password_lifetime NULL 879ALTER USER u15@localhost IDENTIFIED WITH 'mysql_native_password', 880u16@localhost, 881u17@localhost IDENTIFIED BY 'new_auth_string' 882 PASSWORD EXPIRE DEFAULT; 883SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 884plugin,authentication_string,password_expired, 885password_last_changed,password_lifetime FROM mysql.user 886WHERE USER='u15'; 887user u15 888ssl_type 889ssl_cipher 890x509_issuer 891x509_subject 892plugin mysql_native_password 893authentication_string # 894password_expired Y 895password_last_changed # 896password_lifetime NULL 897SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 898plugin,authentication_string,password_expired, 899password_last_changed,password_lifetime FROM mysql.user 900WHERE USER='u16'; 901user u16 902ssl_type 903ssl_cipher 904x509_issuer 905x509_subject 906plugin mysql_native_password 907authentication_string # 908password_expired N 909password_last_changed # 910password_lifetime NULL 911SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 912plugin,authentication_string,password_expired, 913password_last_changed,password_lifetime FROM mysql.user 914WHERE USER='u17'; 915user u17 916ssl_type 917ssl_cipher 918x509_issuer 919x509_subject 920plugin mysql_native_password 921authentication_string # 922password_expired N 923password_last_changed # 924password_lifetime NULL 925CREATE USER u18@localhost, 926u19@localhost IDENTIFIED BY 'auth_string', 927u20@localhost IDENTIFIED WITH 'mysql_native_password', 928u21@localhost IDENTIFIED WITH 'mysql_native_password' BY '!Y_TOdh6)', 929u22@localhost IDENTIFIED WITH 'mysql_native_password', 930u23@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_&string' 931 REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 932 WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2; 933SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 934plugin,authentication_string,password_expired,max_user_connections, 935max_questions,password_last_changed,password_lifetime FROM mysql.user 936WHERE USER='u18'; 937user u18 938ssl_type SPECIFIED 939ssl_cipher 940x509_issuer 941x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 942plugin mysql_native_password 943authentication_string # 944password_expired N 945max_user_connections 2 946max_questions 2 947password_last_changed # 948password_lifetime NULL 949SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 950plugin,authentication_string,password_expired,max_user_connections, 951max_questions,password_last_changed,password_lifetime FROM mysql.user 952WHERE USER='u19'; 953user u19 954ssl_type SPECIFIED 955ssl_cipher 956x509_issuer 957x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 958plugin mysql_native_password 959authentication_string # 960password_expired N 961max_user_connections 2 962max_questions 2 963password_last_changed # 964password_lifetime NULL 965SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 966plugin,authentication_string,password_expired,max_user_connections, 967max_questions,password_last_changed,password_lifetime FROM mysql.user 968WHERE USER='u20'; 969user u20 970ssl_type SPECIFIED 971ssl_cipher 972x509_issuer 973x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 974plugin mysql_native_password 975authentication_string # 976password_expired N 977max_user_connections 2 978max_questions 2 979password_last_changed # 980password_lifetime NULL 981SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 982plugin,authentication_string,password_expired,max_user_connections, 983max_questions,password_last_changed,password_lifetime FROM mysql.user 984WHERE USER='u21'; 985user u21 986ssl_type SPECIFIED 987ssl_cipher 988x509_issuer 989x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 990plugin mysql_native_password 991authentication_string # 992password_expired N 993max_user_connections 2 994max_questions 2 995password_last_changed # 996password_lifetime NULL 997SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 998plugin,authentication_string,password_expired,max_user_connections, 999max_questions,password_last_changed,password_lifetime FROM mysql.user 1000WHERE USER='u22'; 1001user u22 1002ssl_type SPECIFIED 1003ssl_cipher 1004x509_issuer 1005x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1006plugin mysql_native_password 1007authentication_string # 1008password_expired N 1009max_user_connections 2 1010max_questions 2 1011password_last_changed # 1012password_lifetime NULL 1013SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1014plugin,authentication_string,password_expired,max_user_connections, 1015max_questions,password_last_changed,password_lifetime FROM mysql.user 1016WHERE USER='u23'; 1017user u23 1018ssl_type SPECIFIED 1019ssl_cipher 1020x509_issuer 1021x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1022plugin mysql_native_password 1023authentication_string # 1024password_expired N 1025max_user_connections 2 1026max_questions 2 1027password_last_changed # 1028password_lifetime NULL 1029ALTER USER u18@localhost, u19@localhost, 1030u20@localhost, u21@localhost, 1031u22@localhost, u23@localhost 1032REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 1033 WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 1034PASSWORD EXPIRE NEVER; 1035SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1036plugin,authentication_string,password_expired,max_user_connections, 1037max_questions,password_last_changed,password_lifetime FROM mysql.user 1038WHERE USER='u18'; 1039user u18 1040ssl_type SPECIFIED 1041ssl_cipher 1042x509_issuer 1043x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1044plugin mysql_native_password 1045authentication_string # 1046password_expired N 1047max_user_connections 2 1048max_questions 2 1049password_last_changed # 1050password_lifetime 0 1051SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1052plugin,authentication_string,password_expired,max_user_connections, 1053max_questions,password_last_changed,password_lifetime FROM mysql.user 1054WHERE USER='u19'; 1055user u19 1056ssl_type SPECIFIED 1057ssl_cipher 1058x509_issuer 1059x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1060plugin mysql_native_password 1061authentication_string # 1062password_expired N 1063max_user_connections 2 1064max_questions 2 1065password_last_changed # 1066password_lifetime 0 1067SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1068plugin,authentication_string,password_expired,max_user_connections, 1069max_questions,password_last_changed,password_lifetime FROM mysql.user 1070WHERE USER='u20'; 1071user u20 1072ssl_type SPECIFIED 1073ssl_cipher 1074x509_issuer 1075x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1076plugin mysql_native_password 1077authentication_string # 1078password_expired N 1079max_user_connections 2 1080max_questions 2 1081password_last_changed # 1082password_lifetime 0 1083SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1084plugin,authentication_string,password_expired,max_user_connections, 1085max_questions,password_last_changed,password_lifetime FROM mysql.user 1086WHERE USER='u21'; 1087user u21 1088ssl_type SPECIFIED 1089ssl_cipher 1090x509_issuer 1091x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1092plugin mysql_native_password 1093authentication_string # 1094password_expired N 1095max_user_connections 2 1096max_questions 2 1097password_last_changed # 1098password_lifetime 0 1099SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1100plugin,authentication_string,password_expired,max_user_connections, 1101max_questions,password_last_changed,password_lifetime FROM mysql.user 1102WHERE USER='u22'; 1103user u22 1104ssl_type SPECIFIED 1105ssl_cipher 1106x509_issuer 1107x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1108plugin mysql_native_password 1109authentication_string # 1110password_expired N 1111max_user_connections 2 1112max_questions 2 1113password_last_changed # 1114password_lifetime 0 1115SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1116plugin,authentication_string,password_expired,max_user_connections, 1117max_questions,password_last_changed,password_lifetime FROM mysql.user 1118WHERE USER='u23'; 1119user u23 1120ssl_type SPECIFIED 1121ssl_cipher 1122x509_issuer 1123x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1124plugin mysql_native_password 1125authentication_string # 1126password_expired N 1127max_user_connections 2 1128max_questions 2 1129password_last_changed # 1130password_lifetime 0 1131DROP USER tu1@localhost,tu2@localhost,u1@localhost, u2@localhost, u3@localhost, 1132u4@localhost,u5@localhost,u6@localhost, u7@localhost, u8@localhost, 1133u9@localhost,u10@localhost,u11@localhost,u12@localhost,u13@localhost, 1134u14@localhost,u15@localhost,u16@localhost,u17@localhost,u18@localhost, 1135u19@localhost,u20@localhost,u21@localhost,u22@localhost,u23@localhost; 1136# ALTER USER with current user 1137CREATE USER u1@localhost IDENTIFIED BY 'abc'; 1138SELECT USER(); 1139USER() 1140u1@localhost 1141ALTER USER u1@localhost PASSWORD EXPIRE; 1142SELECT USER(); 1143ERROR HY000: You must reset your password using ALTER USER statement before executing this statement. 1144SET PASSWORD = 'def'; 1145SELECT USER(); 1146USER() 1147u1@localhost 1148ALTER USER u1@localhost PASSWORD EXPIRE; 1149SELECT USER(); 1150ERROR HY000: You must reset your password using ALTER USER statement before executing this statement. 1151ALTER USER IDENTIFIED BY 'npwd'; 1152ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'BY 'npwd'' at line 1 1153ALTER USER USER() IDENTIFIED BY 'abc'; 1154SELECT USER(); 1155USER() 1156u1@localhost 1157ALTER USER u1@localhost PASSWORD EXPIRE; 1158SELECT USER(); 1159ERROR HY000: You must reset your password using ALTER USER statement before executing this statement. 1160ALTER USER u1@localhost IDENTIFIED BY 'def'; 1161SELECT USER(); 1162USER() 1163u1@localhost 1164DROP USER u1@localhost; 1165# ALTER USER with current user is allowed to set only credential information 1166CREATE USER u1@localhost, u2@localhost IDENTIFIED BY 'abc'; 1167GRANT ALL ON *.* TO u2@localhost; 1168ALTER USER USER() IDENTIFIED WITH 'sha256_password'; 1169ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''sha256_password'' at line 1 1170ALTER USER USER() IDENTIFIED BY 'def', u2@localhost PASSWORD EXPIRE; 1171ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' u2@localhost PASSWORD EXPIRE' at line 1 1172ALTER USER USER() IDENTIFIED BY 'def' PASSWORD EXPIRE; 1173ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'PASSWORD EXPIRE' at line 1 1174ALTER USER ; 1175ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 1176ALTER USER u2@localhost IDENTIFIED BY 'auth_string' PASSWORD EXPIRE INTERVAL 45 DAY; 1177SELECT user,ssl_type,ssl_cipher,x509_issuer,x509_subject, 1178plugin,authentication_string,password_expired, 1179password_last_changed,password_lifetime FROM mysql.user WHERE USER='u2'; 1180user u2 1181ssl_type 1182ssl_cipher 1183x509_issuer 1184x509_subject 1185plugin mysql_native_password 1186authentication_string # 1187password_expired N 1188password_last_changed # 1189password_lifetime 45 1190DROP USER u1@localhost, u2@localhost; 1191# SHOW CREATE USER 1192CREATE USER u1@localhost; 1193SHOW CREATE USER u1@localhost; 1194CREATE USER for u1@localhost 1195CREATE USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1196CREATE USER u2@localhost IDENTIFIED BY 'auth_string'; 1197SHOW CREATE USER u2@localhost; 1198CREATE USER for u2@localhost 1199CREATE USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1200# DDL output for SHOW CREATE USER u2@localhost and recreating user 1201DROP USER u2@localhost; 1202CREATE USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1203 AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE NONE; 1204SELECT USER(); 1205USER() 1206u2@localhost 1207 1208CREATE USER u3@localhost IDENTIFIED WITH 'mysql_native_password'; 1209SHOW CREATE USER u3@localhost; 1210CREATE USER for u3@localhost 1211CREATE USER 'u3'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1212CREATE USER u4@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 1213SHOW CREATE USER u4@localhost; 1214CREATE USER for u4@localhost 1215CREATE USER 'u4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<non-deterministic-password-hash>' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1216CREATE USER user1@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 1217SHOW CREATE USER user1@localhost; 1218CREATE USER for user1@localhost 1219CREATE USER 'user1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<non-deterministic-password-hash>' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1220 1221CREATE USER user2@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; 1222SHOW CREATE USER user2@localhost; 1223CREATE USER for user2@localhost 1224CREATE USER 'user2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<non-deterministic-password-hash>' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1225 1226CREATE USER u5@localhost REQUIRE SSL; 1227SHOW CREATE USER u5@localhost; 1228CREATE USER for u5@localhost 1229CREATE USER 'u5'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SSL PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1230CREATE USER u6@localhost IDENTIFIED BY 'auth_string' REQUIRE X509; 1231SHOW CREATE USER u6@localhost; 1232CREATE USER for u6@localhost 1233CREATE USER 'u6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE X509 PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1234CREATE USER u7@localhost IDENTIFIED WITH 'mysql_native_password' 1235 REQUIRE CIPHER 'cipher'; 1236SHOW CREATE USER u7@localhost; 1237CREATE USER for u7@localhost 1238CREATE USER 'u7'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE CIPHER 'cipher' PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1239CREATE USER u8@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 1240 REQUIRE ISSUER 'issuer'; 1241SHOW CREATE USER u8@localhost; 1242CREATE USER for u8@localhost 1243CREATE USER 'u8'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<non-deterministic-password-hash>' REQUIRE ISSUER 'issuer' PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1244CREATE USER u9@localhost REQUIRE SUBJECT 'sub'; 1245SHOW CREATE USER u9@localhost; 1246CREATE USER for u9@localhost 1247CREATE USER 'u9'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SUBJECT 'sub' PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1248CREATE USER u10@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 1249 REQUIRE CIPHER "DHE-RSA-AES256-SHA" AND 1250SUBJECT "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client" 1251 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA"; 1252SHOW CREATE USER u10@localhost; 1253CREATE USER for u10@localhost 1254CREATE USER 'u10'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<non-deterministic-password-hash>' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' CIPHER 'DHE-RSA-AES256-SHA' PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1255CREATE USER u11@localhost WITH MAX_QUERIES_PER_HOUR 2; 1256SHOW CREATE USER u11@localhost; 1257CREATE USER for u11@localhost 1258CREATE USER 'u11'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 2 PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1259CREATE USER u12@localhost IDENTIFIED BY 'auth_string' WITH MAX_QUERIES_PER_HOUR 2; 1260SHOW CREATE USER u12@localhost; 1261CREATE USER for u12@localhost 1262CREATE USER 'u12'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 2 PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1263CREATE USER u13@localhost IDENTIFIED WITH 'mysql_native_password' 1264 WITH MAX_CONNECTIONS_PER_HOUR 2; 1265SHOW CREATE USER u13@localhost; 1266CREATE USER for u13@localhost 1267CREATE USER 'u13'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE NONE WITH MAX_CONNECTIONS_PER_HOUR 2 PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1268CREATE USER u14@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 1269 WITH MAX_USER_CONNECTIONS 2; 1270SHOW CREATE USER u14@localhost; 1271CREATE USER for u14@localhost 1272CREATE USER 'u14'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<non-deterministic-password-hash>' WITH MAX_USER_CONNECTIONS 2 PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1273CREATE USER u15@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 1274 REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 1275 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA" 1276 CIPHER 'cipher' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2; 1277SHOW CREATE USER u15@localhost; 1278CREATE USER for u15@localhost 1279CREATE USER 'u15'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '<non-deterministic-password-hash>' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' CIPHER 'cipher' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK 1280DROP USER user1@localhost,u1@localhost,u2@localhost,u3@localhost,u4@localhost, 1281u5@localhost,u6@localhost, u7@localhost, u8@localhost,u9@localhost, 1282u10@localhost,u11@localhost,u12@localhost,u13@localhost,u14@localhost, 1283u15@localhost; 1284 1285# GRANT 1286 1287CREATE USER user1@localhost IDENTIFIED WITH 'mysql_native_password' 1288 AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1289 REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 1290 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA" 1291 WITH MAX_CONNECTIONS_PER_HOUR 1000 MAX_USER_CONNECTIONS 20 1292MAX_QUERIES_PER_HOUR 60 MAX_UPDATES_PER_HOUR 100; 1293SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 1294x509_issuer,x509_subject,max_user_connections, 1295max_questions,max_updates,max_connections FROM mysql.user 1296WHERE USER='user1'; 1297user user1 1298plugin mysql_native_password 1299authentication_string # 1300ssl_type SPECIFIED 1301ssl_cipher 1302x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 1303x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1304max_user_connections 20 1305max_questions 60 1306max_updates 100 1307max_connections 1000 1308 1309GRANT SELECT ON *.* TO user1@localhost; 1310GRANT SELECT,INSERT,UPDATE ON mysql.* TO user1@localhost; 1311 1312SHOW GRANTS FOR user1@localhost; 1313Grants for user1@localhost 1314GRANT SELECT ON *.* TO 'user1'@'localhost' 1315GRANT SELECT, INSERT, UPDATE ON `mysql`.* TO 'user1'@'localhost' 1316 1317REVOKE INSERT,UPDATE ON mysql.* FROM user1@localhost; 1318SHOW GRANTS FOR user1@localhost; 1319Grants for user1@localhost 1320GRANT SELECT ON *.* TO 'user1'@'localhost' 1321GRANT SELECT ON `mysql`.* TO 'user1'@'localhost' 1322 1323GRANT SELECT,INSERT,UPDATE ON *.* TO user2@localhost IDENTIFIED BY 'admin' 1324 REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 1325 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA" 1326 WITH MAX_CONNECTIONS_PER_HOUR 1000 MAX_USER_CONNECTIONS 20 1327MAX_QUERIES_PER_HOUR 60 MAX_UPDATES_PER_HOUR 100; 1328Warnings: 1329Warning 1287 Using GRANT statement to modify existing user's properties other than privileges is deprecated and will be removed in future release. Use ALTER USER statement for this operation. 1330SELECT user,plugin,authentication_string,ssl_type,ssl_cipher, 1331x509_issuer,x509_subject,max_user_connections, 1332max_questions,max_updates,max_connections FROM mysql.user WHERE USER='user2'; 1333user user2 1334plugin mysql_native_password 1335authentication_string # 1336ssl_type SPECIFIED 1337ssl_cipher 1338x509_issuer /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA 1339x509_subject /C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client 1340max_user_connections 20 1341max_questions 60 1342max_updates 100 1343max_connections 1000 1344CREATE USER user3@localhost IDENTIFIED BY 'auth_string'; 1345GRANT SELECT ON mysql.* TO user3@localhost 1346IDENTIFIED WITH 'mysql_native_password' BY 'auth_string' 1347 REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' 1348 ISSUER "/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA" 1349 WITH MAX_CONNECTIONS_PER_HOUR 1000 MAX_USER_CONNECTIONS 20 1350MAX_QUERIES_PER_HOUR 60 MAX_UPDATES_PER_HOUR 100; 1351Warnings: 1352Warning 1287 Using GRANT statement to modify existing user's properties other than privileges is deprecated and will be removed in future release. Use ALTER USER statement for this operation. 1353# Cleanup 1354DROP USER user1@localhost,user2@localhost,user3@localhost; 1355 1356# SET PASSWORD Tests 1357 1358CREATE USER user1@localhost IDENTIFIED BY 'auth_string'; 1359CREATE USER user2@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string1'; 1360SELECT PASSWORD('plaintext_pwd'); 1361PASSWORD('plaintext_pwd') 1362*F42EC6870C44E0E26316EC1D4A953A4B9C2D8958 1363Warnings: 1364Warning 1681 'PASSWORD' is deprecated and will be removed in a future release. 1365SET PASSWORD FOR user1@localhost=PASSWORD('auth_xyz@'); 1366Warnings: 1367Warning 1287 'SET PASSWORD FOR <user> = PASSWORD('<plaintext_password>')' is deprecated and will be removed in a future release. Please use SET PASSWORD FOR <user> = '<plaintext_password>' instead 1368SET PASSWORD FOR user2@localhost=PASSWORD('gd636@gj'); 1369Warnings: 1370Warning 1287 'SET PASSWORD FOR <user> = PASSWORD('<plaintext_password>')' is deprecated and will be removed in a future release. Please use SET PASSWORD FOR <user> = '<plaintext_password>' instead 1371 1372CREATE USER user4@localhost; 1373ALTER USER user4@localhost PASSWORD EXPIRE; 1374SET PASSWORD FOR user4@localhost=''; 1375CREATE USER user3@localhost IDENTIFIED BY 'auth_string'; 1376CREATE USER user5@localhost IDENTIFIED WITH 'mysql_native_password' BY 'auth_string1'; 1377SET PASSWORD FOR user3@localhost='auth_abc'; 1378GRANT SELECT ON *.* TO user3@localhost; 1379SELECT USER(); 1380USER() 1381user3@localhost 1382SET PASSWORD='auth_xyz'; 1383SELECT user,plugin,authentication_string,ssl_type,password_expired, 1384password_lifetime FROM mysql.user WHERE user='user3'; 1385user user3 1386plugin mysql_native_password 1387authentication_string # 1388ssl_type 1389password_expired N 1390password_lifetime NULL 1391 1392SET PASSWORD FOR user4@localhost='auth_xyz'; 1393SELECT user,plugin,authentication_string,ssl_type,password_expired, 1394password_lifetime FROM mysql.user WHERE user='user4'; 1395user user4 1396plugin mysql_native_password 1397authentication_string # 1398ssl_type 1399password_expired N 1400password_lifetime NULL 1401 1402SET PASSWORD FOR user5@localhost='auth_dhsga5'; 1403SELECT user,plugin,authentication_string,ssl_type,password_expired, 1404password_lifetime FROM mysql.user WHERE user='user5'; 1405user user5 1406plugin mysql_native_password 1407authentication_string # 1408ssl_type 1409password_expired N 1410password_lifetime NULL 1411 1412CREATE USER user6@localhost IDENTIFIED BY 'auth_string'; 1413SELECT user,plugin,authentication_string,password_expired 1414FROM mysql.user WHERE USER='user6'; 1415user user6 1416plugin mysql_native_password 1417authentication_string # 1418password_expired N 1419ALTER USER user6@localhost IDENTIFIED WITH 'mysql_native_password'; 1420SELECT user,plugin,authentication_string,password_expired 1421FROM mysql.user WHERE USER='user6'; 1422user user6 1423plugin mysql_native_password 1424authentication_string # 1425password_expired Y 1426SET PASSWORD FOR user6@localhost='plaintext_password'; 1427SELECT user,plugin,authentication_string 1428FROM mysql.user WHERE USER='user6'; 1429user user6 1430plugin mysql_native_password 1431authentication_string # 1432SELECT USER(); 1433USER() 1434user6@localhost 1435 1436# Cleanup 1437DROP USER user1@localhost,user2@localhost,user3@localhost, 1438user4@localhost,user5@localhost,user6@localhost; 1439 1440# Testing log_builtin_as_identified_by_password variable scope GLOBAL Dynamic 1441SHOW GLOBAL VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1442Variable_name Value 1443log_builtin_as_identified_by_password OFF 1444 1445SET GLOBAL log_builtin_as_identified_by_password = ON; 1446SHOW GLOBAL VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1447Variable_name Value 1448log_builtin_as_identified_by_password ON 1449 1450SET GLOBAL log_builtin_as_identified_by_password = OFF; 1451SHOW GLOBAL VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1452Variable_name Value 1453log_builtin_as_identified_by_password OFF 1454 1455SET SESSION log_builtin_as_identified_by_password = ON; 1456ERROR HY000: Variable 'log_builtin_as_identified_by_password' is a GLOBAL variable and should be set with SET GLOBAL 1457SHOW VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1458Variable_name Value 1459log_builtin_as_identified_by_password OFF 1460 1461SET @@log_builtin_as_identified_by_password = OFF; 1462ERROR HY000: Variable 'log_builtin_as_identified_by_password' is a GLOBAL variable and should be set with SET GLOBAL 1463SHOW VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1464Variable_name Value 1465log_builtin_as_identified_by_password OFF 1466 1467SET @@global.log_builtin_as_identified_by_password = ON; 1468SHOW GLOBAL VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1469Variable_name Value 1470log_builtin_as_identified_by_password ON 1471 1472SET @@session.log_builtin_as_identified_by_password = ON; 1473ERROR HY000: Variable 'log_builtin_as_identified_by_password' is a GLOBAL variable and should be set with SET GLOBAL 1474# GLOBAL variable value 1475SHOW GLOBAL VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1476Variable_name Value 1477log_builtin_as_identified_by_password ON 1478SET GLOBAL log_builtin_as_identified_by_password=OFF; 1479SHOW VARIABLES LIKE 'log_builtin_as_identified_by_password'; 1480Variable_name Value 1481log_builtin_as_identified_by_password OFF 1482include/sync_slave_sql_with_master.inc 1483[On Slave] 1484include/show_binlog_events.inc 1485Log_name Pos Event_type Server_id End_log_pos Info 1486slave-bin.000001 # Query # # use `test`; CREATE USER 'user1'@'%' IDENTIFIED WITH 'mysql_native_password' 1487slave-bin.000001 # Query # # use `test`; CREATE USER 'user2'@'%' IDENTIFIED WITH 'mysql_native_password' 1488slave-bin.000001 # Query # # use `test`; CREATE USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1489slave-bin.000001 # Query # # use `test`; CREATE USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' ACCOUNT LOCK 1490slave-bin.000001 # Query # # use `test`; CREATE USER 'u3'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1491slave-bin.000001 # Query # # use `test`; CREATE USER 'u4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1492slave-bin.000001 # Query # # use `test`; CREATE USER 'user4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1493slave-bin.000001 # Query # # use `test`; CREATE USER 'user6'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1494slave-bin.000001 # Query # # use `test`; CREATE USER 'user7'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*1643D320B9787E87A3C6CE2C953B9E4FDBC048BC' PASSWORD EXPIRE NEVER ACCOUNT UNLOCK 1495slave-bin.000001 # Query # # use `test`; CREATE USER 'user8'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1496slave-bin.000001 # Query # # use `test`; CREATE USER 'tu1'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1497slave-bin.000001 # Query # # use `test`; CREATE USER 'tu2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*688BC28176C50B8E37AB2D9BDFDCC945AD0CAD61' 1498slave-bin.000001 # Query # # use `test`; CREATE USER 'tu3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*4CB92EE3F6DCB4480A1ED46B0B82E3E6180947D5' 1499slave-bin.000001 # Query # # use `test`; CREATE USER 'u5'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SSL 1500slave-bin.000001 # Query # # use `test`; CREATE USER 'u6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE X509 1501slave-bin.000001 # Query # # use `test`; CREATE USER 'tu4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*0D38B5A8766439BA457E3FDFAF84D794245A1C8B' REQUIRE SSL 1502slave-bin.000001 # Query # # use `test`; CREATE USER 'tu5'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*87CAAC9F8E0664808E450E3E9D4CCCA455FB90F0' REQUIRE X509 1503slave-bin.000001 # Query # # use `test`; CREATE USER 'u7'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE CIPHER 'cipher' 1504slave-bin.000001 # Query # # use `test`; CREATE USER 'u8'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' 1505slave-bin.000001 # Query # # use `test`; CREATE USER 'u9'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SUBJECT 'sub' 1506slave-bin.000001 # Query # # use `test`; CREATE USER 'u10'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*D0B4490FF0452CF4EAA50F79F6B06F859FA2B012' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' CIPHER 'DHE-RSA-AES256-SHA' 1507slave-bin.000001 # Query # # use `test`; CREATE USER 'tu6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*6F268C32216139F3B99FEBA90FC68F8D9651382A' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' CIPHER 'DHE-RSA-AES256-SHA' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 1508slave-bin.000001 # Query # # use `test`; CREATE USER 'u11'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_QUERIES_PER_HOUR 2 1509slave-bin.000001 # Query # # use `test`; CREATE USER 'u12'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' WITH MAX_QUERIES_PER_HOUR 2 1510slave-bin.000001 # Query # # use `test`; CREATE USER 'u13'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_CONNECTIONS_PER_HOUR 2 1511slave-bin.000001 # Query # # use `test`; CREATE USER 'u14'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' WITH MAX_USER_CONNECTIONS 2 ACCOUNT LOCK 1512slave-bin.000001 # Query # # use `test`; CREATE USER 'u15'@'localhost' IDENTIFIED WITH 'mysql_native_password','u16'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF','u17'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1513slave-bin.000001 # Query # # use `test`; CREATE USER 'u18'@'localhost' IDENTIFIED WITH 'mysql_native_password','u19'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF','u20'@'localhost' IDENTIFIED WITH 'mysql_native_password','u21'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF','u22'@'localhost' IDENTIFIED WITH 'mysql_native_password','u23'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*318C29553A414C4A571A077BC9E9A9F67D5E5634' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 ACCOUNT UNLOCK 1514slave-bin.000001 # Query # # use `test`; DROP USER tu1@localhost,tu2@localhost,tu3@localhost,tu4@localhost,tu5@localhost, 1515tu6@localhost,user1@'%',user2@'%',user4@localhost,user6@localhost, 1516user7@localhost,user8@localhost, u1@localhost,u2@localhost,u3@localhost, 1517u4@localhost,u5@localhost,u6@localhost, u7@localhost, u8@localhost, 1518u9@localhost, u10@localhost,u11@localhost, u12@localhost,u13@localhost, 1519u14@localhost,u15@localhost,u16@localhost,u17@localhost,u18@localhost, 1520u19@localhost, u20@localhost,u21@localhost,u22@localhost,u23@localhost 1521slave-bin.000001 # Query # # use `test`; CREATE USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1522slave-bin.000001 # Query # # use `test`; ALTER USER 'u1'@'localhost' 1523slave-bin.000001 # Query # # use `test`; CREATE USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*10E2B9FB284D94506F54D6DE3CD51DAC2F01CA1E' 1524slave-bin.000001 # Query # # use `test`; ALTER USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*5B3304C97AB136DEBC2C0B46336F27398F7AEFB6' 1525slave-bin.000001 # Query # # use `test`; CREATE USER 'u3'@'localhost' IDENTIFIED WITH 'mysql_native_password' ACCOUNT LOCK 1526slave-bin.000001 # Query # # use `test`; ALTER USER 'u3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' PASSWORD EXPIRE NEVER ACCOUNT UNLOCK 1527slave-bin.000001 # Query # # use `test`; ALTER USER 'u3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1528slave-bin.000001 # Query # # use `test`; ALTER USER 'u3'@'localhost' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 PASSWORD EXPIRE NEVER 1529slave-bin.000001 # Query # # use `test`; CREATE USER 'u4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' PASSWORD EXPIRE DEFAULT ACCOUNT LOCK 1530slave-bin.000001 # Query # # use `test`; ALTER USER 'u4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' ACCOUNT UNLOCK 1531slave-bin.000001 # Query # # use `test`; CREATE USER 'u5'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SSL 1532slave-bin.000001 # Query # # use `test`; ALTER USER 'u5'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1533slave-bin.000001 # Query # # use `test`; ALTER USER 'u5'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*5B3304C97AB136DEBC2C0B46336F27398F7AEFB6' 1534slave-bin.000001 # Query # # use `test`; CREATE USER 'u6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE X509 PASSWORD EXPIRE INTERVAL 80 DAY ACCOUNT LOCK 1535slave-bin.000001 # Query # # use `test`; ALTER USER 'u6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*5B3304C97AB136DEBC2C0B46336F27398F7AEFB6' REQUIRE SSL ACCOUNT UNLOCK 1536slave-bin.000001 # Query # # use `test`; CREATE USER 'u7'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE CIPHER 'DHE-RSA-AES256-SHA' 1537slave-bin.000001 # Query # # use `test`; ALTER USER 'u7'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*5B3304C97AB136DEBC2C0B46336F27398F7AEFB6' REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' ACCOUNT UNLOCK 1538slave-bin.000001 # Query # # use `test`; CREATE USER 'u8'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' 1539slave-bin.000001 # Query # # use `test`; ALTER USER 'u8'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE CIPHER 'DHE-RSA-AES256-SHA' 1540slave-bin.000001 # Query # # use `test`; CREATE USER 'tu1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE ISSUER 'issuer' 1541slave-bin.000001 # Query # # use `test`; ALTER USER 'tu1'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE CIPHER 'DHE-RSA-AES256-SHA' 1542slave-bin.000001 # Query # # use `test`; CREATE USER 'u9'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SUBJECT 'sub' 1543slave-bin.000001 # Query # # use `test`; ALTER USER 'u9'@'localhost' REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' 1544slave-bin.000001 # Query # # use `test`; ALTER USER 'u9'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*AEEAD8F349FAED7CA659DCEFCEC2F0BF90241263' REQUIRE ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' 1545slave-bin.000001 # Query # # use `test`; CREATE USER 'u10'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' CIPHER 'DHE-RSA-AES256-SHA' 1546slave-bin.000001 # Query # # use `test`; ALTER USER 'u10'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE SSL 1547slave-bin.000001 # Query # # use `test`; CREATE USER 'u11'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_QUERIES_PER_HOUR 2 1548slave-bin.000001 # Query # # use `test`; ALTER USER 'u11'@'localhost' WITH MAX_QUERIES_PER_HOUR 6 1549slave-bin.000001 # Query # # use `test`; CREATE USER 'u12'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' WITH MAX_QUERIES_PER_HOUR 2 1550slave-bin.000001 # Query # # use `test`; ALTER USER 'u12'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_QUERIES_PER_HOUR 8 1551slave-bin.000001 # Query # # use `test`; ALTER USER 'u12'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_QUERIES_PER_HOUR 1000 1552slave-bin.000001 # Query # # use `test`; CREATE USER 'u13'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_CONNECTIONS_PER_HOUR 2 1553slave-bin.000001 # Query # # use `test`; ALTER USER 'u13'@'localhost' PASSWORD EXPIRE 1554slave-bin.000001 # Query # # use `test`; CREATE USER 'u14'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' WITH MAX_USER_CONNECTIONS 2 1555slave-bin.000001 # Query # # use `test`; ALTER USER 'u14'@'localhost' WITH MAX_USER_CONNECTIONS 12 PASSWORD EXPIRE INTERVAL 365 DAY 1556slave-bin.000001 # Query # # use `test`; CREATE USER 'tu2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' WITH MAX_USER_CONNECTIONS 2 1557slave-bin.000001 # Query # # use `test`; ALTER USER 'tu2'@'localhost' WITH MAX_QUERIES_PER_HOUR 543 MAX_USER_CONNECTIONS 12 PASSWORD EXPIRE INTERVAL 365 DAY 1558slave-bin.000001 # Query # # use `test`; CREATE USER 'u15'@'localhost' IDENTIFIED WITH 'mysql_native_password','u16'@'localhost' IDENTIFIED WITH 'mysql_native_password','u17'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1559slave-bin.000001 # Query # # use `test`; ALTER USER 'u15'@'localhost' IDENTIFIED WITH 'mysql_native_password','u16'@'localhost','u17'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*5B3304C97AB136DEBC2C0B46336F27398F7AEFB6' PASSWORD EXPIRE DEFAULT 1560slave-bin.000001 # Query # # use `test`; CREATE USER 'u18'@'localhost' IDENTIFIED WITH 'mysql_native_password','u19'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF','u20'@'localhost' IDENTIFIED WITH 'mysql_native_password','u21'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*8A92C25096CC077349306CDC1CA8BE466ED357E3','u22'@'localhost' IDENTIFIED WITH 'mysql_native_password','u23'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*318C29553A414C4A571A077BC9E9A9F67D5E5634' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 1561slave-bin.000001 # Query # # use `test`; ALTER USER 'u18'@'localhost','u19'@'localhost','u20'@'localhost','u21'@'localhost','u22'@'localhost','u23'@'localhost' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 PASSWORD EXPIRE NEVER 1562slave-bin.000001 # Query # # use `test`; DROP USER tu1@localhost,tu2@localhost,u1@localhost, u2@localhost, u3@localhost, 1563u4@localhost,u5@localhost,u6@localhost, u7@localhost, u8@localhost, 1564u9@localhost,u10@localhost,u11@localhost,u12@localhost,u13@localhost, 1565u14@localhost,u15@localhost,u16@localhost,u17@localhost,u18@localhost, 1566u19@localhost,u20@localhost,u21@localhost,u22@localhost,u23@localhost 1567slave-bin.000001 # Query # # use `test`; CREATE USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*0D3CED9BEC10A777AEC23CCC353A8C08A633045E' 1568slave-bin.000001 # Query # # use `test`; ALTER USER 'u1'@'localhost' PASSWORD EXPIRE 1569slave-bin.000001 # Query # # use `test`; ALTER USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*EFA28F5E94885AA962E1AFC1912CE376EE374F65' 1570slave-bin.000001 # Query # # use `test`; ALTER USER 'u1'@'localhost' PASSWORD EXPIRE 1571slave-bin.000001 # Query # # use `test`; ALTER USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*0D3CED9BEC10A777AEC23CCC353A8C08A633045E' 1572slave-bin.000001 # Query # # use `test`; ALTER USER 'u1'@'localhost' PASSWORD EXPIRE 1573slave-bin.000001 # Query # # use `test`; ALTER USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*EFA28F5E94885AA962E1AFC1912CE376EE374F65' 1574slave-bin.000001 # Query # # use `test`; DROP USER u1@localhost 1575slave-bin.000001 # Query # # use `test`; CREATE USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password','u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*0D3CED9BEC10A777AEC23CCC353A8C08A633045E' 1576slave-bin.000001 # Query # # use `test`; GRANT ALL PRIVILEGES ON *.* TO 'u2'@'localhost' 1577slave-bin.000001 # Query # # use `test`; ALTER USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' PASSWORD EXPIRE INTERVAL 45 DAY 1578slave-bin.000001 # Query # # use `test`; DROP USER u1@localhost, u2@localhost 1579slave-bin.000001 # Query # # use `test`; CREATE USER 'u1'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1580slave-bin.000001 # Query # # use `test`; CREATE USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1581slave-bin.000001 # Query # # use `test`; DROP USER u2@localhost 1582slave-bin.000001 # Query # # use `test`; CREATE USER 'u2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE NONE 1583slave-bin.000001 # Query # # use `test`; CREATE USER 'u3'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1584slave-bin.000001 # Query # # use `test`; CREATE USER 'u4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1585slave-bin.000001 # Query # # use `test`; CREATE USER 'user1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1586slave-bin.000001 # Query # # use `test`; CREATE USER 'user2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1587slave-bin.000001 # Query # # use `test`; CREATE USER 'u5'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SSL 1588slave-bin.000001 # Query # # use `test`; CREATE USER 'u6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE X509 1589slave-bin.000001 # Query # # use `test`; CREATE USER 'u7'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE CIPHER 'cipher' 1590slave-bin.000001 # Query # # use `test`; CREATE USER 'u8'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE ISSUER 'issuer' 1591slave-bin.000001 # Query # # use `test`; CREATE USER 'u9'@'localhost' IDENTIFIED WITH 'mysql_native_password' REQUIRE SUBJECT 'sub' 1592slave-bin.000001 # Query # # use `test`; CREATE USER 'u10'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' CIPHER 'DHE-RSA-AES256-SHA' 1593slave-bin.000001 # Query # # use `test`; CREATE USER 'u11'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_QUERIES_PER_HOUR 2 1594slave-bin.000001 # Query # # use `test`; CREATE USER 'u12'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' WITH MAX_QUERIES_PER_HOUR 2 1595slave-bin.000001 # Query # # use `test`; CREATE USER 'u13'@'localhost' IDENTIFIED WITH 'mysql_native_password' WITH MAX_CONNECTIONS_PER_HOUR 2 1596slave-bin.000001 # Query # # use `test`; CREATE USER 'u14'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' WITH MAX_USER_CONNECTIONS 2 1597slave-bin.000001 # Query # # use `test`; CREATE USER 'u15'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' CIPHER 'cipher' WITH MAX_QUERIES_PER_HOUR 2 MAX_USER_CONNECTIONS 2 1598slave-bin.000001 # Query # # use `test`; DROP USER user1@localhost,u1@localhost,u2@localhost,u3@localhost,u4@localhost, 1599u5@localhost,u6@localhost, u7@localhost, u8@localhost,u9@localhost, 1600u10@localhost,u11@localhost,u12@localhost,u13@localhost,u14@localhost, 1601u15@localhost 1602slave-bin.000001 # Query # # use `test`; CREATE USER 'user1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' WITH MAX_QUERIES_PER_HOUR 60 MAX_UPDATES_PER_HOUR 100 MAX_CONNECTIONS_PER_HOUR 1000 MAX_USER_CONNECTIONS 20 1603slave-bin.000001 # Query # # use `test`; GRANT SELECT ON *.* TO 'user1'@'localhost' 1604slave-bin.000001 # Query # # use `test`; GRANT SELECT, INSERT, UPDATE ON `mysql`.* TO 'user1'@'localhost' 1605slave-bin.000001 # Query # # use `test`; REVOKE INSERT,UPDATE ON mysql.* FROM user1@localhost 1606slave-bin.000001 # Query # # use `test`; GRANT SELECT, INSERT, UPDATE ON *.* TO 'user2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*4ACFE3202A5FF5CF467898FC58AAB1D615029441' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' WITH MAX_QUERIES_PER_HOUR 60 MAX_UPDATES_PER_HOUR 100 MAX_CONNECTIONS_PER_HOUR 1000 MAX_USER_CONNECTIONS 20 1607slave-bin.000001 # Query # # use `test`; CREATE USER 'user3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1608slave-bin.000001 # Query # # use `test`; GRANT SELECT ON `mysql`.* TO 'user3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' REQUIRE SUBJECT '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=Client' ISSUER '/C=SE/ST=Stockholm/L=Stockholm/O=Oracle/OU=MySQL/CN=CA' WITH MAX_QUERIES_PER_HOUR 60 MAX_UPDATES_PER_HOUR 100 MAX_CONNECTIONS_PER_HOUR 1000 MAX_USER_CONNECTIONS 20 1609slave-bin.000001 # Query # # use `test`; DROP USER user1@localhost,user2@localhost,user3@localhost 1610slave-bin.000001 # Query # # use `test`; CREATE USER 'user1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1611slave-bin.000001 # Query # # use `test`; CREATE USER 'user2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*BB2A6C4B68EBE1B781C294D655785971401FB13B' 1612slave-bin.000001 # Query # # use `test`; ALTER USER 'user1'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*5BC789A788B4F867BF1B8DB2A6A20ACDF5B32C49' 1613slave-bin.000001 # Query # # use `test`; ALTER USER 'user2'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*F03819CC796CCA4052B8928179B81D18288B05A8' 1614slave-bin.000001 # Query # # use `test`; CREATE USER 'user4'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1615slave-bin.000001 # Query # # use `test`; ALTER USER 'user4'@'localhost' PASSWORD EXPIRE 1616slave-bin.000001 # Query # # use `test`; ALTER USER 'user4'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1617slave-bin.000001 # Query # # use `test`; CREATE USER 'user3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1618slave-bin.000001 # Query # # use `test`; CREATE USER 'user5'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*BB2A6C4B68EBE1B781C294D655785971401FB13B' 1619slave-bin.000001 # Query # # use `test`; ALTER USER 'user3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*9EAD043037BDC069CBBF0A05A1702BF0217BC238' 1620slave-bin.000001 # Query # # use `test`; GRANT SELECT ON *.* TO 'user3'@'localhost' 1621slave-bin.000001 # Query # # use `test`; ALTER USER 'user3'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*FFC91FB317629FBAC23400346B54066C4C3389A6' 1622slave-bin.000001 # Query # # use `test`; ALTER USER 'user4'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*FFC91FB317629FBAC23400346B54066C4C3389A6' 1623slave-bin.000001 # Query # # use `test`; ALTER USER 'user5'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*960F0A06F105B0FE8089E3F6FAD5369E8A28E241' 1624slave-bin.000001 # Query # # use `test`; CREATE USER 'user6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*67092806AE91BFB6BE72DE6C7BE2B7CCA8CFA9DF' 1625slave-bin.000001 # Query # # use `test`; ALTER USER 'user6'@'localhost' IDENTIFIED WITH 'mysql_native_password' 1626slave-bin.000001 # Query # # use `test`; ALTER USER 'user6'@'localhost' IDENTIFIED WITH 'mysql_native_password' AS '*9CAB2BAE176801E82ABA9E55CCCDDBF388E0301D' 1627slave-bin.000001 # Query # # use `test`; DROP USER user1@localhost,user2@localhost,user3@localhost, 1628user4@localhost,user5@localhost,user6@localhost 1629include/rpl_end.inc 1630 1631End of 5.7 tests! 1632 1633