feat(X-Pack): 取消新建数据填报数据库表时对表名和字段名的敏感词校验

This commit is contained in:
ulleo 2024-04-26 17:58:44 +08:00
parent 957a74e54e
commit 53ae10d82c

View File

@ -39,9 +39,9 @@ public class MysqlExtDDLProvider extends DefaultExtDDLProvider {
@Override
public String createTableSql(String table, List<ExtTableField> formFields) {
//check inject
if (checkSqlInjection(table)) {
/*if (checkSqlInjection(table)) {
throw new RuntimeException("包含SQL注入的参数请检查参数");
}
}*/
List<ExtTableField.TableField> fields = convertTableFields(true, formFields);
String fieldSql = convertTableFieldsString(table, fields);
@ -249,9 +249,9 @@ public class MysqlExtDDLProvider extends DefaultExtDDLProvider {
}
//check inject
if (checkSqlInjection(field.getColumnName())) {
/*if (checkSqlInjection(field.getColumnName())) {
throw new RuntimeException("包含SQL注入的参数请检查参数");
}
}*/
//column name
str.append("`").append(field.getColumnName()).append("` ");
@ -345,9 +345,9 @@ public class MysqlExtDDLProvider extends DefaultExtDDLProvider {
}
//check inject
if (checkSqlInjection(table) || checkSqlInjection(indexField.getName())) {
/*if (checkSqlInjection(table) || checkSqlInjection(indexField.getName())) {
throw new RuntimeException("包含SQL注入的参数请检查参数");
}
}*/
int count = 0;
for (ExtIndexField.ColumnSetting indexFieldColumn : indexField.getColumns()) {