AWS Security Group & NACL ကိုတွဲသုံးတဲ့အခါ Traffic Flow, Stateful vs Stateless, Best Practice
AWS Cloud Networking မှာ Security Group (SG) နဲ့ Network Access Control List (NACL) ကိုအတူသုံးတဲ့အချိန် Traffic Flow, Stateful/Stateless လုပ်ဆောင်ချက်၊ Best Practice စတာတွေကိုနားလည်ထားရင် Security အတွက်လဲ အဆင်ပြေသလို Troubleshooting လဲ လွယ်ကူစေပါတယ်။
1. SG & NACL Traffic Flow
Client တစ်ယောက်က EC2 Instance ဆီ Traffic ပို့တဲ့အချိန်မှာ AWS အတွင်း Flow က အောက်ကအတိုင်း ဖြစ်ပါတယ်။
Inbound Flow:
Client → NACL → Security Group → EC2
Outbound Flow:
EC2 → Security Group → NACL → Internet
ဆိုတော့ NACL က Subnet Layer မှာ first gatekeeper အဖြစ်လုပ်ဆောင်ပြီး, SG က Instance Layer မှာ last gatekeeper အဖြစ် Instance ထဲကို ဝင်လာမယ့်/ထွက်သွားမယ့် traffic ကို filter လုပ်ပေးတာပါ။
2. Stateful vs Stateless Impact
SG က Stateful ဖြစ်တဲ့အတွက် Inbound rule တစ်ခု Allow လုပ်ထားရင် Return traffic ကို AWS က auto allow လုပ်ပေးတာကြောင့် Outbound reply route အတွက် rule အသစ်ထည့်ပေးဖို့မလိုပါဘူး။
NACL က Stateless ဖြစ်တဲ့အတွက် Inbound traffic ကို Allow လုပ်ထားပေမယ့် Return traffic အတွက် Outbound rule ကိုလည်း explicit လုပ်ပေးရပါမယ်။ ဥပမာ - NACL Inbound → Port 22 Allow, NACL Outbound → Ephemeral Ports (1024–65535) မရေးထားရင် SSH connection က timeout ဖြစ်သွားမှာပါ။
ဒီ အချက်က Connection success အတွက် အရေးကြီးတဲ့အချက်ဖြစ်ပြီး, NACL ကို configure လုပ်တဲ့အချိန် သတိထားရမဲ့ အချက်တစ်ခုဖြစ်ပါတယ်။
3. Best Practice
Production-level VPC setup မှာ NACL ကို Broad-Level Blacklist, SG ကို Service-Level Whitelist အနေနဲ့ configure လုပ်ရင် အဆင်ပြေပါတယ်။
NACL: Malicious IP ranges, Suspicious subnets စတာတွေကို Wide-level filtering လုပ်ပြီး Root-level Block/Allow လုပ်မယ်။
SG: Required ports, Trusted source IPs, Instance/Service-specific granular control တွေကို only allow လုပ်ပြီး Service-level access control ကို handle လုပ်မယ်။ ဒီ practice က Security ကိုကောင်းမွန်စေသလို၊ Maintainability အတွက်လည်း အထူးသင့်တော်ပြီး Troubleshooting လုပ်ရာမှာလည်း လွယ်ကူစေပါတယ်
Discussion
Join the conversation
How do you feel about this article?
Comments
Sign in to join the conversation
Sign in to be the first to comment!
Share Your Article
Share with your professional network
Recent Articles

AWS - Application Load Balancer
Elastic Load Balancing (ELB) ELB ဆိုတာကတော့ request တွေကို တစ်နေရာတည်းမှ လက်ခံကာ Amazon EC2 instances၊ containers, etc.....

Terraform Day 3: Benefits of Terraform State
Terraform ကိုလေ့လာ တဲ့အခါ ကျွန််တော်တို့ရဲ့ Project Folder ထဲမှာ terraform.tfstate ဆိုတဲ့ ဖိုင်လေးကို တွေ့ဖူးကြပါလိမ့်မယ...

Terraform Day 2: Essential IaC Principles You Must Know
မနေ့ကတော့ Terraform အကြောင်း အကြမ်းဖျင်း Concept ကို ပြောပြခဲ့ပြီးပြီဆိုတော့ ဒီနေ့မှာတော့ Terraform ကို Professional ကျက...

TCP/IP Protocol
အားလုံးပဲမင်္ဂလာပါ။ ဒီနေ့ ကျွန်တော်တို့ TCP/IP Protocol အကြောင်း ဆွေးနွေးသွားပါမယ်။ ပထမဆုံးအနေနဲ့ TCP/IP ရဲ့ History လေး...

Terraform Day 1: Introduction to IAC and Terraform
ကျွန်တော်တို့ cloud အကြောင်း စပြောကြပြီဆိုရင် အရင်ဆုံး ခေါင်းထဲရောက်လာတာ Console ထဲဝင်၊ UI ကနေ ခလုတ်လေးတွေ လိုက်နှိပ်ပြီ...

