Merge remote-tracking branch 'origin/master'

This commit is contained in:
Hao Miao
2024-01-23 12:17:30 +08:00
13 changed files with 202 additions and 17 deletions

View File

@@ -11,7 +11,7 @@ import lombok.Data;
public class FiveTupleWithMask {
@Schema(description = "地址类型(IPv4 or IPv6)", example = "4")
@JsonProperty("addr_type")
private Integer addrType;
private Integer addrType = 4;
@Schema(description = "源IP", example = "192.168.104.14")
@Pattern(regexp = "^(\\d{1,3})\\.(\\d{1,3})\\.(\\d{1,3})\\.(\\d{1,3})$", message = "源IP无效IPv4地址")

View File

@@ -67,6 +67,10 @@ public class TaskCommandInfo {
@JsonProperty("is_valid")
private Boolean isValid = true;
@Schema(description = "指令是否已研判", example = "true")
@JsonProperty("is_judged")
private Boolean isJudged = true;
@Schema(description = "五元组信息")
@NotNull(message = "五元组信息不能为空。")
@JsonProperty("five_tuple_with_mask")
@@ -87,10 +91,6 @@ public class TaskCommandInfo {
@Schema(description = "最新下发时间", accessMode = Schema.AccessMode.READ_ONLY)
@JsonProperty("latest_send_times")
private LocalDateTime latestSendTime;
@Schema(description = "指令是否研判", example = "true")
@JsonProperty("is_judeged")
private Boolean isJudged = true;
/*
以下属性用于动态规则生成不写入dorist_command表
*/

View File

@@ -36,7 +36,6 @@ public class CommandService {
commandInfo.setUUID(UUID.randomUUID().toString());
commandMapper.createCommand(commandInfo);
return commandInfo.getUUID();
}
public void createCommands(List<TaskCommandInfo> taskCommandInfos) {

View File

@@ -48,7 +48,6 @@ public class StateHandler {
}
protected Boolean handleResume(CommandService commandService, Long taskId) {
commandService.startCommandsByTaskId(taskId);
return true;
}