diff --git a/db/2pigxx.sql b/db/2pigxx.sql index c0cd676e4..2439ee74b 100644 --- a/db/2pigxx.sql +++ b/db/2pigxx.sql @@ -474,6 +474,7 @@ INSERT INTO `sys_oauth_client_details` VALUES (3, 'gen', NULL, 'gen', 'server', INSERT INTO `sys_oauth_client_details` VALUES (4, 'mp', NULL, 'mp', 'server', 'password,refresh_token', NULL, NULL, NULL, NULL, '{\"enc_flag\":\"1\",\"captcha_flag\":\"1\"}', 'true', '0', ' ', ' ', NULL, NULL, 1); INSERT INTO `sys_oauth_client_details` VALUES (5, 'pig', NULL, 'pig', 'server', 'password,refresh_token,authorization_code,client_credentials,mobile', 'http://localhost:4040/sso1/login,http://localhost:4041/sso1/login,http://localhost:8080/renren-admin/sys/oauth2-sso,http://localhost:8090/sys/oauth2-sso', NULL, 0, 0, '{\"enc_flag\":\"1\",\"captcha_flag\":\"1\"}', 'false', '0', ' ', ' ', NULL, NULL, 1); INSERT INTO `sys_oauth_client_details` VALUES (6, 'test', NULL, 'test', 'server', 'password,refresh_token', NULL, NULL, NULL, NULL, '{ \"enc_flag\":\"1\",\"captcha_flag\":\"0\"}', 'true', '0', ' ', ' ', NULL, NULL, 1); +INSERT INTO `sys_oauth_client_details` VALUES (7, 'social', NULL, 'social', 'server', 'password,refresh_token,mobile', NULL, NULL, NULL, NULL, '{ \"enc_flag\":\"1\",\"captcha_flag\":\"0\"}', 'true', '0', ' ', ' ', NULL, NULL, 1); COMMIT; -- ---------------------------- diff --git a/db/v4.2_v4.3_update.sql b/db/v4.2_v4.3_update.sql index edab9dd1f..eb1e5ba47 100644 --- a/db/v4.2_v4.3_update.sql +++ b/db/v4.2_v4.3_update.sql @@ -148,6 +148,7 @@ INSERT INTO `sys_menu` VALUES (6801, '新增标签', 'mp_wx_account_tag_add', NU INSERT INTO `sys_menu` VALUES (6802, '编辑标签', 'mp_wx_account_tag_edit', NULL, 6800, NULL, 1, '0', '1', ' ', '2019-03-29 15:43:54', ' ', '2020-03-24 08:58:39', '0', 1); INSERT INTO `sys_menu` VALUES (6803, '删除标签', 'mp_wx_account_tag_del', NULL, 6800, NULL, 1, '0', '1', ' ', '2019-03-29 15:43:54', ' ', '2020-03-24 08:58:39', '0', 1); INSERT INTO `sys_menu` VALUES (6804, '同步标签', 'mp_wx_account_tag_sync', NULL, 6800, NULL, 1, '0', '1', ' ', '2019-03-29 15:43:54', ' ', '2022-02-17 15:44:24', '0', 1); +INSERT INTO `sys_oauth_client_details` VALUES (7, 'social', NULL, 'social', 'server', 'password,refresh_token,mobile', NULL, NULL, NULL, NULL, '{ \"enc_flag\":\"1\",\"captcha_flag\":\"0\"}', 'true', '0', ' ', ' ', NULL, NULL, 1); -- pigxx_ac USE pigxx_ac; diff --git a/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/resolver/SqlFilterArgumentResolver.java b/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/resolver/SqlFilterArgumentResolver.java index 6acff2b88..39427caa2 100644 --- a/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/resolver/SqlFilterArgumentResolver.java +++ b/pigx-common/pigx-common-data/src/main/java/com/pig4cloud/pigx/common/data/resolver/SqlFilterArgumentResolver.java @@ -107,14 +107,7 @@ public class SqlFilterArgumentResolver implements HandlerMethodArgumentResolver * @return Predicate */ private Predicate sqlInjectPredicate() { - return sql -> { - for (String keyword : KEYWORDS) { - if (StrUtil.containsIgnoreCase(sql, keyword)) { - return false; - } - } - return true; - }; + return sql -> Arrays.stream(KEYWORDS).noneMatch(keyword -> StrUtil.containsIgnoreCase(sql, keyword)); } } diff --git a/pom.xml b/pom.xml index 85d92feb4..a395745f6 100644 --- a/pom.xml +++ b/pom.xml @@ -33,7 +33,7 @@ - 2.6.3 + 2.6.4 2021.0.1 2021.1 UTF-8