MXS-2502 Fix access denied when connecting to 'information_schema'

This commit is contained in:
Marko
2019-06-25 14:40:17 +03:00
parent be8f4fe055
commit edbbafc2e9
3 changed files with 7 additions and 5 deletions

View File

@ -63,7 +63,7 @@ const char create_sql[] =
/** The query that is executed when a user is authenticated */
static const char gssapi_auth_query[] =
"SELECT * FROM " GSSAPI_TABLE_NAME
" WHERE user = '%s' AND '%s' LIKE host AND (anydb = '1' OR '%s' = '' OR '%s' LIKE db)"
" WHERE user = '%s' AND '%s' LIKE host AND (anydb = '1' OR '%s' IN ('information_schema', '') OR '%s' LIKE db)"
" AND ('%s' = '%s' OR princ = '%s') LIMIT 1";
/** Delete query used to clean up the database before loading new users */