From a1550765aaecdd4ac0c9ad5b078624bf538184e7 Mon Sep 17 00:00:00 2001 From: midoks Date: Sat, 31 Dec 2022 14:52:39 +0800 Subject: [PATCH] up --- plugins/mariadb/index.py | 2 +- plugins/mysql-apt/index.py | 2 +- plugins/mysql-yum/index.py | 2 +- plugins/mysql/index.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/mariadb/index.py b/plugins/mariadb/index.py index 8245cf93b..2bfb93894 100755 --- a/plugins/mariadb/index.py +++ b/plugins/mariadb/index.py @@ -1792,7 +1792,7 @@ def addMasterRepSlaveUser(version=''): # address = args['address'].strip() # dataAccess = args['dataAccess'].strip() - reg = "^[\w\.-]+$" + reg = "^[\w-]+$" if not re.match(reg, username): return mw.returnJson(False, '用户名不能带有特殊符号!') checks = ['root', 'mysql', 'test', 'sys', 'panel_logs'] diff --git a/plugins/mysql-apt/index.py b/plugins/mysql-apt/index.py index a0c6c674b..7ab236ade 100755 --- a/plugins/mysql-apt/index.py +++ b/plugins/mysql-apt/index.py @@ -1779,7 +1779,7 @@ def addMasterRepSlaveUser(version=''): # address = args['address'].strip() # dataAccess = args['dataAccess'].strip() - reg = "^[\w\.-]+$" + reg = "^[\w-]+$" if not re.match(reg, username): return mw.returnJson(False, '用户名不能带有特殊符号!') checks = ['root', 'mysql', 'test', 'sys', 'panel_logs'] diff --git a/plugins/mysql-yum/index.py b/plugins/mysql-yum/index.py index 97d983b60..7de864129 100755 --- a/plugins/mysql-yum/index.py +++ b/plugins/mysql-yum/index.py @@ -1754,7 +1754,7 @@ def addMasterRepSlaveUser(version=''): # address = args['address'].strip() # dataAccess = args['dataAccess'].strip() - reg = "^[\w\.-]+$" + reg = "^[\w-]+$" if not re.match(reg, username): return mw.returnJson(False, '用户名不能带有特殊符号!') checks = ['root', 'mysql', 'test', 'sys', 'panel_logs'] diff --git a/plugins/mysql/index.py b/plugins/mysql/index.py index 7318cbd83..a41739c67 100755 --- a/plugins/mysql/index.py +++ b/plugins/mysql/index.py @@ -1935,7 +1935,7 @@ def addMasterRepSlaveUser(version=''): # address = args['address'].strip() # dataAccess = args['dataAccess'].strip() - reg = "^[\w\.-]+$" + reg = "^[\w-]+$" if not re.match(reg, username): return mw.returnJson(False, '用户名不能带有特殊符号!') checks = ['root', 'mysql', 'test', 'sys', 'panel_logs']