On Mon, Nov 24, 2003 at 01:18:39PM -0500, Jefferson Ogata wrote:
> Guido van Rooij wrote:
> >On Fri, Nov 21, 2003 at 12:17:30AM +0530, Ram Chandar wrote:
> >>If the packet had been recognised by state code it wouldn't have
> >>encountered the Tender Loving Care of the Firewall code 
> >>for passing/blocking/logging/screaming.
> >>
> >>the "p" .. is caused by "pass in log quick on ppp0 proto icmp from any to 
> >>any"
> >>in my ipnat.conf. 
> >
> >True. I located the problem. See the attached diff.
> 
> With this patch, can someone disrupt TCP sessions using ICMP messages 
> without having to observe/predict sequence numbers? Not that it'd be a show 
> stopper either way. Just curious.

No. A correct TCP implementation should ignore ICMP errors once a session
is active. In case an ICMP error is sent in response to a sync, some
implementation actually process the icmp if it were an RST IIRC.

The reasons to ignore ICMP errors is that TCP should survice temporary
failures (e.g. host unreachables might point a routing problem that
can cause a route flip causing the host to be reachable again).

Hmm..I am not sure what happens if a TCP stack receives a
ICMP_UNREACH_FILTER_PROHIB.

After looking in FreeBSD's TCP stack it seems that, given
net.inet.tcp.icmp_may_rst == 1, and a ICMP_UNREACH_FILTER_PROHIB,
ICMP_UNREACH_NET_PROHIB, ICMP_UNREACH_HOST_PROHIB,
ICMP_UNREACH_PORT, ICMP_UNREACH_PROTOCOL  or ICMP_TIMXCEED is received,
the ICMP will be handled like an RST.

So, if you are concearned about this, set net.inet.tcp.icmp_may_rst to
0.

-Guido

Reply via email to