⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 options.html

📁 嵌入式http源代码的文档资料
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<HTML>
<HEAD><TITLE>Configuration Options</TITLE></HEAD>
<BODY BGCOLOR="#99cc99">

<!--AD_START-->
<DIV ALIGN="center"><CENTER>
<A HREF="tppmsgs/msgs0.htm#1" tppabs="http://www.acme.com/resources/ads/acme.cgi"><IMG WIDTH=470 HEIGHT=88 SRC="acme1.gif" tppabs="http://www.acme.com/resources/ads/acme1.gif" BORDER=0></A>
</CENTER></DIV>
<HR>
<CENTER><DIV ALIGN="center">
<FONT SIZE="+2"><B><A HREF="tppmsgs/msgs0.htm#2" tppabs="http://www.acme.com/donate/">Donate $5 to help support ACME Labs</A></B></FONT>
</DIV></CENTER>
<HR>
<!--AD_END-->

<IMG ALIGN=RIGHT WIDTH=111 HEIGHT=64 SRC="anvil_thttpd.gif" tppabs="http://www.acme.com/software/thttpd/anvil_thttpd.gif">
<H3>Configuration Options</H3>

<P>
This is just an HTMLized version of config.h.

<UL>
<LI><A HREF="#CGI_PATTERN">CGI_PATTERN</A>
<LI><A HREF="#CGI_TIMELIMIT">CGI_TIMELIMIT</A>
<LI><A HREF="#IDLE_READ_TIMELIMIT">IDLE_READ_TIMELIMIT</A>
<LI><A HREF="#IDLE_SEND_TIMELIMIT">IDLE_SEND_TIMELIMIT</A>
<LI><A HREF="#LOG_FACILITY">LOG_FACILITY</A>
<LI><A HREF="#TILDE_MAP_1">TILDE_MAP_1</A> and <A HREF="#TILDE_MAP_2">TILDE_MAP_2</A>
<LI><A HREF="#AUTH_FILE">AUTH_FILE</A>
<LI><A HREF="#DEFAULT_CHARSET">DEFAULT_CHARSET</A>
<LI><A HREF="#SERVER_NAME">SERVER_NAME</A> and <A HREF="#SERVER_NAME_LIST">SERVER_NAME_LIST</A>
<LI><A HREF="#SHOW_SERVER_VERSION">SHOW_SERVER_VERSION</A>
<LI><A HREF="#ALWAYS_CHROOT">ALWAYS_CHROOT</A>
<LI><A HREF="#ALWAYS_VHOST">ALWAYS_VHOST</A>
<LI><A HREF="#VHOST_DIRLEVELS">VHOST_DIRLEVELS</A>
<LI><A HREF="#DEFAULT_USER">DEFAULT_USER</A>
<LI><A HREF="#USE_USER_DIR">USE_USER_DIR</A>
<LI><A HREF="#EXPLICIT_ERROR_PAGES">EXPLICIT_ERROR_PAGES</A>
<LI><A HREF="#ERR_DIR">ERR_DIR</A>
<LI><A HREF="#ERR_APPEND_SERVER_INFO">ERR_APPEND_SERVER_INFO</A>
<LI><A HREF="#CGI_NICE">CGI_NICE</A>
<LI><A HREF="#CGI_PATH">CGI_PATH</A>
<LI><A HREF="#CGI_LD_LIBRARY_PATH">CGI_LD_LIBRARY_PATH</A>
<LI><A HREF="#OCCASIONAL_TIME">OCCASIONAL_TIME</A>
<LI><A HREF="#STATS_TIME">STATS_TIME</A>
<LI><A HREF="#MIN_REAP_TIME">MIN_REAP_TIME</A> and <A HREF="#MAX_REAP_TIME">MAX_REAP_TIME</A>
<LI><A HREF="#CGI_BYTECOUNT">CGI_BYTECOUNT</A>
<LI><A HREF="#DEFAULT_PORT">DEFAULT_PORT</A>
<LI><A HREF="#INDEX_NAMES">INDEX_NAMES</A>
<LI><A HREF="#GENERATE_INDEXES">GENERATE_INDEXES</A>
<LI><A HREF="#LOG_UNKNOWN_HEADERS">LOG_UNKNOWN_HEADERS</A>
<LI><A HREF="#THROTTLE_TIME">THROTTLE_TIME</A>
<LI><A HREF="#LISTEN_BACKLOG">LISTEN_BACKLOG</A>
<LI><A HREF="#MAXTHROTTLENUMS">MAXTHROTTLENUMS</A>
<LI><A HREF="#SPARE_FDS">SPARE_FDS</A>
<LI><A HREF="#LINGER_TIME">LINGER_TIME</A>
<LI><A HREF="#MAX_LINKS">MAX_LINKS</A>
<LI><A HREF="#MIN_WOULDBLOCK_DELAY">MIN_WOULDBLOCK_DELAY</A>
</UL>

<HR>

<!--

<H4><A NAME="CC">CC</A></H4>
<P>
The C compiler to use.
Typical values are "cc" and "gcc".

<H4><A NAME="SYSVLIBS">SYSVLIBS</A></H4>
<P>
Uncomment this if you're running a SysV OS such as Solaris 2.x.

<H4><A NAME="CFLAGS">CFLAGS</A></H4>
<P>
The C flags to use.
Typical values are "-O" and "-g".

<H4><A NAME="LDFLAGS">LDFLAGS</A></H4>
<P>
The linker flags to use.
Typical values are "-s" and "-g".

<H4><A NAME="STATICFLAG">STATICFLAG</A></H4>
<P>
CGI programs should be statically linked, so that you don't
have to bother with copying in shared libraries when setting up a
chroot() tree.  Uncomment the correct flag for your compiler.
Typical values are "-static" and "-Bstatic".

<H4><A NAME="BINDIR">BINDIR</A></H4>
<P>
Directory for public executables.
A typical value is "/usr/local/bin".

<H4><A NAME="ETCDIR">ETCDIR</A></H4>
<P>
Directory for daemon executable.
A typical value is "/usr/local/sbin".

<H4><A NAME="WEBDIR">WEBDIR</A></H4>
<P>
Directory tree that thttpd will run in.  This is so that the
makeweb program can know what directory to make subdirs in.  It also
affects the <A HREF="#CGIBINDIR">CGIBINDIR</A> definition below.
A typical value is "/usr/etc/www".

<H4><A NAME="WEBGROUP">WEBGROUP</A></H4>
<P>
The group that the web directory belongs to.  This is so that
the makeweb program can be installed set-group-id to that group, and make
subdirectories.  If you're not going to use makeweb, ignore this.
A typical value is "www".

<H4><A NAME="CGIBINDIR">CGIBINDIR</A></H4>
<P>
Directory for CGI executables.
A typical value is "$(<A HREF="#WEBDIR">WEBDIR</A>)/cgi-bin".

<H4><A NAME="MANDIR">MANDIR</A></H4>
<P>
Directory tree for man pages.
A typical value is "/usr/local/man".

<HR>

-->

<H4><A NAME="CGI_PATTERN">CGI_PATTERN</A></H4>
<P>
CGI programs must match this pattern to get executed.  It's
a simple shell-style filename pattern, with ? and *, or multiple such
patterns separated by |.  The patterns get checked against the filename
part of the incoming URL.
<P>
Restricting CGI programs to a single directory lets the site administrator
review them for security holes, and is strongly recommended.  If there
are individual users that you trust, you can enable their directories too.
<P>
You can also specify a CGI pattern on the command line, with the -c flag.
Such a pattern overrides this compiled-in default.
<P>
If no CGI pattern is specified, neither here nor on the command line,
then CGI programs cannot be run at all.  If you want to disable CGI
as a security measure that's how you do it, just don't define any
pattern here and don't run with the -c flag.
<P>
Some sample patterns.
<DL>
<DT> "/cgi-bin/*"
<DD>
Allow programs only in one central directory.
<DT> "/cgi-bin/*|/jef/**"
<DD>
Allow programs in a central directory, or anywhere in a trusted user's tree.
<DT> "**.cgi"
<DD>
Allow any program ending with a .cgi.
<DT> "/*/cgi-bin/*"
<DD>
When virtual hosting, enable the central directory on every host.
</DL>

<H4><A NAME="CGI_TIMELIMIT">CGI_TIMELIMIT</A></H4>
<P>
How many seconds to allow CGI programs to run before killing
them.  This is in case someone writes a CGI program that goes into an
infinite loop, or does a massive database lookup that would take hours,
or whatever.  If you don't want any limit, comment this out, but that's
probably a really bad idea.
<P>
A typical value is 300.

<H4><A NAME="IDLE_READ_TIMELIMIT">IDLE_READ_TIMELIMIT</A></H4>
<P>
How many seconds to allow for reading the initial request
on a new connection.
A typical value is 300.

<H4><A NAME="IDLE_SEND_TIMELIMIT">IDLE_SEND_TIMELIMIT</A></H4>
<P>
How many seconds before an idle connection gets closed.
A typical value is 300.

<H4><A NAME="LOG_FACILITY">LOG_FACILITY</A></H4>
<P>
The syslog facility to use.  Using this you can set up your
syslog.conf so that all thttpd messages go into a separate file.
Note that even if you use the -l command line flag to send logging to a
file, errors still get sent via syslog.
A typical value is LOG_DAEMON.

<H4><A NAME="TILDE_MAP_1">TILDE_MAP_1</A> and <A NAME="TILDE_MAP_2">TILDE_MAP_2</A></H4>
<P>
Tilde mapping.  Many URLs use ~username to indicate a
user's home directory.  thttpd provides two options for mapping
this construct to an actual filename.
<P>
1) Map ~username to &lt;prefix&gt;/username.  This is the recommended choice.
Each user gets a subdirectory in the main chrootable web tree, and
the tilde construct points there.  The prefix could be something
like "users", or it could be empty.  See also the makeweb program
for letting users create their own web subdirectories.
<P>
2) Map ~username to &lt;user's homedir&gt;/&lt;postfix&gt;.  The postfix would be
the name of a subdirectory off of the user's actual home dir, something
like "public_html".  This is what NCSA and other servers do.  The problem
is, you can't do this and chroot() at the same time, so it's inherently
a security hole.  This is strongly dis-recommended, but it's here because
some people really want it.  Use at your own risk.
<P>
You can also leave both options undefined, and thttpd will not do
anything special about tildes.  Enabling both options is an error.
<P>
Typical values, if they're defined, are "users" for TILDE_MAP_1
and "public_html" for TILDE_MAP_2.

<H4><A NAME="AUTH_FILE">AUTH_FILE</A></H4>
<P>
The file to use for authentication.  If this is defined then
thttpd checks for this file in the local directory before every fetch.
If the file exists then authentication is done, otherwise the fetch

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -