[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

=?ISO-8859-1?Q?Re: =C7=EB=C8=C3=CE=D2=BF=B4=C4=E3=B5=C4httpd.conf =BA=C3=C2=F0?????=



irene shaw,你好!
try:
#
# Control access to UserDir directories.  The following is an example
# for a site where these directories are restricted to read-only.
#
<Directory /usr/home/*/www>
    AllowOverride FileInfo AuthConfig Limit All
    Options MultiViews SymLinksIfOwnerMatch IncludesNoExec
    <Limit GET POST OPTIONS PROPFIND>
        Order allow,deny
        Allow from all
    </Limit>
    <Limit PUT DELETE PATCH PROPPATCH MKCOL COPY MOVE LOCK UNLOCK>
        Order deny,allow
        Deny from all
    </Limit>
</Directory>

<Directory /usr/home/*/cgi-bin>
    AllowOverride FileInfo AuthConfig Limit
    Options ExecCGI
</Directory>

NameVirtualHost 1.1.1.1

<VirtualHost 1.1.1.1>

RewriteEngine on
RewriteLog   "/var/www/logs/rewrite.log"
RewriteLogLevel 0

RewriteMap   lowercase  int:tolower

RewriteMap   vhost      dbm:/var/www/conf/vhost

RewriteCond  ${lowercase:%{SERVER_NAME}}  ^(.+)$
RewriteCond  ${vhost:%1}                  ^.*;(.+);.*;.*;red;.*
RewriteRule  ^/.*$                        http://%1 [R,L]
RewriteCond  %{REQUEST_URI}               ^/$
RewriteCond  ${lowercase:%{SERVER_NAME}}  ^(.+)$
RewriteCond  ${vhost:%1}                  ^.*;.*;www;.*;.*;ad$
RewriteRule  ^/.*$                        /var/www/cgi-bin/ad.cgi  [T=application/x-httpd-cgi,E=WEBPAGE:/index.htm,L]

RewriteCond  %{REQUEST_URI}               !^/cgi-bin/
RewriteCond  ${lowercase:%{SERVER_NAME}}  ^(.+)$
RewriteCond  ${vhost:%1}                  ^(.+);.*;www;.*
RewriteRule  ^/(.*)$                      /usr/home/%1/www/$1

RewriteCond  %{REQUEST_URI}               ^/cgi-bin/
RewriteCond  ${lowercase:%{SERVER_NAME}}  ^(.+)$
RewriteCond  ${vhost:%1}                  ^(.+);.*;www;cgi;;
RewriteRule  ^/cgi-bin/(.*)$              /usr/home/%1/cgi-bin/$1 [T=application/x-httpd-cgi]

</VirtualHost>
                        <VirtualHost 1.1.1.1>
                            ServerAdmin webmaster@domain.com
                            DocumentRoot /usr/home/user1/www
                            ServerName www.domain.com
                            ServerAlias domain.com
                            ErrorLog /usr/home/user1/wwwlogs/error_log
                            TransferLog /usr/home/user1/wwwlogs/access_log
                            ScriptAlias /cgi-bin/ /usr/home/user1/cgi-bin/
                        </VirtualHost>

在 01-1-2 下午 06:15:00 您寫道:
> 我想設 每個user home下的cgi-bin目錄  ...
>  我己經嘗試了很多方法, 但都不行 ....
>
>  例如 :
>
>  ScriptAliasMatch ^/~([^/]*)/cgi-bin/(.*) /home/$1/cgi-bin/$2
>
>  <direcory ~ "/home/*/www/cgi-bin">
>  Options ExecCGI
>  AddHandler cgi-script .cgi .sh .pl
>  AllowOverride None
>  AllowFrom all
>  </directory>
>
>  都還是不行 ... 有沒有人成功的在debian的apache上設定每個user home 的
>
>  cgi-bin ??? 可以把你的httpd.conf post 出來, 或是寄給我嗎 ???
>
>  感激不盡 ... 我己經設了一天了......
>
>--------------------------------------------------------------------
>奇摩電子信箱﹒溝通心世界  http://mail.kimo.com.tw
>< 你 今 天 KIMO 了 嗎? >  http://www.kimo.com.tw
>
>--
>| This message was re-posted from debian-chinese-big5@lists.debian.org
>| and converted from big5 to gb2312 by an automatic gateway.
>
>
>--
>To UNSUBSCRIBE, email to debian-chinese-gb-request@lists.debian.org
>with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

                    致
禮!

            wgj
            wgj@joyosoft.com

--
To UNSUBSCRIBE, email to debian-chinese-gb-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

-- 
| This message was re-posted from debian-chinese-gb@lists.debian.org
| and converted from gb2312 to big5 by an automatic gateway.



Reply to: