mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
MDEV-7015: SET STATEMENT old_passwords has no effect
Decision about algorihtm moved on prepare phase. Made possible to add mpore password algorithms.
This commit is contained in:
@ -1070,8 +1070,6 @@ set statement character_set_filesystem=default for select 1;
|
||||
ERROR 42000: The system variable character_set_filesystem cannot be set in SET STATEMENT.
|
||||
set statement collation_connection=default for select 1;
|
||||
ERROR 42000: The system variable collation_connection cannot be set in SET STATEMENT.
|
||||
set statement old_passwords=default for select 1;
|
||||
ERROR 42000: The system variable old_passwords cannot be set in SET STATEMENT.
|
||||
set statement query_cache_type=default for select 1;
|
||||
ERROR 42000: The system variable query_cache_type cannot be set in SET STATEMENT.
|
||||
set statement wait_timeout=default for select 1;
|
||||
@ -1105,3 +1103,38 @@ week(a)
|
||||
deallocate prepare stmt1;
|
||||
drop table t1;
|
||||
set @@default_week_format=@save_week_format;
|
||||
set @save_old_passwords=@@old_passwords;
|
||||
set @@old_passwords=0;
|
||||
set statement OLD_PASSWORDS = 0 for select password('test');
|
||||
password('test')
|
||||
*94BDCEBE19083CE2A1F959FD02F964C7AF4CFC29
|
||||
set statement OLD_PASSWORDS = 1 for select password('test');
|
||||
password('test')
|
||||
378b243e220ca493
|
||||
set statement OLD_PASSWORDS = 0 for explain extended select password('test');
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
Warnings:
|
||||
Note 1003 select password('test') AS `password('test')`
|
||||
set statement OLD_PASSWORDS = 1 for explain extended select password('test');
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used
|
||||
Warnings:
|
||||
Note 1003 select password('test') AS `password('test')`
|
||||
create table t1 (a char(10));
|
||||
insert t1 values ('qwertyuiop');
|
||||
prepare stmt1 from "select password(a) from t1";
|
||||
execute stmt1;
|
||||
password(a)
|
||||
*6063C78456BB048BAF36BE1104D12D547834DFEA
|
||||
set old_passwords=1;
|
||||
execute stmt1;
|
||||
password(a)
|
||||
2013610f6aac2950
|
||||
alter table t1 engine=myisam;
|
||||
execute stmt1;
|
||||
password(a)
|
||||
2013610f6aac2950
|
||||
deallocate prepare stmt1;
|
||||
drop table t1;
|
||||
set @@old_passwords=@save_old_passwords;
|
||||
|
Reference in New Issue
Block a user