CCNA 200-301

CCNP Enterprise

CCNP Security

CCIE Enterprise Lab

CCIE Security Lab

CCNP Service Provider

CCNP Data Center

CCNP Collaboration

CCIE DC Lab

Network diagnostics tools like traceroute and tracert are essential for diagnosing latency, packet loss, and routing anomalies. However, from an infrastructure defense and service provider perspective, these tools also map internal network topologies, reveal core router addressing schemes, and expose control plane resources to reconnaissance probing. Whether hardening enterprise perimeter routers or isolating a carrier backbone from customer visibility, engineers frequently need to intentionally break or suppress traceroute.

Accomplishing this cleanly on Cisco IOS and IOS-XE platforms requires understanding how probes interact with the control plane, differentiating between transit hops and termination hops, and suppressing diagnostic telemetry without causing collateral damage to critical protocols like Path MTU Discovery (PMTUD).


Table of Contents

Understanding Traceroute Mechanics and ICMP Responses on Cisco Hardware

To manipulate how a Cisco router interacts with route tracing utilities, you must first understand the packet-level mechanics governing transit hop identification and destination discovery.

How does traceroute discover hops using IP TTL and ICMP?

Traceroute operates by manipulating the Time-to-Live (TTL) field within the IPv4 header (or Hop Limit in IPv6). The source device transmits a sequence of probe packets starting with an IP TTL of 1. When the first routed hop receives the packet, it decrements the TTL by 1. Because the TTL reaches 0, the router cannot forward the datagram.

Under standard RFC 792 behavior, the router drops the original packet and sends an ICMP Type 11, Code 0 (Time-to-Live Exceeded in Transit) error datagram back to the probe’s source IP address. The sender records the source IP of this ICMP message as the first hop and measures the round-trip delay. The probing utility then increments the TTL to 2, 3, 4, and so on, prompting each successive intermediate transit router along the path to drop the probe and reply with an ICMP Type 11 message until the final destination is reached.

Why do traceroute probes produce asterisks ( * ) on Cisco routers?

An asterisk (* * *) signifies that the probing client waited for a response until a timeout occurred without receiving an ICMP response packet for that specific hop. On a Cisco router, this timeout is typically caused by one of three distinct conditions:
1. ICMP Generation Filtering: An egress Access Control List (ACL) dropped the outbound ICMP Type 11 message generated by the route processor before it exited the router.
2. Inbound Probe Discard: An ingress ACL dropped the incoming UDP, ICMP Echo, or TCP probe before the packet hit the routing engine.
3. Internal Control Plane Rate Limiting: Cisco IOS enforces internal rate limits on ICMP error generation to prevent denial-of-service (DoS) conditions. Probes arriving in excess of the configured threshold are silently discarded by the control plane without a response.

What is the mechanical difference between Unix/Linux traceroute and Windows tracert?

Different operating systems employ different protocols for traceroute probes:
* Unix, Linux, macOS, and Cisco IOS: Send UDP datagrams targeting a high-numbered, unassigned port range (typically destination UDP ports 33434 to 33534). When the packet arrives at the final destination host, the host detects that no application is listening on that port and returns an ICMP Type 3, Code 3 (Destination Unreachable: Port Unreachable) message, terminating the trace.
* Microsoft Windows (tracert): Uses ICMP Type 8, Code 0 (Echo Request) datagrams for its probes—the same packet type used by ping. Transit hops reply with ICMP Type 11 Code 0, but the final destination replies with an ICMP Type 0, Code 0 (Echo Reply).
* Modern TCP Tracers (tcptraceroute, nmap): Dispatch TCP SYN packets (frequently directed toward port 80 or 443) to pass through stateful firewalls that filter generic ICMP and UDP probes.

Why doesn’t “no ip unreachables” alone stop an intermediate Cisco router from appearing in traceroute?

A frequent misconception among network administrators is that entering no ip unreachables on an interface completely breaks traceroute. The no ip unreachables directive specifically disables the transmission of ICMP Type 3 (Destination Unreachable) messages.

When a Cisco router acts as an intermediate transit hop, it drops the probe because the TTL expired; it does not generate a Destination Unreachable message, but rather an ICMP Type 11 (Time-to-Live Exceeded) message. Because no ip unreachables does not suppress Type 11 messages, the intermediate router will continue to expose its IP address to external traceroutes. The command only affects the final hop of a UDP traceroute, where a port unreachable message would normally signal completion.


Comparing Traceroute Suppression Methods: ACLs vs. Interface Directives vs. Rate Limiting

Suppressing traceroute involves balancing security concealment with network stability. The table below compares the primary architectural approaches available in Cisco IOS.

Suppression MethodTransit Hop Concealment (ICMP Type 11)Destination Hop Concealment (ICMP Type 3 / Echo Reply)Impact on Path MTU Discovery (PMTUD)Control Plane CPU LoadOperational Tradeoffs & Limitations
Outbound ICMP Filter (ACL)Full (Silently drops outbound Type 11 messages)None (Unless Type 3 Code 3 or Type 0 are explicitly matched)None (Allows Type 3 Code 4 to pass through unhindered)Minimal (Packets filtered in hardware/CEF before exit)Most targeted approach; requires placing egress ACLs on all perimeter-facing interfaces.
Inbound Probe Filter (ACL)Full (Drops UDP probe range 33434–33534 & ICMP Echo)Full (Stops probes before reaching local sockets)NoneLow (Dropped at ingress ASIC before punt to CPU)Does not block non-standard traceroute variations (e.g., custom TCP SYN traceroutes) unless explicitly defined.
Interface no ip unreachablesNone (Has zero effect on TTL-expired transit hops)Partial (Suppresses Type 3 Port Unreachable on the final hop)Severe (Drops Type 3 Code 4; breaks TCP PMTUD across smaller MTU paths)None (Prevents generation of Type 3 messages entirely)High risk of causing silent black holes for packets with the Don’t Fragment (DF) bit set.
ICMP Error Rate Limiting (ip icmp rate-limit)Partial (Suppresses excess replies, showing intermittent * * *)Partial (Throttles high-frequency Type 3 messages)Low (If configured to spare DF-unreachable traffic)Protective (Guards route processor during high-rate scans)Obfuscates responses inconsistently; does not fully hide topology during slow, single-probe scans.
MPLS Core Hiding (no mpls ip propagate-ttl)Full (Hides all internal P-routers across the label switched path)None (Edge routers remain visible)None (Payload IP MTU handling remains unaffected)Zero impactCarrier-grade method; applies strictly to MPLS-encapsulated core environments.

Using no ip unreachables as a standalone anti-traceroute defense is largely counterproductive: it fails to conceal intermediate router hops and introduces Path MTU Discovery black holes. An extended Access Control List applied at the perimeter remains the most surgical method for IP-routed environments.


Step-by-Step Guide: Blocking Traceroute via Access Lists and Interface Directives

The following procedure configures a Cisco IOS/IOS-XE edge router to eliminate traceroute responses while preserving normal transit forwarding and PMTUD functionality.

                +------------------------------------+
                |         Cisco Edge Router          |
[ External ] -->| Gi0/0/0 (Untrusted)   Gi0/0/1 (LAN)| --> [ Internal Hosts ]
  Probes        +------------------------------------+
                   |                 |
         Inbound ACL Filters       Outbound ACL Filters
         UDP 33434-33534 &         ICMP Type 11 (TTL Exceeded)
         ICMP Echo Probes          Leaving Untrusted Boundary

Step 1: Identify incoming probe signatures

To suppress both Unix/Linux and Windows traces, you must intercept:
* Inbound UDP packets targeting destination ports 33434 through 33534.
* Inbound ICMP Echo Requests (type 8) destined directly to the router’s infrastructure addresses.
* Outbound ICMP Time Exceeded (type 11) packets generated toward untrusted external networks.

Step 2: Build the extended access-list to filter outbound ICMP Time Exceeded

The most reliable method to hide a transit router hop is to permit normal transit traffic while denying the router the ability to return ICMP Time Exceeded messages to external IP addresses.

Enter global configuration mode and create an extended named access list:

Router# configure terminal
Router(config)# ip access-list extended ACL-OUTBOUND-FILTER
Router(config-ext-nacl)# remark Deny ICMP Time Exceeded leaving untrusted perimeter
Router(config-ext-nacl)# deny icmp any any time-exceeded
Router(config-ext-nacl)# remark Permit Path MTU Discovery (Fragmentation Needed)
Router(config-ext-nacl)# permit icmp any any packet-too-big
Router(config-ext-nacl)# permit icmp any any unreachable
Router(config-ext-nacl)# remark Permit all other transit traffic
Router(config-ext-nacl)# permit ip any any
Router(config-ext-nacl)# exit

Step 3: Filter incoming traceroute probes on the perimeter interface

To prevent the router from processing traceroute probes directed at its own interfaces or passing to hosts behind it, configure an ingress access list:

Router(config)# ip access-list extended ACL-INBOUND-HARDEN
Router(config-ext-nacl)# remark Drop UDP traceroute probes
Router(config-ext-nacl)# deny udp any any range 33434 33534
Router(config-ext-nacl)# remark Drop Windows ICMP traceroute probes to router IP
Router(config-ext-nacl)# deny icmp any any echo
Router(config-ext-nacl)# remark Permit standard transit traffic
Router(config-ext-nacl)# permit ip any any
Router(config-ext-nacl)# exit

Step 4: Apply the access lists to the external interface

Navigate to the internet- or WAN-facing interface and bind both access lists:

Router(config)# interface GigabitEthernet0/0/0
Router(config-if)# ip access-group ACL-INBOUND-HARDEN in
Router(config-if)# ip access-group ACL-OUTBOUND-FILTER out
Router(config-if)# exit

Step 5: Implement safe unreachable suppression

If you want to prevent final-hop UDP port responses on secondary interfaces, do not apply no ip unreachables globally or on interfaces facing paths with variable MTUs. To selectively suppress destination unreachable messages without dropping PMTUD (Type 3, Code 4), use the global rate-limiting engine to throttle generic unreachables while preserving DF (Don’t Fragment) notifications:

Router(config)# ip icmp rate-limit unreachable 100000
Router(config)# ip icmp rate-limit unreachable df 100
Router(config)# end
Router# write memory

Step 6: Verify filter operation

From an external host, initiate a traceroute targeting a node on or past the router. Intermediate hops running this configuration will output * * *, confirming the suppression of Type 11 datagrams. Verify hits on your access list via privileged EXEC mode:

Router# show ip access-lists ACL-OUTBOUND-FILTER
Extended IP access list ACL-OUTBOUND-FILTER
    10 deny icmp any any time-exceeded (12 matches)
    20 permit icmp any any packet-too-big
    30 permit icmp any any unreachable
    40 permit ip any any (142082 matches)

Hiding Backbone Topology: Suppressing Traceroute Across Cisco MPLS Networks

In Multi-Protocol Label Switching (MPLS) backbones, service providers frequently isolate internal Provider (P) routers from customer visibility. Unlike standard IP routing, MPLS provides native commands to make the entire core network appear as a single direct hop.

[ Customer CE1 ] ---> [ Ingress PE ] === ( P1 --- P2 --- P3 ) ===> [ Egress PE ] ---> [ Customer CE2 ]
                      [ MPLS Label ]     Core Hops Hidden           [ Label Popped ]
                      [ TTL = 255  ]     Never Decrement to 0       [ IP TTL = -1  ]

Step 1: Understand default MPLS TTL copying

By default, when an ingress Label Edge Router (PE / LER) imposes an MPLS label onto an incoming IP packet, it copies the IP header’s TTL value directly into the TTL field of the MPLS label header.

As the labeled frame traverses intermediate Provider (P) routers within the core, each P-router decrements the label’s TTL. If a customer executes a traceroute, the label TTL eventually expires on a P-router, causing the P-router to return an ICMP Type 11 message. This exposes internal provider IP addresses, loopbacks, and Multi-Protocol BGP next-hop infrastructures.

Step 2: Implement “no mpls ip propagate-ttl” on the Ingress PE

To break traceroute through the core, configure the ingress edge routers to disable TTL propagation. This forces the router to push a static TTL value of 255 into the MPLS label stack instead of copying the IP packet’s real TTL.

Log in to the Label Edge Router (PE) and disable TTL propagation globally:

PE-Router(config)# no mpls ip propagate-ttl

When this is active, core P-routers decrement the label’s TTL starting from 255. Because the label TTL never drops to 0 inside the core, internal P-routers never generate ICMP Time Exceeded messages. When the egress PE router receives the frame, it pops the label and decrements the original customer IP packet’s TTL by only 1 before handing it to the destination Customer Edge (CE) device.

Step 3: Configure propagation scope using “forwarded” vs. “local”

If network operators still need the ability to troubleshoot core P-routers from internal management systems, use the optional keywords rather than disabling propagation universally:

  • Forwarded Traffic Only: Prevents customer/transit traffic from mapping the core, while allowing engineering teams on the PE to run traceroutes through the core:
    text
    PE-Router(config)# no mpls ip propagate-ttl forwarded
  • Local Traffic Only: Conceals core hops exclusively for traceroutes initiated locally on the PE router, while allowing transit customer packets to see normal hops:
    text
    PE-Router(config)# no mpls ip propagate-ttl local

Step 4: Validate MPLS traceroute suppression

Run a traceroute from customer device CE1 to CE2 across the MPLS cloud.

  • Before configuration (Default MPLS):
    text
    CE1# traceroute 192.168.20.1
    1 10.1.1.1 (Ingress PE) 4 ms 2 ms 2 ms
    2 172.16.1.1 [MPLS: Labels 104/18 Exp 0] 12 ms 11 ms 10 ms
    3 172.16.2.2 [MPLS: Labels 108/18 Exp 0] 14 ms 12 ms 12 ms
    4 10.2.2.1 (Egress PE) 15 ms 15 ms 14 ms
    5 192.168.20.1 (CE2) 16 ms 16 ms 15 ms
  • After applying no mpls ip propagate-ttl forwarded:
    text
    CE1# traceroute 192.168.20.1
    1 10.1.1.1 (Ingress PE) 2 ms 2 ms 2 ms
    2 10.2.2.1 (Egress PE) 14 ms 13 ms 13 ms
    3 192.168.20.1 (CE2) 15 ms 15 ms 15 ms

    The entire internal topology—including core link IP addresses and label switching information—is collapsed into a single transparent hop between the edge routers.

Production-Ready Cisco IOS Configuration Templates

These configuration scripts provide drop-in configurations for enterprise edge routers and service provider environments.

Template 1: Perimeter Outbound ICMP Suppression (IPv4 Extended ACL)

! ================================================================
! Cisco IOS/IOS-XE Outbound Filtering Template for Traceroute Hiding
! ================================================================
configure terminal
!
ip access-list extended ACL-EDGE-EGRESS
 remark -----------------------------------------------------------
 remark Block ICMP Time-Exceeded to prevent transit hop exposure
 remark -----------------------------------------------------------
 deny icmp any any time-exceeded
 !
 remark -----------------------------------------------------------
 remark CRITICAL: Explicitly allow Path MTU Discovery to function
 remark -----------------------------------------------------------
 permit icmp any any packet-too-big
 permit icmp any any unreachable
 !
 remark -----------------------------------------------------------
 remark Permit standard business and transit traffic
 remark -----------------------------------------------------------
 permit ip any any
exit
!
interface GigabitEthernet0/0/0
 description External-WAN-Interface
 ip access-group ACL-EDGE-EGRESS out
exit
!
end
write memory

Template 2: Inbound Probe Elimination Template (IPv4 & IPv6 Dual-Stack)

! ================================================================
! Dual-Stack Inbound Probe Silencing (Drops Probes Before Ingestion)
! ================================================================
configure terminal
!
ip access-list extended ACL-EDGE-INGRESS-V4
 remark Drop standard UDP traceroute probes (Linux/Unix/Cisco)
 deny udp any any range 33434 33534
 remark Drop ICMP Echo Probes targeted at router interfaces (Windows)
 deny icmp any any echo
 permit ip any any
exit
!
ipv6 access-list ACL-EDGE-INGRESS-V6
 remark Drop IPv6 UDP traceroute probes
 deny udp any any range 33434 33534
 remark Drop ICMPv6 Echo Requests
 deny icmp any any echo-request
 remark Permit Neighbor Discovery and essential ICMPv6 control messages
 permit icmp any any nd-na
 permit icmp any any nd-ns
 permit icmp any any router-solicitation
 permit icmp any any router-advertisement
 permit ipv6 any any
exit
!
interface GigabitEthernet0/0/0
 ip access-group ACL-EDGE-INGRESS-V4 in
 ipv6 traffic-filter ACL-EDGE-INGRESS-V6 in
exit
!
end
write memory

Template 3: Carrier MPLS Backbone Topology Obfuscation

! ================================================================
! Service Provider Core Hiding Template (Apply on all PE Routers)
! ================================================================
configure terminal
!
! Disable TTL copy for customer/transit packets entering the LSP
no mpls ip propagate-ttl forwarded
!
! Rate-limit general unreachables; isolate DF unreachables for stability
ip icmp rate-limit unreachable 100000
ip icmp rate-limit unreachable df 100
!
end
write memory

Cisco IOS Command Reference: ICMP and TTL Control Directives

This reference documents the Cisco IOS commands controlling ICMP error transmission and TTL behavior.

ip unreachables

  • Syntax: [no] ip unreachables
  • Command Mode: Interface configuration mode (config-if)
  • Default Value: Enabled (ip unreachables is active by default on all IP interfaces)
  • Parameter Descriptions:
  • no: Disables the generation of ICMP Destination Unreachable messages (Type 3) on the interface.
  • Usage Guidelines:
    When disabled, the router silently drops packets that cannot be delivered rather than notifying the sender. Caution: This command suppresses all ICMP Type 3 codes, including Code 4 (“Fragmentation needed and DF set”). Suppressing Code 4 prevents TCP Path MTU Discovery from calculating optimal segment sizes, causing large packets to be discarded without error messages. This command does not stop ICMP Type 11 (Time Exceeded) messages generated by transit TTL expirations.

ip icmp rate-limit unreachable

  • Syntax: ip icmp rate-limit unreachable [df] [ms] [log [packets] [interval-ms]]
  • Command Mode: Global configuration mode (config)
  • Default Value: Rate limiting enabled at 500 milliseconds (one message allowed every 500 ms).
  • Parameter Descriptions:
  • df: (Optional) Configures the rate-limiting interval specifically for Don’t Fragment (DF) ICMP Code 4 messages used by PMTUD.
  • ms: Specifies the interval in milliseconds between generated unreachable messages (range: 1 to 4294967295).
  • log: (Optional) Configures logging thresholds for dropped ICMP unreachable packets.
  • Usage Guidelines:
    Protects the Route Processor from CPU saturation caused by high-volume scanning or denial-of-service attempts. Setting a long interval for general unreachables while keeping df at a low interval allows an administrator to silence network mapping utilities without impairing PMTUD.

mpls ip propagate-ttl

  • Syntax: mpls ip propagate-ttl | no mpls ip propagate-ttl [forwarded | local]
  • Command Mode: Global configuration mode (config)
  • Default Value: Enabled (IP TTL is copied directly to and from the MPLS label header).
  • Parameter Descriptions:
  • forwarded: (Optional) Disables TTL propagation only for routed/forwarded customer datagrams entering the LSP.
  • local: (Optional) Disables TTL propagation only for datagrams generated locally by the router itself.
  • Usage Guidelines:
    Executed on Label Edge Routers (PE devices). When negated (no), the ingress PE writes an initial TTL of 255 into the outermost MPLS label instead of copying the inner IP packet’s TTL. The egress PE discards the label TTL upon popping and decrements the original IP TTL by 1. This conceals all intermediate MPLS P-routers from customer traceroute utilities.

ip access-group

  • Syntax: ip access-group {access-list-number | access-list-name} {in | out}
  • Command Mode: Interface configuration mode (config-if)
  • Default Value: No access list is bound to the interface by default.
  • Parameter Descriptions:
  • in: Filters packets arriving into the router on the specified interface.
  • out: Filters packets departing the router through the specified interface.
  • Usage Guidelines:
    To suppress ICMP Time Exceeded packets generated by the local control plane, the access list must be bound in the out direction on the egress interface facing the probe source. Inbound ACLs targeting port ranges or ICMP types drop incoming probes before they can be processed by the control plane.

Conclusion

Breaking traceroute on a Cisco router requires selecting the right mechanism for your specific network topology. Blindly applying interface-level commands like no ip unreachables creates operational risks without successfully hiding intermediate transit hops. For standard IP networks, the most effective approach is deploying an extended egress Access Control List to suppress ICMP Type 11 (Time Exceeded) messages while explicitly permitting PMTUD traffic. In service provider MPLS environments, the correct solution is using no mpls ip propagate-ttl forwarded to turn the entire provider core into an invisible, single-hop transit path without degrading customer performance. Balancing these controls helps network architects protect infrastructure topologies while preserving overall protocol stability.

Please follow and like us:
Last modified: November 16, 2026

Author

Comments

Write a Reply or Comment

Your email address will not be published.