Ticket #846 (new defect)

Opened 2 years ago

Last modified 9 months ago

SO_ACCEPTFILTER Doesn't Do What It Says

Reported by: c0nsumer@… Owned by: jan
Priority: normal Milestone:
Component: core Version: 1.4.11
Severity: normal Keywords:
Cc: Blocked By:
Need User Feedback: no Blocking:

Description

I've compiled lighty with -DSO_ACCEPTFILTER as appears to be required (http://trac.lighttpd.net/trac/browser/trunk/src/network.c#L250) yet in testing it doesn't appear to work.

To confirm, here's the output from make:

if cc -DHAVE_CONFIG_H -DLIBRARY_DIR="\"/usr/local/lib/lighttpd\"" -I. -I. -I.. -D_REENTRANT -DEXTENSIONS -I/usr/include -DOPENSSL_NO_KRB5 -I/usr/local/include -D_FIL E_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES -O -pipe -march=pentium3 -I/usr/local/include -DSO_ACCEPTFILTER -Wall -W -Wshadow -pedantic -MT network.o -MD -MP -MF " .deps/network.Tpo" -c -o network.o network.c; then mv -f ".deps/network.Tpo" ".deps/network.Po"; else rm -f ".deps/network.Tpo"; exit 1; fiM rm -f configparser.hM

Running strings against the resulting binary gives me a hint that this support should now be included:

root@rowla:/usr/local/sbin# strings lighttpd | grep filter can't set accept-filter 'httpready': root@rowla:/usr/local/sbin#

However, testing has shown that connections are handed directly to lighty. This testing was done by telnetting to port 80 on the device running the aforementioned lighttpd binary and noticing that it immediately appears in netstat. Additionally, it is possible to run lighty without accf_http.ko loaded nor compiled in the kernel, which shows me that it's not actually being used.

Am I doing something wrong here, or is this a bug?

Attachments

Change History

Changed 9 months ago by Olaf van der Spek

  • pending unset

and noticing that it immediately appears in netstat.

Why would it not appear in netstat?

Additionally, it is possible to run lighty without accf_http.ko loaded nor compiled in the kernel, which shows me that it's not actually being used.

Lighty ignores a failure to set the accept filter.

To verify this you'd need to use strace.

Add/Change #846 (SO_ACCEPTFILTER Doesn't Do What It Says)

Author



Change Properties
<Author field>
Action
as new
 
Note: See TracTickets for help on using tickets.