diff options
| author | shihaoyue <[email protected]> | 2024-09-01 22:25:02 +0800 |
|---|---|---|
| committer | shihaoyue <[email protected]> | 2024-09-01 22:25:02 +0800 |
| commit | ae91af60b5003d208c410f790f4be05c3a637386 (patch) | |
| tree | 578dfeca19f7280625b092dba0b72d29ea08fa74 | |
| parent | 45681fb4fd50b7e1346a9cc533c76f19e671c61a (diff) | |
获取不到目标信息时处理
| -rw-r--r-- | agent/apps/target_gz.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/agent/apps/target_gz.py b/agent/apps/target_gz.py index 7bfbba2..f119bd2 100644 --- a/agent/apps/target_gz.py +++ b/agent/apps/target_gz.py @@ -20,5 +20,8 @@ def execute_command(IP): encoding='utf-8') output = proc.communicate()[0].strip() + # 报错的情况 + if "udp" in output: + output = None return output
\ No newline at end of file |
