8
n8n 한국어amn8n.com

Wazuh, ClamAV 및 GPT-4를 사용한 엔드포인트 감염 자동 치료

중급

이것은SecOps, AI Summarization분야의자동화 워크플로우로, 9개의 노드를 포함합니다.주로 If, Ssh, Webhook, Telegram, Agent 등의 노드를 사용하며. Wazuh, ClamAV 및 GPT-4를 사용한 엔드포인트 감염 자동 치료

사전 요구사항
  • HTTP Webhook 엔드포인트(n8n이 자동으로 생성)
  • Telegram Bot Token
  • OpenAI API Key
워크플로우 미리보기
노드 연결 관계를 시각적으로 표시하며, 확대/축소 및 이동을 지원합니다
워크플로우 내보내기
다음 JSON 구성을 복사하여 n8n에 가져오면 이 워크플로우를 사용할 수 있습니다
{
  "meta": {
    "instanceId": "04efa85563ff59ae71f7bc1e4ed9a086a69f4130298a28a588ae58f08407702b",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "fb1f79ac-2b5a-4bac-8f49-9d4938ea8c9b",
      "name": "Wazuh 경고",
      "type": "n8n-nodes-base.webhook",
      "position": [
        -640,
        -112
      ],
      "webhookId": "de0c6d77-ae71-4d78-9f10-502eaa851ce8",
      "parameters": {
        "path": "de0c6d77-ae71-4d78-9f10-502eaa851ce8",
        "options": {
          "rawBody": true
        },
        "httpMethod": "POST"
      },
      "typeVersion": 2
    },
    {
      "id": "961ed6cb-a6b7-401f-a2b5-aaadf91ab4f1",
      "name": "작업 없음, 아무것도 하지 않음",
      "type": "n8n-nodes-base.noOp",
      "position": [
        -112,
        32
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "6ed0c622-e956-46da-87bb-82d96548f108",
      "name": "OpenAI 채팅 모델",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -96,
        -144
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "Qf3yZKrzzR0LSOXm",
          "name": "OpenAi account"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "84cfeaa8-db3b-48be-a89d-fd2f9a3d66ec",
      "name": "OpenAI 채팅 모델1",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        304,
        -48
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "Qf3yZKrzzR0LSOXm",
          "name": "OpenAi account"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "b8e61b73-87fd-4511-9514-03135d34c348",
      "name": "높은 심각도 확인",
      "type": "n8n-nodes-base.if",
      "position": [
        -416,
        -112
      ],
      "parameters": {
        "options": {
          "ignoreCase": true
        },
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": false,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "0c8dba85-ab11-4ef9-9049-d3ad934976ef",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.body.severity }}",
              "rightValue": "3 high"
            },
            {
              "id": "2a4587f8-ccae-435c-8c67-1606811538a2",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.body.rule_id }}",
              "rightValue": "=52502"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "cad813f2-fb68-4e31-a85c-5732f11f4f96",
      "name": "경고 요약",
      "type": "@n8n/n8n-nodes-langchain.chainSummarization",
      "position": [
        -192,
        -368
      ],
      "parameters": {
        "options": {
          "summarizationMethodAndPrompts": {
            "values": {
              "prompt": "Write a detailed concise summary of the following as a Senior soc analyst:\n\n\n\"{text}\"\n\n\nCONCISE SUMMARY:",
              "combineMapPrompt": "=You are the Wazuh AI Assistant created by Mariskarthick. \n\nYou should act as a Senior experienced SOC Analyst\n\nYour main purpose is to run the ClamAV if wazuh siem detected a ClamAV: Virus detected alert. you have full access to the all the machines via ssh and initate a CLAM AV scan using this command  sudo clamscan -r \"mention the path where the virus is detected\"  --bell -i\n\nfor example:  sudo clamscan -r /test --bell -i\n\nonce the scanning is done, consolidate the output of the scan and initiate a msg to stateholder via shadowArk telegram trigger\n\nyou can refer the below details:\n Wazuh detected alert Name: {{ $json.body.title }}\nFull log: {{ $json.body.text }}\n"
            }
          }
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "3c6645a6-3d16-48ec-8f35-a850244c3536",
      "name": "경로 추출",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        208,
        -256
      ],
      "parameters": {
        "text": "={{ $json.output.text }}\n\nYou are the wazuh AI Assistant. your primary task is to understand the abive mentioend text and extract the path where the virus got detected on the below format:\n\nExamle: \n\ntext:\nA high-severity WAZUH alert was triggered on July 30, 2025, indicating ClamAV detected the EICAR test virus (EICAR.TEST.3.UNOFFICIAL) in the file `/test/eicar.com` on the host `shadowark`. The detection was logged by the ClamAV daemon (clamd) and confirmed repeatedly at 13:44:27, involving components such as freshclam and journald. The alert originated from IP `122.178.166.190` accessing `3aad845638746618f1a5187d93674f5f.n8n.selfmade.codes` via HTTPS.\n\noutput required:\n/test/eicar.com",
        "options": {},
        "promptType": "define"
      },
      "typeVersion": 2.1
    },
    {
      "id": "f44a9bc0-46d4-45c3-aaaa-3bf2eb567578",
      "name": "AV 스캔 실행",
      "type": "n8n-nodes-base.ssh",
      "position": [
        608,
        -256
      ],
      "parameters": {
        "command": "=clamscan -r {{ $json.output }} --bell -i"
      },
      "credentials": {
        "sshPassword": {
          "id": "ounO8RvAyII5YqON",
          "name": "Wazuh_Manager"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "8858c573-ad0b-4f14-8a19-993a93f6d8ca",
      "name": "Telegram을 통한 이해관계자 알림",
      "type": "n8n-nodes-base.telegram",
      "position": [
        816,
        -272
      ],
      "webhookId": "4f1045ae-5d81-46fc-b0ae-7146529a9700",
      "parameters": {
        "text": "=Notification: \n\n{{ $('Summarize Alert').item.json.output.text }}\n\n\nFollowed by the above activity, the scanning has been initiated and completed successfully. please find the below details.\n\n{{ $json.stdout }}\n\nThank you!\nMariskarthick M",
        "chatId": "831690003",
        "additionalFields": {}
      },
      "credentials": {
        "telegramApi": {
          "id": "kb3ymxZjowjLNhLb",
          "name": "Shadowark AI"
        }
      },
      "typeVersion": 1.2
    }
  ],
  "pinData": {},
  "connections": {
    "f44a9bc0-46d4-45c3-aaaa-3bf2eb567578": {
      "main": [
        [
          {
            "node": "8858c573-ad0b-4f14-8a19-993a93f6d8ca",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "fb1f79ac-2b5a-4bac-8f49-9d4938ea8c9b": {
      "main": [
        [
          {
            "node": "b8e61b73-87fd-4511-9514-03135d34c348",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3c6645a6-3d16-48ec-8f35-a850244c3536": {
      "main": [
        [
          {
            "node": "f44a9bc0-46d4-45c3-aaaa-3bf2eb567578",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "cad813f2-fb68-4e31-a85c-5732f11f4f96": {
      "main": [
        [
          {
            "node": "3c6645a6-3d16-48ec-8f35-a850244c3536",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "6ed0c622-e956-46da-87bb-82d96548f108": {
      "ai_languageModel": [
        [
          {
            "node": "cad813f2-fb68-4e31-a85c-5732f11f4f96",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "84cfeaa8-db3b-48be-a89d-fd2f9a3d66ec": {
      "ai_languageModel": [
        [
          {
            "node": "3c6645a6-3d16-48ec-8f35-a850244c3536",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "b8e61b73-87fd-4511-9514-03135d34c348": {
      "main": [
        [
          {
            "node": "cad813f2-fb68-4e31-a85c-5732f11f4f96",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "961ed6cb-a6b7-401f-a2b5-aaadf91ab4f1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
자주 묻는 질문

이 워크플로우를 어떻게 사용하나요?

위의 JSON 구성 코드를 복사하여 n8n 인스턴스에서 새 워크플로우를 생성하고 "JSON에서 가져오기"를 선택한 후, 구성을 붙여넣고 필요에 따라 인증 설정을 수정하세요.

이 워크플로우는 어떤 시나리오에 적합한가요?

중급 - 보안 운영, AI 요약

유료인가요?

이 워크플로우는 완전히 무료이며 직접 가져와 사용할 수 있습니다. 다만, 워크플로우에서 사용하는 타사 서비스(예: OpenAI API)는 사용자 직접 비용을 지불해야 할 수 있습니다.

워크플로우 정보
난이도
중급
노드 수9
카테고리2
노드 유형8
난이도 설명

일정 경험을 가진 사용자를 위한 6-15개 노드의 중간 복잡도 워크플로우

저자
mariskarthick

mariskarthick

@mariskarthick

An Opensource Enthusiast specializing in detection engineering, threat hunting, and automating security operations to accelerate threat detection and response.

외부 링크
n8n.io에서 보기

이 워크플로우 공유

카테고리

카테고리: 34