HomeFreeBSD

Immediately propagate EACCES error code to application from tcp_output.

Description

Immediately propagate EACCES error code to application from tcp_output.

In r309610 and r315514 the behavior of handling EACCES was changed, and
tcp_output() now returns zero when EACCES happens. The reason of this
change was a hesitation that applications that use TCP-MD5 will be
affected by changes in project/ipsec.

TCP-MD5 code returns EACCES when security assocition for given connection
is not configured. But the same error code can return pfil(9), and this
change has affected connections blocked by pfil(9). E.g. application
doesn't return immediately when SYN segment is blocked, instead it waits
when several tries will be failed.

Actually, for TCP-MD5 application it doesn't matter will it get EACCES
after first SYN, or after several tries. Security associtions must be
configured before initiating TCP connection.

I left the EACCES in the switch() to show that it has special handling.

Reported by: Andreas Longwitz <longwitz at incore dot de>
MFC after: 10 days

Details

Provenance
aeAuthored on
Parents
rS333243: opensolaris system_taskq does not need to run at maximum priority
Branches
Unknown
Tags
Unknown