From 00b4f4d543512c0da9b80917988c9d1abab5515a Mon Sep 17 00:00:00 2001 From: sysadmin75 Date: Thu, 25 Dec 2014 17:36:51 -0500 Subject: [PATCH] Fix to revoke privileges for mysql user = '' Issue #9848 --- database/mysql/mysql_user.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/database/mysql/mysql_user.py b/database/mysql/mysql_user.py index e160fcb68f6..f4b620c0e9a 100644 --- a/database/mysql/mysql_user.py +++ b/database/mysql/mysql_user.py @@ -254,7 +254,7 @@ def privileges_get(cursor, user,host): return x for grant in grants: - res = re.match("GRANT (.+) ON (.+) TO '.+'@'.+'( IDENTIFIED BY PASSWORD '.+')? ?(.*)", grant[0]) + res = re.match("GRANT (.+) ON (.+) TO '.*'@'.+'( IDENTIFIED BY PASSWORD '.+')? ?(.*)", grant[0]) if res is None: raise InvalidPrivsError('unable to parse the MySQL grant string: %s' % grant[0]) privileges = res.group(1).split(", ")