Browse Source

fix: tcpdump想捕捉所有ip时,空ip被解析成0.0.0.0,导致捕捉不到的问题

pull/12874/head
jiangweidong 8 months ago committed by Bryan
parent
commit
ccd4f3ada4
  1. 3
      apps/settings/utils/common.py

3
apps/settings/utils/common.py

@ -20,7 +20,8 @@ def get_login_title():
def generate_ips(address_string):
def transform(_ip):
real_ip, err_msg = lookup_domain(_ip)
return _ip if err_msg else real_ip
return _ip if err_msg or real_ip == '0.0.0.0' else real_ip
# 支持的格式
# 192.168.1.1,192.168.1.2
# 192.168.1.1-12 | 192.168.1.1-192.168.1.12 | 192.168.1.0/30 | 192.168.1.1

Loading…
Cancel
Save