You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by "github-code-scanning[bot] (via GitHub)" <gi...@apache.org> on 2023/02/07 08:35:10 UTC

[GitHub] [dolphinscheduler] github-code-scanning[bot] commented on a diff in pull request #13527: [fix-13489] Complement task with wrong date format input causes an infinite loop

github-code-scanning[bot] commented on code in PR #13527:
URL: https://github.com/apache/dolphinscheduler/pull/13527#discussion_r1098335421


##########
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/ExecutorServiceImpl.java:
##########
@@ -1241,6 +1241,18 @@
             if (scheduleResult.get(CMD_PARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST) == null) {
                 return false;
             }
+            String[] stringDates = scheduleResult.get(CMD_PARAM_COMPLEMENT_DATA_SCHEDULE_DATE_LIST).split(COMMA);
+            for (String stringDate : stringDates) {
+                try {
+                    ZonedDateTime dateTime = DateUtils.stringToZoneDateTime(stringDate.trim());
+                    if (dateTime == null) {
+                        return false;
+                    }
+                } catch (Exception ex) {
+                    logger.warn("Parse schedule time error, date string: {}", stringDate.trim());

Review Comment:
   ## Log Injection
   
   This log entry depends on a [user-provided value](1).
   This log entry depends on a [user-provided value](2).
   
   [Show more details](https://github.com/apache/dolphinscheduler/security/code-scanning/2661)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@dolphinscheduler.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org