Chuyển đến nội dung
Skillpedia
Triển khai và đám mây (DevOps)35k · #8056

implementing-ics-firewall-with-tofino

Skill này làm gì

Tính năng này cấu hình tường lửa công nghiệp Tofino để bảo vệ hệ thống điều khiển (như trong nhà máy) và thiết bị như PLC. Nó kiểm tra lưu lượng mạng để đảm bảo chỉ các giao tiếp được ủy quyền mới diễn ra, đặc biệt đối với các giao thức công nghiệp.

Khi nào nên dùng

  • ✓Khi triển khai tường lửa bảo vệ gần các PLC hoặc RTU.
  • ✓Khi cần kiểm tra nội dung gói tin giao thức công nghiệp.
  • ✓Khi tạo ranh giới bảo mật giữa các phần khác nhau của mạng công nghiệp.

Liên kết skill

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/implementing-ics-firewall-with-tofino/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/implementing-ics-firewall-with-tofino/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Cấu hình tường lửa Tofino để bảo vệ các PLC trong khu vực điều khiển lò phản ứng, chỉ cho phép giao tiếp vận hành và kỹ thuật từ máy trạm kỹ thuật và máy chủ HMI.”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Tường lửa Tofino được thiết lập với các quy tắc cụ thể, hiểu được giao thức công nghiệp. Nó phân tích dữ liệu đi qua và chặn mọi thứ không khớp với quy tắc đã định, đảm bảo an toàn.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Implementing ICS Firewall with Tofino

When to Use

  • When deploying zone-level firewall protection directly in front of critical PLCs or RTUs
  • When requiring deep packet inspection of industrial protocols (Modbus, EtherNet/IP, OPC, S7comm)
  • When implementing IEC 62443 zone and conduit boundaries with protocol-aware enforcement
  • When protecting legacy PLCs that cannot be patched and need compensating controls
  • When segmenting control network zones without disrupting existing industrial communications

Do not use for enterprise IT firewall deployment, for perimeter firewall between IT and OT (use Palo Alto/Fortinet at the DMZ), or for environments using only IP-based protocols without OT-specific DPI needs.

Prerequisites

  • Tofino Xenon appliance or Tofino virtual appliance with appropriate license
  • Tofino Central Management Platform (CMP) for centralized policy management
  • Network topology map showing PLC/RTU placement and communication requirements
  • Baseline of OT protocol communications (Modbus function codes, EtherNet/IP CIP services)
  • Change management approval for inline deployment between network zones

Workflow

Step 1: Design Tofino Deployment Architecture

# Tofino ICS Firewall Deployment Architecture
# Zone-level protection using deep packet inspection

deployment_zones:
  zone_1_reactor_control:
    tofino_appliance: "TOFINO-XN-001"
    deployment_mode: "inline_bridge"
    protected_assets:
      - name: "PLC-REACTOR-01"
        ip: "10.10.1.10"
        vendor: "Siemens S7-1500"
        protocols: ["S7comm/102", "Profinet"]
      - name: "PLC-REACTOR-02"
        ip: "10.10.1.11"
        vendor: "Siemens S7-1500"
        protocols: ["S7comm/102", "Profinet"]
    authorized_communications:
      - source: "10.10.2.50"  # Engineering workstation
        dest: "10.10.1.0/24"
        protocols: ["S7comm"]
        access_type: "engineering"
      - source: "10.10.2.10"  # HMI server
        dest: "10.10.1.0/24"
        protocols: ["S7comm"]
        access_type: "operational"

  zone_2_packaging:
    tofino_appliance: "TOFINO-XN-002"
    deployment_mode: "inline_bridge"
    protected_assets:
      - name: "PLC-PACK-01"
        ip: "10.10.3.10"
        vendor: "Rockwell ControlLogix"
        protocols: ["EtherNet-IP/44818", "CIP"]
    authorized_communications:
      - source: "10.10.2.20"  # HMI
        dest: "10.10.3.0/24"
        protocols: ["EtherNet-IP"]
        access_type: "operational"

  zone_3_utilities:
    tofino_appliance: "TOFINO-XN-003"
    deployment_mode: "inline_bridge"
    protected_assets:
      - name: "RTU-BOILER-01"
        ip: "10.10.4.10"
        vendor: "Schneider M340"
        protocols: ["Modbus-TCP/502"]
    authorized_communications:
      - source: "10.10.2.30"  # SCADA server
        dest: "10.10.4.0/24"
        protocols: ["Modbus-TCP"]
        allowed_function_codes: [1, 2, 3, 4]  # Read only from SCADA

Step 2: Configure Deep Packet Inspection Rules

#!/usr/bin/env python3
"""Tofino ICS Firewall Rule Generator.

Generates Tofino firewall rules with deep packet inspection for
industrial protocols based on communication baseline analysis.
"""

import json
import sys
from datetime import datetime
from typing import Dict, List


class TofinoRuleGenerator:
    """Generates Tofino ICS firewall DPI rules."""

    def __init__(self):
        self.rules = []
        self.rule_id = 1000

    def add_modbus_rule(self, src: str, dst: str, allowed_funcs: List[int],
                        allowed_registers: List[dict] = None, description: str = ""):
        """Generate Modbus DPI rule."""
        func_names = {
            1: "read_coils", 2: "read_discrete_inputs",
            3: "read_holding_registers", 4: "read_input_registers",
            5: "write_single_coil", 6: "write_single_register",
            15: "write_multiple_coils", 16: "write_multiple_registers",
        }

        rule = {
            "rule_id": self.rule_id,
            "protocol": "Modbus-TCP",
            "action": "ALLOW",
            "source": src,
            "destination": dst,
            "port": 502,
            "dpi_policy": {
                "allowed_function_codes": [
                    {"code": fc, "name": func_names.get(fc, f"FC{fc}")}
                    for fc in allowed_funcs
                ],
                "blocked_function_codes": [
                    fc for fc in range(1, 128) if fc not in allowed_funcs
                ],
            },

…
Câu hỏi thường gặp

PLC và RTU là gì?

PLC (Programmable Logic Controller) và RTU (Remote Terminal Unit) là các thiết bị dùng để điều khiển và giám sát quy trình công nghiệp.

Kiểm tra sâu gói tin (DPI) là gì?

Đây là kỹ thuật cho phép tường lửa kiểm tra nội dung của các gói dữ liệu, không chỉ địa chỉ nguồn và đích, để hiểu và kiểm soát các giao thức cụ thể.

Tôi có thể dùng cái này để bảo vệ mạng văn phòng không?

Không, tường lửa này được thiết kế riêng cho mạng công nghiệp và các giao thức cụ thể. Với mạng văn phòng, các loại tường lửa khác phù hợp hơn.

Chi tiết

Mô tả gốc của tác giả

Deploys and configures Tofino industrial firewalls (Belden/Hirschmann) to protect SCADA systems and PLCs, using deep packet inspection of OT protocols (Modbus, EtherNet/IP, OPC, S7comm) to enforce access control between ICS zones. Use when deploying zone-level firewall protection in front of PLCs/RTUs, enforcing IEC 62443 zone/conduit boundaries, or adding compensating controls for unpatchable leg

repo: mukul975/Anthropic-Cybersecurity-Skills

Độ phổ biến

Sao GitHub
35k
Vị trí xếp hạng
#8056
Giấy phép
Apache-2.0
Cập nhật
31/8/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự