www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <>
Subject config/131: http_request.c: directory_walk() misses some <Directory ...> directives
Date Mon, 27 Jan 1997 21:40:01 GMT

	The contract type is `' with a response time of 3 business hours.
	A first analysis should be sent before: Mon Jan 27 17:00:01 PST 1997


>Number:         131
>Category:       config
>Synopsis:       http_request.c: directory_walk() misses some <Directory ...> directives
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    gnats-admin (GNATS administrator)
>State:          open
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Mon Jan 27 13:40:01 1997
>Originator:     
>Organization:
apache
>Release:        
>Environment:
N/a	
>Description:
I constructed a access.conf which had two <Directory> directives for the same
path, http_request.c: directory_walk() silently ignores the first!

This caused much confusion.
>How-To-Repeat:
<Directory /a/b/c>
<Limit GET POST>
require valid-user
</Limit>
</Directory>

and later in access.conf


<Directory /a/b/c>
AllowOverride None
Options None
</Directory>
>Fix:
In directory_walk(), I think the 'this_conf' test in the second for loop should
be inside the for loop.

If there is some subtle reason why multiple <Directory> sections are not allowed
please, please, can we have a warning message!
diff -C 5 http_request.c /home1/mendel/Xjproxy/site/httpd/apache/src 
*** http_request.c      Mon Jan 27 21:18:50 1997
--- /home1/mendel/Xjproxy/site/httpd/apache/src/http_request.c  Tue Dec 24 18:06:16 1996
***************
*** 328,347 ****
                sec[j] = NULL;
                this_conf = entry_config;
            }
            else if (!strcmp (this_dir, entry_dir))
                this_conf = entry_config;
  
!           if (this_conf)
!           {
!               per_dir_defaults =
!                   merge_per_dir_configs (r->pool, per_dir_defaults, this_conf);
!               core_dir =(core_dir_config *)get_module_config(per_dir_defaults,
                                               &core_module);
-           }
        }
- 
        overrides_here = core_dir->override;
  
        /* If .htaccess files are enabled, check for one.
         */
  
--- 328,346 ----
                sec[j] = NULL;
                this_conf = entry_config;
            }
            else if (!strcmp (this_dir, entry_dir))
                this_conf = entry_config;
+       }
  
!       if (this_conf)
!       {
!           per_dir_defaults =
!               merge_per_dir_configs (r->pool, per_dir_defaults, this_conf);
!           core_dir =(core_dir_config *)get_module_config(per_dir_defaults,
                                                           &core_module);
        }
        overrides_here = core_dir->override;
  
        /* If .htaccess files are enabled, check for one.
         */
  

%0
>Audit-Trail:
>Unformatted:



Mime
View raw message