浏览代码

Merge pull request #33 from crowdsecurity/cscli_calculate_ips

add missing IPs calculation
Thibault "bui" Koechlin 5 年之前
父节点
当前提交
2e0b0597c5
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      cmd/crowdsec-cli/ban.go

+ 2 - 0
cmd/crowdsec-cli/ban.go

@@ -64,6 +64,8 @@ func simpleBanToSignal(targetIP string, reason string, expirationStr string, act
 		if parsedIP == nil {
 			return signalOcc, fmt.Errorf("'%s' is not a valid IP", targetIP)
 		}
+		banApp.StartIp = types.IP2Int(parsedIP)
+		banApp.EndIp = types.IP2Int(parsedIP)
 	}
 
 	var banApps = make([]types.BanApplication, 1)