Skip to content
Tom Barbette edited this page Oct 3, 2018 · 2 revisions

ICMPRewriter Element Documentation

NAME

ICMPRewriter — Click element; rewrites ICMP packets based on IP rewriter mappings

SYNOPSIS

ICMPRewriter(MAPS, keywords DST_ANNO)

Batching: Batching natively supported
Ports: 1 input, 1 or more outputs
Processing: push

DESCRIPTION

Rewrites ICMP error packets by changing their source and/or destination addresses and some of their payloads. It checks MAPS, a space-separated list of IPRewriter-like elements, to see how to rewrite. This lets source quenches, redirects, TTL-expired messages, and so forth pass through a NAT gateway.

ICMP error packets are sent in response to normal IP packets, and include a small portion of the relevant IP packet data. If the IP packet had been sent through IPRewriter, ICMPPingRewriter, or a similar element, then the ICMP packet will be in response to the rewritten address. ICMPRewriter takes such ICMP error packets and checks a list of IPRewriters for a relevant mapping. If a mapping is found, ICMPRewriter will rewrite the ICMP packet so it appears like a response to the original packet and emit the result on output 0.

ICMPRewriter may have one or two outputs. If it has one, then any non-rewritten ICMP error packets, and any ICMP packets that are not errors, are dropped. If it has two, then these kinds of packets are emitted on output 1.

Keyword arguments are:

  • DST_ANNO — Boolean. If true, then set the destination IP address annotation on passing packets to the rewritten destination address. Default is true.

NOTES

ICMPRewriter supports the following ICMP types: destination unreachable, time exceeded, parameter problem, source quench, and redirect.

MAPS elements may have element class IPAddrRewriter, IPRewriter, TCPRewriter, ICMPPingRewriter, or other related classes.

SEE ALSO

IPAddrRewriter, IPRewriter, ICMPPingRewriter, TCPRewriter

Generated by click-elem2man from ../elements/icmp/icmprewriter.hh:9 on 2018/10/03.

Clone this wiki locally