Busybox httpd: sub directory config file
Roman Krüger
amdahl256 at googlemail.com
Thu Apr 2 14:22:25 UTC 2009
Hello,
I want to password-protect a directory using a config file.
It works with the main httpd.conf but not with a config file in a sub
directory of the web root dir.
I have a file /config/httpd.conf containing the following line:
/cgi-bin:admin:asdfgh
now I start httpd with the command line:
httpd -h /config/www -c /config/httpd.conf -r "Authentication"
Then it works. When I access a CGI on the webserver I get the login window.
But I want to change the password from a CGI. So I want to store the
config file in
/config/www/cgi-bin/
A comment in httpd.c says:
"If a sub directory contains a config file it is parsed and merged with
any existing settings as if it was appended to the original configuration."
So I moved /config/httpd.conf to /config/www/cgi-bin/
and create a new empty /config/httpd.conf
and killed and restarted http with the above command line.
But now it doesn't work. I can access it without beeing asked for the password
(yes, I have restarted my web browser).
What am I doing wrong?
Thanks for your help.
Roman
More information about the busybox
mailing list