Nmap Firewall / IDS / IPS Evasion Techniques

Use LLMs in combination with these techniques to further enhance the evasion.

1. Packet Fragmentation

Goal: Break signatures that expect full packets.

nmap -f 192.168.1.10
nmap --mtu 24 192.168.1.10

Why it works

  • Some firewalls/IDS don’t properly reassemble fragments

  • Signature-based detection may miss payloads split across packets

Weakness

  • Modern IDS/IPS usually reassemble fragments correctly


2. Decoy Scanning

Goal: Obscure the real scanner’s IP.

nmap -D 10.0.0.5,10.0.0.6,ME 192.168.1.10

What happens

  • Target sees multiple source IPs

  • Only one is real (ME)

  • Makes attribution harder in logs

Detection

  • IDS may fingerprint timing, TTL, or TCP behavior differences


3. Source IP Spoofing

Goal: Hide origin (mostly theoretical).

Important

  • ❌ Does NOT work for TCP connect scans

  • Responses go to the spoofed IP

  • Useful only in limited scenarios (stateless scans, research)


4. Source Port Manipulation

Goal: Bypass naive firewall rules.

Why

  • Firewalls often allow traffic from DNS (53) or HTTPS (443)

Reality

  • Modern firewalls inspect state, not just ports


5. Interface Selection

Goal: Control routing / VLAN behavior.

Useful in

  • Multi-homed hosts

  • VPN vs local interface testing


6. Proxy Chaining

Goal: Hide scanning origin (TCP only).

Limitations

  • Works only with TCP connect scans

  • Slow

  • Easy to fingerprint as proxied traffic


7. Custom Payload Injection

Goal: Evade static signatures.

Why

  • Changes packet fingerprints

  • Can bypass payload-based IDS rules


8. IP Options

Goal: Trigger edge-case handling.

Reality

  • Often blocked outright

  • Mostly useful for detection testing, not evasion


9. TTL Manipulation

Goal: Evade inline IPS or map network position.

Use cases

  • Bypass poorly placed IPS

  • Identify hop-count differences


10. MAC Address Spoofing

Goal: Evade local network controls.

Works against

  • NAC

  • MAC-based ACLs (weak security)


11. Bad Checksum Packets

Goal: Test IDS vs firewall handling.

What happens

  • Firewall drops the packet

  • IDS may still log it

Use

  • Detect IDS positioned behind a firewall


Typical Real-World Combos (Theory Level)

⚠️ Common in exams and labs, not reliable real-world bypasses

Why

  • Packet fragmentation

  • Random decoys

  • Trusted source port


Last updated