iT邦幫忙

2025 iThome 鐵人賽

DAY 20
0
Security

安全助手養成 Vibe UP系列 第 20

Day 20:以 n8n 範例為案例 — AI 驅動的 Domain/IP 安全檢查整合設計

  • 分享至 

  • xImage
  •  

🎯 今日目標

剖析這個公開 n8n workflow:「AI-Powered Domain & IP Security Check Automation」,從設計架構、模組整合、資料流與擴充角度來看,並思考如何以你的安全助手方案套用或改造。
https://n8n.io/workflows/7189-ai-powered-domain-and-ip-security-check-automation/


1️⃣ 問題場景

  • 單純靠被動查詢 Shodan / VirusTotal / AbuseIPDB 雖有風險檢測能力,但可能難以整合與自動化整理成評估報表與行動建議。
  • 安全團隊常常需透過多個 API 結果手動比對、匯整報告,效率低。
  • 若能引入 AI(摘要、評估、警示建議)自動生成判斷與結果,則可加速決策流程。

2️⃣ 模組定位

這個案例裡的模組可以看成是你安全助手的一個子流程模型,包含:

  • Input 模組:從 Google Sheets 拿 domain / IP 清單(狀態為 “To do” 的項目)
  • 資料擷取模組:使用 VirusTotal 查 domain 報告,AbuseIPDB 查 IP reputation,Google DNS 查 SPF / DKIM / DMARC 設定。
  • AI 評估模組:將多個資料點送給 AI(模型)做整合評估,產出簡短語句與風險摘要。
  • 輸出模組:把 AI 評估結果寫回 Google Sheets,將異常標示為 “Done / Flagged”,並加入備註或通報線路。

3️⃣ 技術實作

A. Virustotal分析

https://ithelp.ithome.com.tw/upload/images/20251004/20077752gZbs29dgds.png

  1. Get a domain report
    查詢該 Domain 的概要資訊
    Returns a Domain object.

api/v3/domains/{{ $json.Domain }}
https://ithelp.ithome.com.tw/upload/images/20251004/20077752vYZUvFN4Cn.png

  1. Request an domain rescan (re-analyze)
    要求 VirusTotal 對這個 domain 再做一次新的分析
    Domains in VirusTotal can be reanalysed to refresh their verdicts, whois information, SSL certs, etc. This endpoint sends the domain to be scanned and returns an analysis ID that can be used to retrieve the verdicts from the available vendors using the Analyses endpoint.

api/v3/domains/{{ $json.data.id }}/analyse
https://ithelp.ithome.com.tw/upload/images/20251004/20077752hq2l5XFHTs.png

  1. Get a URL / file analysis
    查詢分析進度 / 結果
    Returns an Analysis object.

api/v3/analyses/{{ $json.data.id }}
https://ithelp.ithome.com.tw/upload/images/20251004/20077752A56erUShPK.png

  1. resolutions
    查詢該 domain 的歷史解析紀錄 (Passive DNS)
    The resolutions relationship returns a list of past and current IP resolutions for a given domain or subdomain.
    This relationship can be retrieved using the relationships API endpoint. The response contains a list of Resolution objects.

api/v3/domains/{{ $('Get a domain report').item.json.data.id }}/resolutions
https://ithelp.ithome.com.tw/upload/images/20251004/20077752bJYQPITHEb.png

B. DNS

https://ithelp.ithome.com.tw/upload/images/20251004/20077752lVCE5e5cxC.png

  1. dns.google/resolve?name={{ $json.hostname }}&type=TXT
    https://ithelp.ithome.com.tw/upload/images/20251004/20077752XlCP9epi0Y.png

  2. dns.google/resolve?name=_dmarc.{{ $('Malicious Hostname').item.json.hostname }}&type=TXT
    https://ithelp.ithome.com.tw/upload/images/20251004/20077752O9i5TfgQpG.png

  3. dns.google/resolve?name=selector1._domainkey{{ $('Malicious Hostname').item.json.hostname }}&type=TXT
    https://ithelp.ithome.com.tw/upload/images/20251004/200777521iFOzN6oPu.png

  4. AI
    https://ithelp.ithome.com.tw/upload/images/20251004/20077752L8oPw1HNy0.png


4️⃣ 預期收穫

  • 學到如何把多個情資 API 整合在一個流程中自動運作
  • 能看到這個典型 AI 驗證流程的設計方式:輸入 → 資料擷取 → AI 評估 → 輸出結果
  • 得到可借鑑的模組設計與欄位標準化方式,可將此範例套入你自己的安全助手架構
  • 實作一條可運作的 AI 驅動 domain / IP 評估流程,把 AI 加入你的工具鏈,讓判斷更智慧、更有說服力

上一篇
Day 19:用 VirusTotal 補強外部資產監控
系列文
安全助手養成 Vibe UP20
圖片
  熱門推薦
圖片
{{ item.channelVendor }} | {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言