Ticket #7277: apache2.diff

File apache2.diff, 3.2 KB (added by ryandesign (Ryan Carsten Schmidt), 16 years ago)
  • files/patch-httpd.conf.in.diff

     
    1 --- docs/conf/httpd.conf.in.orig  2005-12-05 13:41:59.000000000 -0500
    2 +++ docs/conf/httpd.conf.in       2005-12-05 13:42:11.000000000 -0500
     1--- docs/conf/httpd.conf.in     2007-12-21 05:43:00.000000000 -0600
     2+++ docs/conf/httpd.conf.in     2008-02-06 14:10:15.000000000 -0600
    33@@ -63,8 +63,8 @@
    44 # It is usually good practice to create a dedicated user and group for
    55 # running httpd, as with most system services.
     
    88-Group daemon
    99+User www
    1010+Group www
     11 
    1112 </IfModule>
    1213 </IfModule>
     14@@ -168,14 +168,24 @@
     15 </IfModule>
     16 
     17 #
     18-# The following lines prevent .htaccess and .htpasswd files from being
     19-# viewed by Web clients.
     20+# The following lines prevent .htaccess, .htpasswd and .DS_Store files and
     21+# Mac resource forks and named forks from being viewed by Web clients.
     22 #
     23-<FilesMatch "^\.ht">
     24+<Files ~ "^\.([Hh][Tt]|[Dd][Ss]_[Ss])">
     25     Order allow,deny
     26     Deny from all
     27     Satisfy All
     28-</FilesMatch>
     29+</Files>
     30+<Files "rsrc">
     31+    Order allow,deny
     32+    Deny from all
     33+    Satisfy All
     34+</Files>
     35+<DirectoryMatch ".*\.\.namedfork">
     36+    Order allow,deny
     37+    Deny from all
     38+    Satisfy All
     39+</DirectoryMatch>
     40 
     41 #
     42 # ErrorLog: The location of the error log file.
  • files/patch-httpd-userdir.conf.in.diff

     
     1--- docs/conf/extra/httpd-userdir.conf.in       2007-03-07 01:33:58.000000000 -0600
     2+++ docs/conf/extra/httpd-userdir.conf.in       2008-02-06 14:23:42.000000000 -0600
     3@@ -7,13 +7,13 @@
     4 # directory if a ~user request is received.  Note that you must also set
     5 # the default access control for these directories, as in the example below.
     6 #
     7-UserDir public_html
     8+UserDir Sites
     9 
     10 #
     11 # Control access to UserDir directories.  The following is an example
     12 # for a site where these directories are restricted to read-only.
     13 #
     14-<Directory "/home/*/public_html">
     15+<Directory "/Users/*/Sites">
     16     AllowOverride FileInfo AuthConfig Limit Indexes
     17     Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
     18     <Limit GET POST OPTIONS>
  • Portfile

     
    44
    55name             apache2
    66version          2.2.8
     7revision         1
    78
    89categories       www
    910maintainers      imajes@macports.org
     
    3132                 port:openssl \
    3233                 port:pcre
    3334
    34 post-patch {
    35     reinplace -E "s/(User|Group) daemon/\\1 www/" ${worksrcpath}/docs/conf/httpd.conf.in
    36 }
    37 
    3835platform darwin {
    39         post-patch {
    40                 # Customize userdir naming to match darwin
    41                 reinplace "s|/home/|/Users/|g" ${worksrcpath}/docs/conf/extra/httpd-userdir.conf.in
    42                 reinplace "s|public_html|Sites|g" ${worksrcpath}/docs/conf/extra/httpd-userdir.conf.in
    43         }
     36        patchfiles-append patch-httpd.conf.in.diff patch-httpd-userdir.conf.in.diff
    4437}
    4538
    4639platform darwin 7 {