From 633cc34ca7349e2f77dec460db081bf8ba469e87 Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 7 Mar 2008 20:18:14 +0100 Subject: Post merge fixes after ChangeSet@1.2561, 2008-03-07 17:44:03+01:00, mleich@five.local.lan +132 -0 Merge five.local.lan:/work/merge/mysql-5.0-funcs_1 into five.local.lan:/work/merge/mysql-5.1-funcs_1 MERGE: 1.1810.3473.24 ChangeSet@1.1810.3473.24, 2008-03-07 WL#4203 Reorganize and fix the data dictionary tests of testsuite funcs_1 1. Adjustment of expected results to modified server properties 2. Add some tests of information_schema views 3. Minor corrections and improvements BitKeeper/deleted/.del-ndb__datadict.result: Delete: mysql-test/suite/funcs_1/r/ndb__datadict.result BitKeeper/deleted/.del-ndb__datadict.test: Delete: mysql-test/suite/funcs_1/t/ndb__datadict.test BitKeeper/deleted/.del-ndb__load.test: Delete: mysql-test/suite/funcs_1/t/ndb__load.test BitKeeper/deleted/.del-ndb__load.result: Delete: mysql-test/suite/funcs_1/r/ndb__load.result mysql-test/suite/funcs_1/r/memory_storedproc_07.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/memory_storedproc_02.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/memory_storedproc_03.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/memory_storedproc_08.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/memory_storedproc_10.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/innodb_storedproc_02.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/innodb_storedproc_03.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/innodb_storedproc_07.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/innodb_storedproc_08.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/innodb_storedproc_10.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/myisam_storedproc_02.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/myisam_storedproc_03.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/myisam_storedproc_07.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/myisam_storedproc_08.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/r/myisam_storedproc_10.result: Change mode to -rw-rw-r-- mysql-test/suite/funcs_1/datadict/processlist_priv.inc: Make the results independend of amount of preceding tests. mysql-test/suite/funcs_1/datadict/processlist_val.inc: Correct the cleanup mysql-test/suite/funcs_1/r/charset_collation_1.result: Updated results mysql-test/suite/funcs_1/r/charset_collation_2.result: Updated results mysql-test/suite/funcs_1/r/innodb_func_view.result: Updated results mysql-test/suite/funcs_1/r/innodb_storedproc.result: Updated results mysql-test/suite/funcs_1/r/is_basics_mixed.result: Updated results mysql-test/suite/funcs_1/r/is_character_sets.result: Updated results mysql-test/suite/funcs_1/r/is_collation_character_set_applicability.result: Updated results mysql-test/suite/funcs_1/r/is_collations.result: Updated results mysql-test/suite/funcs_1/r/is_column_privileges.result: Updated results mysql-test/suite/funcs_1/r/is_columns.result: Updated results mysql-test/suite/funcs_1/r/is_columns_innodb.result: Updated results mysql-test/suite/funcs_1/r/is_columns_is.result: Updated results mysql-test/suite/funcs_1/r/is_columns_memory.result: Updated results mysql-test/suite/funcs_1/r/is_columns_myisam.result: Updated results mysql-test/suite/funcs_1/r/is_columns_mysql.result: Updated results mysql-test/suite/funcs_1/r/is_key_column_usage.result: Updated results mysql-test/suite/funcs_1/r/is_routines.result: Updated results mysql-test/suite/funcs_1/r/is_schema_privileges.result: Updated results mysql-test/suite/funcs_1/r/is_schema_privileges_is_mysql_test.result: Updated results mysql-test/suite/funcs_1/r/is_schemata.result: Updated results mysql-test/suite/funcs_1/r/is_statistics.result: Updated results mysql-test/suite/funcs_1/r/is_statistics_mysql.result: Updated results mysql-test/suite/funcs_1/r/is_table_constraints.result: Updated results mysql-test/suite/funcs_1/r/is_table_constraints_mysql.result: Updated results mysql-test/suite/funcs_1/r/is_table_privileges.result: Updated results mysql-test/suite/funcs_1/r/is_tables.result: Updated results mysql-test/suite/funcs_1/r/is_tables_is.result: Updated results mysql-test/suite/funcs_1/r/is_tables_mysql.result: Updated results mysql-test/suite/funcs_1/r/is_tables_ndb.result: Updated results mysql-test/suite/funcs_1/r/is_triggers.result: Updated results mysql-test/suite/funcs_1/r/is_user_privileges.result: Updated results mysql-test/suite/funcs_1/r/is_views.result: Updated results mysql-test/suite/funcs_1/r/memory_func_view.result: Updated results mysql-test/suite/funcs_1/r/memory_storedproc.result: Updated results mysql-test/suite/funcs_1/r/myisam_func_view.result: Updated results mysql-test/suite/funcs_1/r/myisam_storedproc.result: Updated results mysql-test/suite/funcs_1/r/myisam_views.result: Updated results mysql-test/suite/funcs_1/r/ndb_func_view.result: Updated results mysql-test/suite/funcs_1/r/ndb_storedproc.result: Updated results mysql-test/suite/funcs_1/r/ndb_storedproc_02.result: Updated results mysql-test/suite/funcs_1/r/ndb_storedproc_03.result: Updated results mysql-test/suite/funcs_1/r/ndb_storedproc_07.result: Updated results mysql-test/suite/funcs_1/r/ndb_storedproc_08.result: Updated results mysql-test/suite/funcs_1/r/ndb_storedproc_10.result: Updated results mysql-test/suite/funcs_1/r/processlist_priv_no_prot.result: Updated results mysql-test/suite/funcs_1/r/processlist_priv_ps.result: Updated results mysql-test/suite/funcs_1/r/processlist_val_no_prot.result: Updated results mysql-test/suite/funcs_1/r/processlist_val_ps.result: Updated results mysql-test/suite/funcs_1/storedproc/storedproc_master.inc: Set subtest checking a no more reserved keyword to comment. mysql-test/suite/funcs_1/t/disabled.def: ndb__datadict is dropped. The checks are done in other scripts. mysql-test/suite/funcs_1/t/is_routines.test: Correction of comment mysql-test/suite/funcs_1/t/is_triggers.test: Adjustment to changes in privilege system between MySQL 5.0 and 5.1. mysql-test/suite/funcs_1/t/is_views.test: Correction of comment. mysql-test/suite/funcs_1/t/processlist_priv_no_prot.test: Correction of comment. mysql-test/suite/funcs_1/t/processlist_priv_ps.test: Correction of comment. mysql-test/suite/funcs_1/t/processlist_val_no_prot.test: Correction of comment. mysql-test/suite/funcs_1/t/processlist_val_ps.test: Correction of comment. mysql-test/suite/funcs_1/r/is_engines.result: Expected results mysql-test/suite/funcs_1/r/is_engines_archive.result: Expected results mysql-test/suite/funcs_1/r/is_engines_blackhole.result: Expected results mysql-test/suite/funcs_1/r/is_engines_csv.result: Expected results mysql-test/suite/funcs_1/r/is_engines_federated.result: Expected results mysql-test/suite/funcs_1/r/is_engines_innodb.result: Expected results mysql-test/suite/funcs_1/r/is_engines_memory.result: Expected results mysql-test/suite/funcs_1/r/is_engines_merge.result: Expected results mysql-test/suite/funcs_1/r/is_engines_myisam.result: Expected results mysql-test/suite/funcs_1/t/is_engines.test: Test of information_schema.engines mysql-test/suite/funcs_1/t/is_engines_archive.test: Test of information_schema.engines Variant for ARCHIVE mysql-test/suite/funcs_1/t/is_engines_blackhole.test: Test of information_schema.engines Variant for BLACKHOLE mysql-test/suite/funcs_1/t/is_engines_csv.test: Test of information_schema.engines Variant for CSV mysql-test/suite/funcs_1/t/is_engines_federated.test: Test of information_schema.engines Variant for FEDERATED mysql-test/suite/funcs_1/t/is_engines_innodb.test: Test of information_schema.engines Variant for InnoDB mysql-test/suite/funcs_1/t/is_engines_memory.test: Test of information_schema.engines Variant for MEMORY mysql-test/suite/funcs_1/t/is_engines_merge.test: Test of information_schema.engines Variant for MERGGE mysql-test/suite/funcs_1/t/is_engines_myisam.test: Test of information_schema.engines Variant for MyISAM mysql-test/suite/funcs_1/t/is_engines_ndb.test: Test of information_schema.engines Variant for NDB mysql-test/suite/funcs_1/t/is_events.test: Test for information_schema.events mysql-test/suite/funcs_1/r/is_engines_ndb.result: Expected results mysql-test/suite/funcs_1/r/is_events.result: Expected results --- .../suite/funcs_1/datadict/processlist_priv.inc | 56 +- .../suite/funcs_1/datadict/processlist_val.inc | 1 + .../funcs_1/r/a_processlist_priv_no_prot.result | 475 - .../funcs_1/r/a_processlist_val_no_prot.result | 154 - .../suite/funcs_1/r/b_processlist_priv_ps.result | 475 - .../suite/funcs_1/r/b_processlist_val_ps.result | 154 - .../suite/funcs_1/r/charset_collation_1.result | 3 + .../suite/funcs_1/r/charset_collation_2.result | 3 + mysql-test/suite/funcs_1/r/innodb_func_view.result | 106 +- .../suite/funcs_1/r/innodb_storedproc.result | 9 - .../suite/funcs_1/r/innodb_storedproc_02.result | 0 .../suite/funcs_1/r/innodb_storedproc_03.result | 0 .../suite/funcs_1/r/innodb_storedproc_07.result | 0 .../suite/funcs_1/r/innodb_storedproc_08.result | 0 .../suite/funcs_1/r/innodb_storedproc_10.result | 0 mysql-test/suite/funcs_1/r/is_basics_mixed.result | 2 +- .../suite/funcs_1/r/is_character_sets.result | 8 +- ...is_collation_character_set_applicability.result | 4 +- mysql-test/suite/funcs_1/r/is_collations.result | 12 +- .../suite/funcs_1/r/is_column_privileges.result | 16 +- mysql-test/suite/funcs_1/r/is_columns.result | 58 +- .../suite/funcs_1/r/is_columns_innodb.result | 2 +- mysql-test/suite/funcs_1/r/is_columns_is.result | 336 +- .../suite/funcs_1/r/is_columns_memory.result | 2 +- .../suite/funcs_1/r/is_columns_myisam.result | 2 +- mysql-test/suite/funcs_1/r/is_columns_mysql.result | 174 +- mysql-test/suite/funcs_1/r/is_engines.result | 84 + .../suite/funcs_1/r/is_engines_archive.result | 8 + .../suite/funcs_1/r/is_engines_blackhole.result | 8 + mysql-test/suite/funcs_1/r/is_engines_csv.result | 8 + .../suite/funcs_1/r/is_engines_federated.result | 8 + .../suite/funcs_1/r/is_engines_innodb.result | 8 + .../suite/funcs_1/r/is_engines_memory.result | 8 + mysql-test/suite/funcs_1/r/is_engines_merge.result | 8 + .../suite/funcs_1/r/is_engines_myisam.result | 8 + mysql-test/suite/funcs_1/r/is_engines_ndb.result | 8 + mysql-test/suite/funcs_1/r/is_events.result | 148 + .../suite/funcs_1/r/is_key_column_usage.result | 24 +- mysql-test/suite/funcs_1/r/is_routines.result | 84 +- .../suite/funcs_1/r/is_schema_privileges.result | 10 +- .../r/is_schema_privileges_is_mysql_test.result | 2 + mysql-test/suite/funcs_1/r/is_schemata.result | 10 +- mysql-test/suite/funcs_1/r/is_statistics.result | 30 +- .../suite/funcs_1/r/is_statistics_mysql.result | 5 + .../suite/funcs_1/r/is_table_constraints.result | 12 +- .../funcs_1/r/is_table_constraints_mysql.result | 4 + .../suite/funcs_1/r/is_table_privileges.result | 16 +- mysql-test/suite/funcs_1/r/is_tables.result | 78 +- mysql-test/suite/funcs_1/r/is_tables_is.result | 570 +- mysql-test/suite/funcs_1/r/is_tables_mysql.result | 138 + mysql-test/suite/funcs_1/r/is_tables_ndb.result | 23 - mysql-test/suite/funcs_1/r/is_triggers.result | 100 +- .../suite/funcs_1/r/is_user_privileges.result | 96 +- mysql-test/suite/funcs_1/r/is_views.result | 46 +- mysql-test/suite/funcs_1/r/memory_func_view.result | 106 +- .../suite/funcs_1/r/memory_storedproc.result | 9 - .../suite/funcs_1/r/memory_storedproc_02.result | 0 .../suite/funcs_1/r/memory_storedproc_03.result | 0 .../suite/funcs_1/r/memory_storedproc_07.result | 0 .../suite/funcs_1/r/memory_storedproc_08.result | 0 .../suite/funcs_1/r/memory_storedproc_10.result | 0 mysql-test/suite/funcs_1/r/myisam_func_view.result | 106 +- .../suite/funcs_1/r/myisam_storedproc.result | 9 - .../suite/funcs_1/r/myisam_storedproc_02.result | 0 .../suite/funcs_1/r/myisam_storedproc_03.result | 0 .../suite/funcs_1/r/myisam_storedproc_07.result | 0 .../suite/funcs_1/r/myisam_storedproc_08.result | 0 .../suite/funcs_1/r/myisam_storedproc_10.result | 0 mysql-test/suite/funcs_1/r/myisam_views.result | 4 +- mysql-test/suite/funcs_1/r/ndb__datadict.result | 14787 ------------------- mysql-test/suite/funcs_1/r/ndb__load.result | 1 - mysql-test/suite/funcs_1/r/ndb_func_view.result | 106 +- mysql-test/suite/funcs_1/r/ndb_storedproc.result | 9 - .../suite/funcs_1/r/ndb_storedproc_02.result | 2 - .../suite/funcs_1/r/ndb_storedproc_03.result | 2 - .../suite/funcs_1/r/ndb_storedproc_07.result | 2 - .../suite/funcs_1/r/ndb_storedproc_08.result | 2 - .../suite/funcs_1/r/ndb_storedproc_10.result | 2 - .../funcs_1/r/processlist_priv_no_prot.result | 475 + .../suite/funcs_1/r/processlist_priv_ps.result | 475 + .../suite/funcs_1/r/processlist_val_no_prot.result | 155 + .../suite/funcs_1/r/processlist_val_ps.result | 155 + .../suite/funcs_1/storedproc/storedproc_master.inc | 14 +- .../funcs_1/t/a_processlist_priv_no_prot.test | 36 - .../suite/funcs_1/t/a_processlist_val_no_prot.test | 31 - .../suite/funcs_1/t/b_processlist_priv_ps.test | 35 - .../suite/funcs_1/t/b_processlist_val_ps.test | 30 - mysql-test/suite/funcs_1/t/disabled.def | 1 - mysql-test/suite/funcs_1/t/is_engines.test | 126 + mysql-test/suite/funcs_1/t/is_engines_archive.test | 15 + .../suite/funcs_1/t/is_engines_blackhole.test | 15 + mysql-test/suite/funcs_1/t/is_engines_csv.test | 15 + .../suite/funcs_1/t/is_engines_federated.test | 15 + mysql-test/suite/funcs_1/t/is_engines_innodb.test | 15 + mysql-test/suite/funcs_1/t/is_engines_memory.test | 14 + mysql-test/suite/funcs_1/t/is_engines_merge.test | 14 + mysql-test/suite/funcs_1/t/is_engines_myisam.test | 14 + mysql-test/suite/funcs_1/t/is_engines_ndb.test | 15 + mysql-test/suite/funcs_1/t/is_events.test | 169 + mysql-test/suite/funcs_1/t/is_routines.test | 4 + mysql-test/suite/funcs_1/t/is_triggers.test | 18 +- mysql-test/suite/funcs_1/t/is_views.test | 3 + mysql-test/suite/funcs_1/t/ndb__datadict.test | 11 - mysql-test/suite/funcs_1/t/ndb__load.test | 43 - .../suite/funcs_1/t/processlist_priv_no_prot.test | 30 + .../suite/funcs_1/t/processlist_priv_ps.test | 29 + .../suite/funcs_1/t/processlist_val_no_prot.test | 25 + mysql-test/suite/funcs_1/t/processlist_val_ps.test | 24 + 108 files changed, 3856 insertions(+), 16916 deletions(-) delete mode 100644 mysql-test/suite/funcs_1/r/a_processlist_priv_no_prot.result delete mode 100644 mysql-test/suite/funcs_1/r/a_processlist_val_no_prot.result delete mode 100644 mysql-test/suite/funcs_1/r/b_processlist_priv_ps.result delete mode 100644 mysql-test/suite/funcs_1/r/b_processlist_val_ps.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/innodb_storedproc_02.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/innodb_storedproc_03.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/innodb_storedproc_07.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/innodb_storedproc_08.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/innodb_storedproc_10.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_archive.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_blackhole.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_csv.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_federated.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_innodb.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_memory.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_merge.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_myisam.result create mode 100644 mysql-test/suite/funcs_1/r/is_engines_ndb.result create mode 100644 mysql-test/suite/funcs_1/r/is_events.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/memory_storedproc_02.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/memory_storedproc_03.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/memory_storedproc_07.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/memory_storedproc_08.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/memory_storedproc_10.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/myisam_storedproc_02.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/myisam_storedproc_03.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/myisam_storedproc_07.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/myisam_storedproc_08.result mode change 100755 => 100644 mysql-test/suite/funcs_1/r/myisam_storedproc_10.result delete mode 100644 mysql-test/suite/funcs_1/r/ndb__datadict.result delete mode 100644 mysql-test/suite/funcs_1/r/ndb__load.result create mode 100644 mysql-test/suite/funcs_1/r/processlist_priv_no_prot.result create mode 100644 mysql-test/suite/funcs_1/r/processlist_priv_ps.result create mode 100644 mysql-test/suite/funcs_1/r/processlist_val_no_prot.result create mode 100644 mysql-test/suite/funcs_1/r/processlist_val_ps.result delete mode 100644 mysql-test/suite/funcs_1/t/a_processlist_priv_no_prot.test delete mode 100644 mysql-test/suite/funcs_1/t/a_processlist_val_no_prot.test delete mode 100644 mysql-test/suite/funcs_1/t/b_processlist_priv_ps.test delete mode 100644 mysql-test/suite/funcs_1/t/b_processlist_val_ps.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_archive.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_blackhole.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_csv.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_federated.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_innodb.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_memory.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_merge.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_myisam.test create mode 100644 mysql-test/suite/funcs_1/t/is_engines_ndb.test create mode 100644 mysql-test/suite/funcs_1/t/is_events.test delete mode 100644 mysql-test/suite/funcs_1/t/ndb__datadict.test delete mode 100644 mysql-test/suite/funcs_1/t/ndb__load.test create mode 100644 mysql-test/suite/funcs_1/t/processlist_priv_no_prot.test create mode 100644 mysql-test/suite/funcs_1/t/processlist_priv_ps.test create mode 100644 mysql-test/suite/funcs_1/t/processlist_val_no_prot.test create mode 100644 mysql-test/suite/funcs_1/t/processlist_val_ps.test (limited to 'mysql-test') diff --git a/mysql-test/suite/funcs_1/datadict/processlist_priv.inc b/mysql-test/suite/funcs_1/datadict/processlist_priv.inc index 337ddf5df60..24df7ef8948 100644 --- a/mysql-test/suite/funcs_1/datadict/processlist_priv.inc +++ b/mysql-test/suite/funcs_1/datadict/processlist_priv.inc @@ -112,11 +112,11 @@ connect (con100,localhost,ddicttestuser1,ddictpass,information_schema); --echo #################################################################################### connection default; eval SHOW CREATE TABLE $table; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME eval SHOW $table; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME eval SELECT * FROM $table $select_where ORDER BY id; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME eval SELECT $columns FROM $table $select_where ORDER BY id; --source suite/funcs_1/datadict/datadict_priv.inc --real_sleep 0.3 @@ -128,11 +128,11 @@ connection con100; --echo SHOW/SELECT shows only the processes (1) of the user. --echo #################################################################################### eval SHOW CREATE TABLE $table; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME eval SHOW $table; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME eval SELECT * FROM $table $select_where ORDER BY id; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME eval SELECT $columns FROM $table $select_where ORDER BY id; --source suite/funcs_1/datadict/datadict_priv.inc --real_sleep 0.3 @@ -154,9 +154,9 @@ GRANT PROCESS ON *.* TO ddicttestuser1@'localhost' IDENTIFIED BY 'ddictpass'; --echo #################################################################################### connection con100; SHOW GRANTS; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -166,9 +166,9 @@ SELECT * FROM information_schema.processlist; --echo #################################################################################### connect (con101,localhost,ddicttestuser1,ddictpass,information_schema); SHOW GRANTS; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -188,9 +188,9 @@ GRANT PROCESS ON *.* TO ''@'localhost'; --echo #################################################################################### connect (anonymous1,localhost,'',,information_schema); SHOW GRANTS; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -210,9 +210,9 @@ connect (con102,localhost,ddicttestuser1,ddictpass,information_schema); --echo ddicttestuser1 are visible. --echo #################################################################################### SHOW GRANTS; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -235,10 +235,10 @@ SHOW GRANTS FOR ''@'localhost'; if ($fixed_bug_30395) { # Bug#30395 strange results after REVOKE PROCESS ON *.* FROM ... ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; } ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -257,9 +257,9 @@ connect (con103,localhost,ddicttestuser1,ddictpass,information_schema); --echo Only the processes of ddicttestuser1 user are visible. --echo #################################################################################### SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -279,9 +279,9 @@ connect (con104,localhost,ddicttestuser1,ddictpass,information_schema); --echo Only the processes of ddicttestuser1 are visible. --echo #################################################################################### SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -326,9 +326,9 @@ connect (con200,localhost,ddicttestuser2,ddictpass,information_schema); --echo ddicttestuser2 has now the PROCESS privilege and sees all connections --echo #################################################################################### SHOW GRANTS FOR 'ddicttestuser2'@'localhost'; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -347,9 +347,9 @@ connect (con201,localhost,ddicttestuser2,ddictpass,information_schema); --echo ddicttestuser2 has no more the PROCESS privilege and can only see own connects --echo #################################################################################### SHOW GRANTS; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -370,9 +370,9 @@ connect (con107,localhost,ddicttestuser1,ddictpass,information_schema); SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; --error ER_ACCESS_DENIED_ERROR GRANT PROCESS ON *.* TO 'ddicttestuser2'@'localhost'; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 @@ -394,9 +394,9 @@ connect (con108,localhost,ddicttestuser1,ddictpass,information_schema); --echo Therefore the missing SELECT privilege does not affect SELECTs on PROCESSLIST. --echo #################################################################################### SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SHOW processlist; ---replace_column 6 TIME +--replace_column 1 ID 6 TIME SELECT * FROM information_schema.processlist; --real_sleep 0.3 diff --git a/mysql-test/suite/funcs_1/datadict/processlist_val.inc b/mysql-test/suite/funcs_1/datadict/processlist_val.inc index f383cf20405..69a32553f65 100644 --- a/mysql-test/suite/funcs_1/datadict/processlist_val.inc +++ b/mysql-test/suite/funcs_1/datadict/processlist_val.inc @@ -306,3 +306,4 @@ connection default; --echo ----- close connection ddicttestuser1 ----- disconnect ddicttestuser1; DROP USER ddicttestuser1@'localhost'; +DROP TABLE test.t1; diff --git a/mysql-test/suite/funcs_1/r/a_processlist_priv_no_prot.result b/mysql-test/suite/funcs_1/r/a_processlist_priv_no_prot.result deleted file mode 100644 index 8ed815ab667..00000000000 --- a/mysql-test/suite/funcs_1/r/a_processlist_priv_no_prot.result +++ /dev/null @@ -1,475 +0,0 @@ -USE information_schema; -#################################################################################### -1 Prepare test. -connection default (user=root) -#################################################################################### -#################################################################################### -1.1 Create two user -#################################################################################### -DROP USER ddicttestuser1@'localhost'; -ERROR HY000: Operation DROP USER failed for 'ddicttestuser1'@'localhost' -DROP USER ddicttestuser2@'localhost'; -ERROR HY000: Operation DROP USER failed for 'ddicttestuser2'@'localhost' -CREATE USER ddicttestuser1@'localhost'; -CREATE USER ddicttestuser2@'localhost'; -SET PASSWORD FOR ddicttestuser1@'localhost' = PASSWORD('ddictpass'); -SET PASSWORD FOR ddicttestuser2@'localhost' = PASSWORD('ddictpass'); -#################################################################################### -1.2 Establish connection con100 (user=ddicttestuser1 with no PROCESS privilege): -#################################################################################### -#################################################################################### -2 connection default(user=root with default privileges): -SHOW/SELECT shows all processes/threads. -#################################################################################### -SHOW CREATE TABLE processlist; -Table Create Table -PROCESSLIST CREATE TEMPORARY TABLE `PROCESSLIST` ( - `ID` bigint(4) NOT NULL DEFAULT '0', - `USER` varchar(16) NOT NULL DEFAULT '', - `HOST` varchar(64) NOT NULL DEFAULT '', - `DB` varchar(64) DEFAULT NULL, - `COMMAND` varchar(16) NOT NULL DEFAULT '', - `TIME` bigint(7) NOT NULL DEFAULT '0', - `STATE` varchar(64) DEFAULT NULL, - `INFO` longtext -) ENGINE=MyISAM DEFAULT CHARSET=utf8 -SHOW processlist; -Id User Host db Command Time State Info -1 root localhost information_schema Query TIME NULL SHOW processlist -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -SELECT * FROM processlist ORDER BY id; -ID USER HOST DB COMMAND TIME STATE INFO -1 root localhost information_schema Query TIME executing SELECT * FROM processlist ORDER BY id -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -SELECT ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO FROM processlist ORDER BY id; -ID USER HOST DB COMMAND TIME STATE INFO -1 root localhost information_schema Query TIME executing SELECT ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO FROM processlist ORDER BY id -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -CREATE TEMPORARY TABLE test.t_processlist AS SELECT * FROM processlist; -UPDATE test.t_processlist SET user='horst' WHERE id=1 ; -INSERT INTO processlist SELECT * FROM test.t_processlist; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -DROP TABLE test.t_processlist; -CREATE VIEW test.v_processlist (ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO) AS SELECT * FROM processlist WITH CHECK OPTION; -ERROR HY000: CHECK OPTION on non-updatable view 'test.v_processlist' -CREATE VIEW test.v_processlist (ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO) AS SELECT * FROM processlist; -UPDATE test.v_processlist SET TIME=NOW() WHERE id = 1; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -DROP VIEW test.v_processlist; -UPDATE processlist SET user='any_user' WHERE id=1 ; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -DELETE FROM processlist WHERE id=1 ; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -REVOKE ALL ON processlist FROM current_user; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -GRANT INSERT,UPDATE ON processlist TO current_user; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -SHOW GRANTS; -Grants for root@localhost -GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' WITH GRANT OPTION -CREATE INDEX i_processlist ON processlist (user); -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -DROP TABLE processlist; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -ALTER TABLE processlist DROP COLUMN user; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -ALTER TABLE processlist ADD COLUMN (my_column INT); -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -RENAME TABLE processlist TO new_processlist; -ERROR 42S02: Unknown table 'new_processlist' in information_schema -RENAME TABLE processlist TO files; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -CREATE TABLE new_processlist AS SELECT * FROM processlist; -ERROR 42S02: Unknown table 'new_processlist' in information_schema -DROP DATABASE information_schema; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -RENAME DATABASE information_schema TO info_schema; -ERROR 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 'DATABASE information_schema TO info_schema' at line 1 -ALTER DATABASE information_schema UPGRADE DATA DIRECTORY NAME; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -#################################################################################### -3 Switch to connection con100 (user=ddicttestuser1 with no PROCESS privilege): -SHOW/SELECT shows only the processes (1) of the user. -#################################################################################### -SHOW CREATE TABLE processlist; -Table Create Table -PROCESSLIST CREATE TEMPORARY TABLE `PROCESSLIST` ( - `ID` bigint(4) NOT NULL DEFAULT '0', - `USER` varchar(16) NOT NULL DEFAULT '', - `HOST` varchar(64) NOT NULL DEFAULT '', - `DB` varchar(64) DEFAULT NULL, - `COMMAND` varchar(16) NOT NULL DEFAULT '', - `TIME` bigint(7) NOT NULL DEFAULT '0', - `STATE` varchar(64) DEFAULT NULL, - `INFO` longtext -) ENGINE=MyISAM DEFAULT CHARSET=utf8 -SHOW processlist; -Id User Host db Command Time State Info -2 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM processlist ORDER BY id; -ID USER HOST DB COMMAND TIME STATE INFO -2 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM processlist ORDER BY id -SELECT ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO FROM processlist ORDER BY id; -ID USER HOST DB COMMAND TIME STATE INFO -2 ddicttestuser1 localhost information_schema Query TIME executing SELECT ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO FROM processlist ORDER BY id -CREATE TEMPORARY TABLE test.t_processlist AS SELECT * FROM processlist; -UPDATE test.t_processlist SET user='horst' WHERE id=1 ; -INSERT INTO processlist SELECT * FROM test.t_processlist; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -DROP TABLE test.t_processlist; -CREATE VIEW test.v_processlist (ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO) AS SELECT * FROM processlist WITH CHECK OPTION; -ERROR HY000: CHECK OPTION on non-updatable view 'test.v_processlist' -CREATE VIEW test.v_processlist (ID, USER, HOST, DB, COMMAND, TIME, STATE, INFO) AS SELECT * FROM processlist; -UPDATE test.v_processlist SET TIME=NOW() WHERE id = 1; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -DROP VIEW test.v_processlist; -UPDATE processlist SET user='any_user' WHERE id=1 ; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -DELETE FROM processlist WHERE id=1 ; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -REVOKE ALL ON processlist FROM current_user; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -GRANT INSERT,UPDATE ON processlist TO current_user; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -SHOW GRANTS; -Grants for ddicttestuser1@localhost -GRANT USAGE ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -CREATE INDEX i_processlist ON processlist (user); -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -DROP TABLE processlist; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -ALTER TABLE processlist DROP COLUMN user; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -ALTER TABLE processlist ADD COLUMN (my_column INT); -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -RENAME TABLE processlist TO new_processlist; -ERROR 42S02: Unknown table 'new_processlist' in information_schema -RENAME TABLE processlist TO files; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -CREATE TABLE new_processlist AS SELECT * FROM processlist; -ERROR 42S02: Unknown table 'new_processlist' in information_schema -DROP DATABASE information_schema; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -RENAME DATABASE information_schema TO info_schema; -ERROR 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 'DATABASE information_schema TO info_schema' at line 1 -ALTER DATABASE information_schema UPGRADE DATA DIRECTORY NAME; -ERROR 42000: Access denied for user 'ddicttestuser1'@'localhost' to database 'information_schema' -#################################################################################### -4 Grant PROCESS privilege to ddicttestuser1 -connection default (user=root) -#################################################################################### -GRANT PROCESS ON *.* TO ddicttestuser1@'localhost' IDENTIFIED BY 'ddictpass'; -#################################################################################### -4.1 Existing connection con100 (ddicttestuser1) -The user ddicttestuser1 has the PROCESS privilege, but the connection was -established before PROCESS was granted. -SHOW/SELECT shows only the processes (1) of the user. -#################################################################################### -SHOW GRANTS; -Grants for ddicttestuser1@localhost -GRANT PROCESS ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -2 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -2 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -#################################################################################### -4.2 New connection con101 (ddicttestuser1 with PROCESS privilege) -SHOW/SELECT shows all processes/threads. -#################################################################################### -SHOW GRANTS; -Grants for ddicttestuser1@localhost -GRANT PROCESS ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -1 root localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -3 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -1 root localhost information_schema Sleep TIME NULL -#################################################################################### -5 Grant PROCESS privilege to anonymous user. -connection default (user=root) -#################################################################################### -GRANT PROCESS ON *.* TO ''@'localhost'; -#################################################################################### -5.1 Establish connection (anonymous1,localhost,'',,information_schema) -anonymous user with PROCESS privilege -SHOW/SELECT shows all processes/threads. -#################################################################################### -SHOW GRANTS; -Grants for @localhost -GRANT PROCESS ON *.* TO ''@'localhost' -SHOW processlist; -Id User Host db Command Time State Info -1 root localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -4 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -4 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -1 root localhost information_schema Sleep TIME NULL -#################################################################################### -6 Revoke PROCESS privilege from ddicttestuser1 -connection default (user=root) -#################################################################################### -REVOKE PROCESS ON *.* FROM ddicttestuser1@'localhost' IDENTIFIED BY 'ddictpass'; -#################################################################################### -6.1 New connection con102 (ddicttestuser1 has no more PROCESS privilege) -Again (compared to state before GRANT PROCESS) only the processes of -ddicttestuser1 are visible. -#################################################################################### -SHOW GRANTS; -Grants for ddicttestuser1@localhost -GRANT USAGE ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -5 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -#################################################################################### -7 Revoke PROCESS privilege from anonymous user + disconnect ddicttestuser1 -connection default (user=root) -#################################################################################### -REVOKE PROCESS ON *.* FROM ''@'localhost'; -#################################################################################### -7.1 New connection (anonymous2,localhost,'',,information_schema) -The anonymous user has no more the PROCESS privilege -Again only the processes of the anonymous user are visible. -#################################################################################### -SHOW GRANTS FOR ''@'localhost'; -Grants for @localhost -GRANT USAGE ON *.* TO ''@'localhost' -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -6 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -4 localhost information_schema Sleep TIME NULL -#################################################################################### -8 Grant SUPER (does not imply PROCESS) privilege to ddicttestuser1 -connection default (user=root) -#################################################################################### -GRANT SUPER ON *.* TO 'ddicttestuser1'@'localhost'; -#################################################################################### -8.1 New connection con103 (ddicttestuser1 with SUPER privilege) -Only the processes of ddicttestuser1 user are visible. -#################################################################################### -SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; -Grants for ddicttestuser1@localhost -GRANT SUPER ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -7 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -#################################################################################### -9 Revoke SUPER privilege from user ddicttestuser1 -connection default (user=root) -#################################################################################### -REVOKE SUPER ON *.* FROM 'ddicttestuser1'@'localhost'; -#################################################################################### -9.1 New connection con104 (ddicttestuser1 without SUPER privilege) -ddicttestuser1 has no more the SUPER privilege. -Only the processes of ddicttestuser1 are visible. -#################################################################################### -SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; -Grants for ddicttestuser1@localhost -GRANT USAGE ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -8 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -8 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -#################################################################################### -10 Grant SUPER privilege with grant option to user ddicttestuser1. -connection default (user=root) -#################################################################################### -GRANT SUPER ON *.* TO 'ddicttestuser1'@'localhost' WITH GRANT OPTION; -#################################################################################### -10.1 New connection con105 (ddicttestuser1 with SUPER privilege and GRANT OPTION) -Try to grant PROCESS privilege to user ddicttestuser2 without having it. -#################################################################################### -SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; -Grants for ddicttestuser1@localhost -GRANT SUPER ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' WITH GRANT OPTION -GRANT PROCESS ON *.* TO 'ddicttestuser2'@'localhost'; -ERROR 28000: Access denied for user 'ddicttestuser1'@'localhost' (using password: YES) -#################################################################################### -10.2 Grant SUPER and PROCESS privilege with grant option to user ddicttestuser1 -connection default (user=root) -#################################################################################### -GRANT SUPER,PROCESS ON *.* TO 'ddicttestuser1'@'localhost' WITH GRANT OPTION; -#################################################################################### -10.3 New connection con106 (ddicttestuser1 with SUPER,PROCESS WITH GRANT OPTION) -Grant PROCESS privilege to user ddicttestuser2 -#################################################################################### -SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; -Grants for ddicttestuser1@localhost -GRANT PROCESS, SUPER ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' WITH GRANT OPTION -GRANT PROCESS ON *.* TO 'ddicttestuser2'@'localhost'; -#################################################################################### -10.4 New connection con200 (ddicttestuser2 with PROCESS privilege) -ddicttestuser2 has now the PROCESS privilege and sees all connections -#################################################################################### -SHOW GRANTS FOR 'ddicttestuser2'@'localhost'; -Grants for ddicttestuser2@localhost -GRANT PROCESS ON *.* TO 'ddicttestuser2'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -1 root localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -4 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -6 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -8 ddicttestuser1 localhost information_schema Sleep TIME NULL -9 ddicttestuser1 localhost information_schema Sleep TIME NULL -10 ddicttestuser1 localhost information_schema Sleep TIME NULL -11 ddicttestuser2 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -11 ddicttestuser2 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -10 ddicttestuser1 localhost information_schema Sleep TIME NULL -9 ddicttestuser1 localhost information_schema Sleep TIME NULL -8 ddicttestuser1 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -6 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -4 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -1 root localhost information_schema Sleep TIME NULL -#################################################################################### -11 User ddicttestuser1 revokes PROCESS privilege from user ddicttestuser2 -connection ddicttestuser1; -#################################################################################### -REVOKE PROCESS ON *.* FROM 'ddicttestuser2'@'localhost'; -#################################################################################### -11.1 New connection con201 (ddicttestuser2) -ddicttestuser2 has no more the PROCESS privilege and can only see own connects -#################################################################################### -SHOW GRANTS; -Grants for ddicttestuser2@localhost -GRANT USAGE ON *.* TO 'ddicttestuser2'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -11 ddicttestuser2 localhost information_schema Sleep TIME NULL -12 ddicttestuser2 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -12 ddicttestuser2 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -11 ddicttestuser2 localhost information_schema Sleep TIME NULL -#################################################################################### -11.2 Revoke SUPER,PROCESS,GRANT OPTION privilege from user ddicttestuser1 -connection default (user=root) -#################################################################################### -REVOKE SUPER,PROCESS,GRANT OPTION ON *.* FROM 'ddicttestuser1'@'localhost'; -#################################################################################### -11.3 New connection con107 (ddicttestuser1) -ddicttestuser1 has no more the PROCESS privilege and can only see own connects -He is also unable to GRANT the PROCESS privilege to ddicttestuser2 -#################################################################################### -SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; -Grants for ddicttestuser1@localhost -GRANT USAGE ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -GRANT PROCESS ON *.* TO 'ddicttestuser2'@'localhost'; -ERROR 28000: Access denied for user 'ddicttestuser1'@'localhost' (using password: YES) -SHOW processlist; -Id User Host db Command Time State Info -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -8 ddicttestuser1 localhost information_schema Sleep TIME NULL -9 ddicttestuser1 localhost information_schema Sleep TIME NULL -10 ddicttestuser1 localhost information_schema Sleep TIME NULL -13 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -13 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -10 ddicttestuser1 localhost information_schema Sleep TIME NULL -9 ddicttestuser1 localhost information_schema Sleep TIME NULL -8 ddicttestuser1 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -#################################################################################### -12 Revoke the SELECT privilege from user ddicttestuser1 -connection default (user=root) -#################################################################################### -REVOKE SELECT ON *.* FROM 'ddicttestuser1'@'localhost'; -#################################################################################### -12.1 New connection con108 (ddicttestuser1) -ddicttestuser1 has neither PROCESS nor SELECT privilege -Manual says: Each MySQL user has the right to access these tables, but can see -only the rows ... -Therefore the missing SELECT privilege does not affect SELECTs on PROCESSLIST. -#################################################################################### -SHOW GRANTS FOR 'ddicttestuser1'@'localhost'; -Grants for ddicttestuser1@localhost -GRANT USAGE ON *.* TO 'ddicttestuser1'@'localhost' IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' -SHOW processlist; -Id User Host db Command Time State Info -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -8 ddicttestuser1 localhost information_schema Sleep TIME NULL -9 ddicttestuser1 localhost information_schema Sleep TIME NULL -10 ddicttestuser1 localhost information_schema Sleep TIME NULL -13 ddicttestuser1 localhost information_schema Sleep TIME NULL -14 ddicttestuser1 localhost information_schema Query TIME NULL SHOW processlist -SELECT * FROM information_schema.processlist; -ID USER HOST DB COMMAND TIME STATE INFO -14 ddicttestuser1 localhost information_schema Query TIME executing SELECT * FROM information_schema.processlist -13 ddicttestuser1 localhost information_schema Sleep TIME NULL -10 ddicttestuser1 localhost information_schema Sleep TIME NULL -9 ddicttestuser1 localhost information_schema Sleep TIME NULL -8 ddicttestuser1 localhost information_schema Sleep TIME NULL -7 ddicttestuser1 localhost information_schema Sleep TIME NULL -5 ddicttestuser1 localhost information_schema Sleep TIME NULL -3 ddicttestuser1 localhost information_schema Sleep TIME NULL -2 ddicttestuser1 localhost information_schema Sleep TIME NULL -#################################################################################### -12.2 Revoke only the SELECT privilege on the information_schema from ddicttestuser1. -connection default (user=root) -#################################################################################### -REVOKE SELECT ON information_schema.* FROM 'ddicttestuser3'@'localhost'; -ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema' -#################################################################################### -connection default (user=root) -Cleanup: close connections, DROP USER etc. -#################################################################################### -DROP USER ddicttestuser1@'localhost'; -DROP USER ddicttestuser2@'localhost'; -REVOKE USAGE ON *.* FROM ''@'localhost'; -DROP USER ''@'localhost'; diff --git a/mysql-test/suite/funcs_1/r/a_processlist_val_no_prot.result b/mysql-test/suite/funcs_1/r/a_processlist_val_no_prot.result deleted file mode 100644 index 86054aacd20..00000000000 --- a/mysql-test/suite/funcs_1/r/a_processlist_val_no_prot.result +++ /dev/null @@ -1,154 +0,0 @@ -DROP USER ddicttestuser1@'localhost'; -ERROR HY000: Operation DROP USER failed for 'ddicttestuser1'@'localhost' -CREATE USER ddicttestuser1@'localhost'; -GRANT ALL ON *.* TO ddicttestuser1@'localhost'; -REVOKE PROCESS ON *.* FROM ddicttestuser1@'localhost'; -SET PASSWORD FOR ddicttestuser1@'localhost' = PASSWORD('ddictpass'); -DROP TABLE IF EXISTS test.t1; -CREATE TABLE test.t1 (f1 BIGINT); -SHOW CREATE TABLE INFORMATION_SCHEMA.PROCESSLIST; -Table Create Table -PROCESSLIST CREATE TEMPORARY TABLE `PROCESSLIST` ( - `ID` bigint(4) NOT NULL DEFAULT '0', - `USER` varchar(16) NOT NULL DEFAULT '', - `HOST` varchar(64) NOT NULL DEFAULT '', - `DB` varchar(64) DEFAULT NULL, - `COMMAND` varchar(16) NOT NULL DEFAULT '', - `TIME` bigint(7) NOT NULL DEFAULT '0', - `STATE` varchar(64) DEFAULT NULL, - `INFO` longtext -) ENGINE=MyISAM DEFAULT CHARSET=utf8 -SELECT COUNT(*) FROM INFORMATION_SCHEMA.PROCESSLIST; -COUNT(*) -1 -USE test; -SELECT * FROM INFORMATION_SCHEMA.PROCESSLIST; -ID USER HOST DB COMMAND TIME STATE INFO - root localhost test Query 0 executing SELECT * FROM INFORMATION_SCHEMA.PROCESSLIST -SHOW FULL PROCESSLIST; -Id User Host db Command Time State Info - root localhost test Query 0 NULL SHOW FULL PROCESSLIST -USE information_schema; -SELECT * FROM INFORMATION_SCHEMA.PROCESSLIST; -ID USER HOST DB COMMAND TIME STATE INFO - root localhost information_schema Query