diff options
author | Vladislav Vaintroub <wlad@mariadb.com> | 2016-02-01 17:51:57 +0100 |
---|---|---|
committer | Vladislav Vaintroub <wlad@mariadb.com> | 2016-02-01 17:51:57 +0100 |
commit | 52d695fef4f959daf12cc1e4b83907917dddfbe8 (patch) | |
tree | 645052e28d43f360e67d0a1bf1fef270fda2a2da | |
parent | e6dee57f1ae78326af9485170d232436fb49404f (diff) | |
download | mariadb-git-52d695fef4f959daf12cc1e4b83907917dddfbe8.tar.gz |
Fix authentication plugin's tests in case username contains non-alphanumeric character, e.g dash
-rw-r--r-- | mysql-test/r/auth_named_pipe.result | 4 | ||||
-rw-r--r-- | mysql-test/t/auth_named_pipe.test | 4 | ||||
-rw-r--r-- | plugin/auth_gssapi/mysql-test/auth_gssapi/basic.result | 4 | ||||
-rw-r--r-- | plugin/auth_gssapi/mysql-test/auth_gssapi/basic.test | 4 |
4 files changed, 8 insertions, 8 deletions
diff --git a/mysql-test/r/auth_named_pipe.result b/mysql-test/r/auth_named_pipe.result index 8de507e1744..3268b760a22 100644 --- a/mysql-test/r/auth_named_pipe.result +++ b/mysql-test/r/auth_named_pipe.result @@ -1,9 +1,9 @@ INSTALL SONAME 'auth_named_pipe'; -CREATE USER USERNAME IDENTIFIED WITH named_pipe; +CREATE USER 'USERNAME' IDENTIFIED WITH named_pipe; SELECT USER(),CURRENT_USER(); USER() CURRENT_USER() USERNAME@localhost USERNAME@% -DROP USER USERNAME; +DROP USER 'USERNAME'; CREATE USER nosuchuser IDENTIFIED WITH named_pipe; ERROR 28000: Access denied for user 'nosuchuser'@'localhost' DROP USER nosuchuser; diff --git a/mysql-test/t/auth_named_pipe.test b/mysql-test/t/auth_named_pipe.test index 5473d628246..00577fbef05 100644 --- a/mysql-test/t/auth_named_pipe.test +++ b/mysql-test/t/auth_named_pipe.test @@ -3,7 +3,7 @@ INSTALL SONAME 'auth_named_pipe'; --replace_result $USERNAME USERNAME -eval CREATE USER $USERNAME IDENTIFIED WITH named_pipe; +eval CREATE USER '$USERNAME' IDENTIFIED WITH named_pipe; # Connect using named pipe, correct username connect(pipe_con,localhost,$USERNAME,,,,,PIPE); --replace_result $USERNAME USERNAME @@ -11,7 +11,7 @@ SELECT USER(),CURRENT_USER(); disconnect pipe_con; connection default; --replace_result $USERNAME USERNAME -eval DROP USER $USERNAME; +eval DROP USER '$USERNAME'; # test invalid user name CREATE USER nosuchuser IDENTIFIED WITH named_pipe; diff --git a/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.result b/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.result index a859ce563c7..dc5155fac8c 100644 --- a/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.result +++ b/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.result @@ -1,9 +1,9 @@ INSTALL SONAME 'auth_gssapi'; -CREATE USER GSSAPI_SHORTNAME IDENTIFIED WITH gssapi; +CREATE USER 'GSSAPI_SHORTNAME' IDENTIFIED WITH gssapi; SELECT USER(),CURRENT_USER(); USER() CURRENT_USER() GSSAPI_SHORTNAME@localhost GSSAPI_SHORTNAME@% -DROP USER GSSAPI_SHORTNAME; +DROP USER 'GSSAPI_SHORTNAME'; CREATE USER nosuchuser IDENTIFIED WITH gssapi; ERROR 28000: GSSAPI name mismatch, requested 'nosuchuser', actual name 'GSSAPI_SHORTNAME' DROP USER nosuchuser; diff --git a/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.test b/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.test index cb49c2e145b..f47ad8c20e2 100644 --- a/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.test +++ b/plugin/auth_gssapi/mysql-test/auth_gssapi/basic.test @@ -4,7 +4,7 @@ INSTALL SONAME 'auth_gssapi'; # CREATE USER without 'AS' clause # --replace_result $GSSAPI_SHORTNAME GSSAPI_SHORTNAME -eval CREATE USER $GSSAPI_SHORTNAME IDENTIFIED WITH gssapi; +eval CREATE USER '$GSSAPI_SHORTNAME' IDENTIFIED WITH gssapi; connect (con1,localhost,$GSSAPI_SHORTNAME,,); --replace_result $GSSAPI_SHORTNAME GSSAPI_SHORTNAME SELECT USER(),CURRENT_USER(); @@ -12,7 +12,7 @@ disconnect con1; connection default; --replace_result $GSSAPI_SHORTNAME GSSAPI_SHORTNAME -eval DROP USER $GSSAPI_SHORTNAME; +eval DROP USER '$GSSAPI_SHORTNAME'; CREATE USER nosuchuser IDENTIFIED WITH gssapi; --disable_query_log |