|
454 | 454 | 1
|
455 | 455 | 2
|
456 | 456 | set autocommit = default;
|
| 457 | +set global default_authentication_plugin = 'invalid_auth_plugin'; |
| 458 | +Error 1231 (42000): Variable 'default_authentication_plugin' can't be set to the value of 'invalid_auth_plugin' |
| 459 | +set global default_authentication_plugin = 'auth_socket'; |
| 460 | +Error 1231 (42000): Variable 'default_authentication_plugin' can't be set to the value of 'auth_socket' |
| 461 | +set global default_authentication_plugin = 'tidb_sm3_password'; |
| 462 | +create user default_sm3_user; |
| 463 | +show create user default_sm3_user; |
| 464 | +CREATE USER for default_sm3_user@% |
| 465 | +CREATE USER 'default_sm3_user'@'%' IDENTIFIED WITH 'tidb_sm3_password' AS '' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK PASSWORD HISTORY DEFAULT PASSWORD REUSE INTERVAL DEFAULT |
| 466 | +select plugin from mysql.user where user = 'default_sm3_user'; |
| 467 | +plugin |
| 468 | +tidb_sm3_password |
| 469 | +set global default_authentication_plugin = 'caching_sha2_password'; |
| 470 | +create user default_sha2_user; |
| 471 | +create user native_plugin_user identified with 'mysql_native_password'; |
| 472 | +create role default_sha2_role; |
| 473 | +show create user default_sha2_user; |
| 474 | +CREATE USER for default_sha2_user@% |
| 475 | +CREATE USER 'default_sha2_user'@'%' IDENTIFIED WITH 'caching_sha2_password' AS '' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK PASSWORD HISTORY DEFAULT PASSWORD REUSE INTERVAL DEFAULT |
| 476 | +select plugin from mysql.user where user = 'default_sha2_user'; |
| 477 | +plugin |
| 478 | +caching_sha2_password |
| 479 | +show create user native_plugin_user; |
| 480 | +CREATE USER for native_plugin_user@% |
| 481 | +CREATE USER 'native_plugin_user'@'%' IDENTIFIED WITH 'mysql_native_password' AS '' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK PASSWORD HISTORY DEFAULT PASSWORD REUSE INTERVAL DEFAULT |
| 482 | +select plugin from mysql.user where user = 'native_plugin_user'; |
| 483 | +plugin |
| 484 | +mysql_native_password |
| 485 | +show create user default_sha2_role; |
| 486 | +CREATE USER for default_sha2_role@% |
| 487 | +CREATE USER 'default_sha2_role'@'%' IDENTIFIED WITH 'caching_sha2_password' AS '' REQUIRE NONE PASSWORD EXPIRE ACCOUNT LOCK PASSWORD HISTORY DEFAULT PASSWORD REUSE INTERVAL DEFAULT |
| 488 | +select plugin from mysql.user where user = 'default_sha2_role'; |
| 489 | +plugin |
| 490 | +caching_sha2_password |
| 491 | +alter user default_sha2_user identified with 'tidb_sm3_password'; |
| 492 | +show create user default_sha2_user; |
| 493 | +CREATE USER for default_sha2_user@% |
| 494 | +CREATE USER 'default_sha2_user'@'%' IDENTIFIED WITH 'tidb_sm3_password' AS '' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK PASSWORD HISTORY DEFAULT PASSWORD REUSE INTERVAL DEFAULT |
| 495 | +select plugin from mysql.user where user = 'default_sha2_user'; |
| 496 | +plugin |
| 497 | +tidb_sm3_password |
| 498 | +alter user default_sha2_user identified with 'authentication_ldap_simple'; |
| 499 | +show create user default_sha2_user; |
| 500 | +CREATE USER for default_sha2_user@% |
| 501 | +CREATE USER 'default_sha2_user'@'%' IDENTIFIED WITH 'authentication_ldap_simple' AS '' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK PASSWORD HISTORY DEFAULT PASSWORD REUSE INTERVAL DEFAULT |
| 502 | +select plugin from mysql.user where user = 'default_sha2_user'; |
| 503 | +plugin |
| 504 | +authentication_ldap_simple |
| 505 | +alter user default_sha2_user identified with 'authentication_ldap_sasl'; |
| 506 | +show create user default_sha2_user; |
| 507 | +CREATE USER for default_sha2_user@% |
| 508 | +CREATE USER 'default_sha2_user'@'%' IDENTIFIED WITH 'authentication_ldap_sasl' AS '' REQUIRE NONE PASSWORD EXPIRE DEFAULT ACCOUNT UNLOCK PASSWORD HISTORY DEFAULT PASSWORD REUSE INTERVAL DEFAULT |
| 509 | +select plugin from mysql.user where user = 'default_sha2_user'; |
| 510 | +plugin |
| 511 | +authentication_ldap_sasl |
| 512 | +drop user default_sm3_user; |
| 513 | +drop user default_sha2_user; |
| 514 | +drop user native_plugin_user; |
| 515 | +drop user default_sha2_role; |
| 516 | +set global default_authentication_plugin = default; |
0 commit comments