summaryrefslogtreecommitdiff
path: root/mysql-test/suite/roles
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2014-11-24 15:10:51 +0100
committerSergei Golubchik <serg@mariadb.org>2014-12-04 10:41:54 +0100
commitbc603c604daaf8c4e7b31c9ad1b4724f9ab3f450 (patch)
tree4a7c6c66343042c09d3e71a5cdb46177ae95eff3 /mysql-test/suite/roles
parent61820bca9b4a4caa30127b17bca93d2bf37217ff (diff)
downloadmariadb-git-bc603c604daaf8c4e7b31c9ad1b4724f9ab3f450.tar.gz
bugfix: IDENTIFIED BY clause was lost in some GRANT variants
Diffstat (limited to 'mysql-test/suite/roles')
-rw-r--r--mysql-test/suite/roles/grant_revoke_current.result15
-rw-r--r--mysql-test/suite/roles/grant_revoke_current.test7
2 files changed, 21 insertions, 1 deletions
diff --git a/mysql-test/suite/roles/grant_revoke_current.result b/mysql-test/suite/roles/grant_revoke_current.result
index 644454685b4..d9798463965 100644
--- a/mysql-test/suite/roles/grant_revoke_current.result
+++ b/mysql-test/suite/roles/grant_revoke_current.result
@@ -24,4 +24,19 @@ revoke all, grant option from current_role;
show grants for current_role;
Grants for r1
GRANT USAGE ON *.* TO 'r1'
+set password=password('foobar');
+show grants;
+Grants for root@localhost
+GRANT r1 TO 'root'@'localhost' WITH ADMIN OPTION
+GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' IDENTIFIED BY PASSWORD '*9B500343BC52E2911172EB52AE5CF4847604C6E5' WITH GRANT OPTION
+GRANT PROXY ON ''@'%' TO 'root'@'localhost' WITH GRANT OPTION
+GRANT USAGE ON *.* TO 'r1'
+grant r1 to current_user() identified by 'barfoo';
+show grants;
+Grants for root@localhost
+GRANT r1 TO 'root'@'localhost' WITH ADMIN OPTION
+GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' IDENTIFIED BY PASSWORD '*343915A8181B5728EADBDC73E1F7E6B0C3998483' WITH GRANT OPTION
+GRANT PROXY ON ''@'%' TO 'root'@'localhost' WITH GRANT OPTION
+GRANT USAGE ON *.* TO 'r1'
+set password='';
drop role r1;
diff --git a/mysql-test/suite/roles/grant_revoke_current.test b/mysql-test/suite/roles/grant_revoke_current.test
index 96a27fd5697..0ebe0170782 100644
--- a/mysql-test/suite/roles/grant_revoke_current.test
+++ b/mysql-test/suite/roles/grant_revoke_current.test
@@ -20,5 +20,10 @@ show grants for current_role;
revoke all, grant option from current_role;
show grants for current_role;
-drop role r1;
+set password=password('foobar');
+show grants;
+grant r1 to current_user() identified by 'barfoo';
+show grants;
+set password='';
+drop role r1;