[ Avaa Bypassed ]




Upload:

Command:

hmhc3928@3.144.96.170: ~ $
# Tests for PERFORMANCE_SCHEMA

--disable_warnings
drop table if exists test.t1;
--enable_warnings

## The result of show grants is not consistent across platforms ...
## show grants;

## Not enforced yet: deny CREATE_ACL and DROP_ACL
## Waiting to remove .FRM files first
##
## --error ER_DBACCESS_DENIED_ERROR
## create table performance_schema.t1(a int);
##
## --error ER_DBACCESS_DENIED_ERROR
## drop table performance_schema.t1;
##
## --error ER_DBACCESS_DENIED_ERROR
## create table performance_schema.setup_instruments(a int);
##
## --error ER_DBACCESS_DENIED_ERROR
## create table performance_schema.events_waits_current(a int);
##
## --error ER_DBACCESS_DENIED_ERROR
## create table performance_schema.file_instances(a int);
##
## --error ER_DBACCESS_DENIED_ERROR
## drop table performance_schema.setup_instruments;
##
## --error ER_DBACCESS_DENIED_ERROR
## drop table performance_schema.events_waits_current;
##
## --error ER_DBACCESS_DENIED_ERROR
## drop table performance_schema.file_instances;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.setup_instruments to test.t1;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.events_waits_current to test.t1;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.file_instances to test.t1;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.setup_instruments to performance_schema.t1;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.events_waits_current to performance_schema.t1;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.file_instances to performance_schema.t1;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.setup_instruments
  to performance_schema.events_waits_current;

--error ER_DBACCESS_DENIED_ERROR
rename table performance_schema.events_waits_current
  to performance_schema.setup_instruments;

--error ER_DBACCESS_DENIED_ERROR
create procedure performance_schema.my_proc() begin end;

--error ER_DBACCESS_DENIED_ERROR
create function performance_schema.my_func() returns int return 0;

--error ER_DBACCESS_DENIED_ERROR
create event performance_schema.my_event on schedule every 15 minute
do begin end;

--error ER_DBACCESS_DENIED_ERROR
create trigger performance_schema.bi_setup_instruments
  before insert on performance_schema.setup_instruments
  for each row begin end;

--error ER_DBACCESS_DENIED_ERROR
create trigger performance_schema.bi_events_waits_current
  before insert on performance_schema.events_waits_current
  for each row begin end;

--error ER_DBACCESS_DENIED_ERROR
create trigger performance_schema.bi_file_instances
  before insert on performance_schema.file_instances
  for each row begin end;

--error ER_WRONG_PERFSCHEMA_USAGE
create table test.t1(a int) engine=PERFORMANCE_SCHEMA;

--error ER_WRONG_PERFSCHEMA_USAGE
create table test.t1 like performance_schema.setup_instruments;

--error ER_WRONG_PERFSCHEMA_USAGE
create table test.t1 like performance_schema.events_waits_current;

--error ER_WRONG_PERFSCHEMA_USAGE
create table test.t1 like performance_schema.file_instances;

--error ER_TABLEACCESS_DENIED_ERROR
insert into performance_schema.setup_instruments
  set name="foo";

--error ER_TABLEACCESS_DENIED_ERROR
insert into performance_schema.events_waits_current
  set name="foo";

--error ER_TABLEACCESS_DENIED_ERROR
insert into performance_schema.file_instances
  set name="foo";

--error ER_TABLEACCESS_DENIED_ERROR
delete from performance_schema.setup_instruments;

--error ER_TABLEACCESS_DENIED_ERROR
delete from performance_schema.events_waits_current;

--error ER_TABLEACCESS_DENIED_ERROR
delete from performance_schema.file_instances;

lock table performance_schema.setup_instruments read;
unlock tables;

lock table performance_schema.setup_instruments write;
unlock tables;

--error ER_TABLEACCESS_DENIED_ERROR
lock table performance_schema.events_waits_current read;
unlock tables;

--error ER_TABLEACCESS_DENIED_ERROR
lock table performance_schema.events_waits_current write;
unlock tables;

--error ER_TABLEACCESS_DENIED_ERROR
lock table performance_schema.file_instances read;
unlock tables;

--error ER_TABLEACCESS_DENIED_ERROR
lock table performance_schema.file_instances write;
unlock tables;

--echo #
--echo # WL#4818, NFS2: Can use grants to give normal user access
--echo #                to view data from _current and _history tables
--echo #
--echo # Should work as pfs_user_1 and pfs_user_2, but not as pfs_user_3.
--echo # (Except for events_waits_current, which is granted.)

# Errors here will be caught by the diff afterwards
--disable_abort_on_error

SELECT "can select" FROM performance_schema.events_waits_history LIMIT 1;

SELECT "can select" FROM performance_schema.events_waits_history_long LIMIT 1;

SELECT "can select" FROM performance_schema.events_waits_current LIMIT 1;

SELECT "can select" FROM performance_schema.events_waits_summary_by_instance LIMIT 1;

SELECT "can select" FROM performance_schema.file_summary_by_instance LIMIT 1;

--enable_abort_on_error


Filemanager

Name Type Size Permission Actions
binlog_edge_common.inc File 5.46 KB 0644
binlog_ok_common.inc File 3.9 KB 0644
cleanup_helper.inc File 356 B 0644
connection_cleanup.inc File 794 B 0644
connection_load.inc File 6.1 KB 0644
connection_setup.inc File 3.01 KB 0644
digest_cleanup.inc File 387 B 0644
digest_execution.inc File 3.96 KB 0644
digest_setup.inc File 618 B 0644
disable_instruments.inc File 548 B 0644
enable_instruments.inc File 549 B 0644
event_aggregate_cleanup.inc File 1.62 KB 0644
event_aggregate_load.inc File 24.49 KB 0644
event_aggregate_setup.inc File 13.05 KB 0644
have_aligned_memory.inc File 548 B 0644
hostcache_dump.inc File 1.13 KB 0644
hostcache_set_state.inc File 651 B 0644
privilege.inc File 4.91 KB 0644
rpl_statements_truncate.inc File 683 B 0644
schema.inc File 2.54 KB 0644
setup_helper.inc File 1.1 KB 0644
sizing_auto.inc File 958 B 0644
socket_check1.inc File 4.63 KB 0644
socket_event.inc File 6.94 KB 0644
socket_event_dbg.inc File 2.95 KB 0644
socket_ipv6.inc File 2.98 KB 0644
socket_summary_check.inc File 8.18 KB 0644
socket_summary_check_dbg.inc File 8.37 KB 0644
stage_cleanup.inc File 915 B 0644
stage_setup.inc File 3.86 KB 0644
start_server_common.inc File 4.29 KB 0644
table_aggregate_cleanup.inc File 1.52 KB 0644
table_aggregate_load.inc File 13.96 KB 0644
table_aggregate_setup.inc File 8.82 KB 0644
table_io_basic_dml.inc File 1.1 KB 0644
table_io_cleanup_helper.inc File 336 B 0644
table_io_result_helper.inc File 702 B 0644
table_io_setup_helper.inc File 1.76 KB 0644
upgrade_check.inc File 435 B 0644
wait_for_pfs_thread_count.inc File 710 B 0644
wait_till_sleep.inc File 590 B 0644