Merge pull request #699 from yakolee/master

sqlwall improve
This commit is contained in:
Yako
2014-11-06 18:21:48 +08:00
@@ -174,14 +174,21 @@ public class WallVisitorUtils {
chrCount++;
}
}
} else if (item instanceof SQLCharExpr) {
if (((SQLCharExpr) item).getText().length() > 5) {
chrCount = 0;
continue;
}
}
if (chrCount >= 4) {
addViolation(visitor, ErrorCode.EVIL_CONCAT, "evil concat", x);
break;
}
}
if (chrCount >= 4) {
addViolation(visitor, ErrorCode.EVIL_CONCAT, "evil concat", x);
}
}
}
return true;
}
@@ -1092,7 +1099,6 @@ public class WallVisitorUtils {
return eval(visitor, dbType, x, Collections.emptyList());
}
public static SQLExpr getFirst(SQLExpr x) {
if (x instanceof SQLBinaryOpExpr) {