Skip to content

Commit 1e9bc51

Browse files
committed
批量查询时 api 超过 fofa 最大查询次数直接退出
1 parent 34de64f commit 1e9bc51

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

internal/fofa/fofa_api.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,10 @@ func (f *FoFa) Fetch(queryStr string) bool {
200200
//}
201201

202202
func getApiErrInfo(code string) string {
203+
// {errmsg: "Request overrun on the day, restrict access, try again tomorrow", error: true}
204+
if strings.Contains(code, "try again tomorrow") {
205+
printer.Fatal(code)
206+
}
203207
switch code {
204208
case "820000":
205209
return "查询语法错误"

0 commit comments

Comments
 (0)