From 8b3b3ad9469238d2c20e1166950be033c40e548e Mon Sep 17 00:00:00 2001 From: tiejiaxiaobao <2922035952@qq.com> Date: Sun, 15 Dec 2024 23:27:06 +0800 Subject: [PATCH] modified:add a small change. --- .../collector/collect/database/JdbcCommonCollect.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hertzbeat-collector/hertzbeat-collector-basic/src/main/java/org/apache/hertzbeat/collector/collect/database/JdbcCommonCollect.java b/hertzbeat-collector/hertzbeat-collector-basic/src/main/java/org/apache/hertzbeat/collector/collect/database/JdbcCommonCollect.java index c89020e876a..b602d2cdcf8 100644 --- a/hertzbeat-collector/hertzbeat-collector-basic/src/main/java/org/apache/hertzbeat/collector/collect/database/JdbcCommonCollect.java +++ b/hertzbeat-collector/hertzbeat-collector-basic/src/main/java/org/apache/hertzbeat/collector/collect/database/JdbcCommonCollect.java @@ -296,7 +296,8 @@ private String constructDatabaseUrl(JdbcProtocol jdbcProtocol) { // check whether the parameter is valid if (url.contains("create trigger") || url.contains("create alias") || url.contains("runscript from") || url.contains("allowloadlocalinfile") || url.contains("allowloadlocalinfileinpath") - || url.contains("uselocalinfile")) { + || url.contains("uselocalinfile") || url.contains("autodeserialize") || url.contains("detectcustomcollations") + || url.contains("serverstatusdiffinterceptor")) { throw new IllegalArgumentException("Invalid JDBC URL: contains malicious characters."); } // when has config jdbc url, use it