Computer >> บทช่วยสอนคอมพิวเตอร์ >  >> ระบบเครือข่าย >> ความปลอดภัยเครือข่าย

OSI Model และ TCP/IP เกี่ยวข้องกับ Network Security อย่างไร?

OSI Model และ TCP/IP กับ Network Security

OSI Model (7 Layers) และความปลอดภัย

OSI Model ช่วยให้เข้าใจว่า ภัยคุกคามแต่ละชนิดโจมตีเลเยอร์ไหน และ การป้องกันควรวางที่เลเยอร์ไหน

Layerชื่อภัยคุกคามหลักการป้องกัน/Security Controls
7ApplicationSQLi, XSS, Malware, Phishing, DDoS App LayerWAF, Secure Coding, Input Validation, API Security
6PresentationEncoding attacks, SSL/TLS exploitsTLS 1.3, Certificate Pinning, Encryption
5SessionSession Hijacking, FixationSecure Session Management, HTTPS Only
4TransportTCP SYN Flood, UDP Flood, Port ScanningFirewall, Rate Limiting, TCP Hardening
3NetworkIP Spoofing, Routing Attacks, ICMP FloodIPsec, ACL, Router Hardening, BGP Security
2Data LinkARP Spoofing, MAC Flooding, VLAN Hopping, STP AttacksPort Security, DAI, DHCP Snooping, BPDU Guard
1PhysicalWiretapping, Cable Tapping, Hardware ImplantsPhysical Security, Fiber Monitoring, Port Locks

TCP/IP Model (4/5 Layers) และความปลอดภัย

TCP/IP เป็นโมเดลปฏิบัติจริง (Practical) ใช้ใน Internet จริง

TCP/IP Layerเทียบ OSISecurity Focus
ApplicationL5-L7App Security, TLS, DNSSEC, Email Security (DMARC/DKIM/SPF)
TransportL4TCP/UDP Security, TLS/SSL, QUIC
Internet (Network)L3IPsec, IPv6 Security, Routing Security (RPKI)
Network AccessL1-L2Wi-Fi Security (WPA3), 802.1X, MACsec, Physical

จุดสำคัญ: ทำไม TCP/IP "ไม่ปลอดภัย" ต้นฉบับ?

  • ออกแบบมาเพื่อ Openness และ Interoperability ไม่ได้ออกแบบมาเพื่อ Security
  • ไม่มี Authentication/Encryption ในตัว (IP, TCP, UDP, ICMP)
  • IP Address Spoofing ง่าย เพราะไม่ verify source
  • ต้องพึ่ง Add-on Protocols: TLS (L4), IPsec (L3), DNSSEC, SSH

TCP vs UDP ด้าน Security

  • TCP: Reliable, Sequenced, มี Handshake → ใช้ทำ SYN Flood, Session Hijacking
  • UDP: Stateless, ไม่มี Handshake → ใช้ทำ Amplification/Reflection DDoS (DNS, NTP, Memcached)

Security Layers (Defense in Depth)

ไม่ควรพึ่ง Layer เดียว ต้องมี:

  1. Perimeter: Firewall, IPS/IDS, WAF
  2. Network: Segmentation, VLAN, ACL, Zero Trust
  3. Endpoint: EDR, Antivirus, Hardening
  4. Application: Secure Code, WAF, API Gateway
  5. Data: Encryption (At rest/In transit), DLP
  6. Human: Security Awareness, Phishing Simulation

สรุป

  • OSI ช่วย วิเคราะห์และออกแบบ** การป้องกันแบบครบวงจร
  • TCP/IP เป็นความจริงในการทำงาน → ต้อง加固 (Harden) ทุก Layer
  • Network Layer (L3) สำคัญที่สุดสำหรับ IPsec (VPN, Site-to-Site)
  • Transport Layer (L4) สำคัญสำหรับ TLS/SSL (HTTPS, Secure API)