httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject [users@httpd] DirectoryMatch - how to use the matched substring ?
Date Wed, 19 Jan 2005 19:49:36 GMT

	I am trying to implement a Webdisk-like service to the University where I work
using Apache + mod_dav + mod_auth_ldap. The basic part is all set, with the
authentication working and the DAV part too.

	The problem I am facing now is as follows:

	The regular expressions are not expanded (using $1, ...) when using
DirectoryMatch. As a way (the only one that I can see) to avoid using .htaccess
files, I would need to use regex expansion to make the Directory information in
httpd.conf generic/dynamic.
	The basic path can be seen as: /home/user/.
	The thing is, only the 'user' has permission to access his home, and there will
be some thousands of them..

	My idea is to use something like:

	<DirectoryMatch /home/([^/].*)/>

	require user $1


	But, $1 does not expand to the matched part of the regex (user). I tried to
search the archives, google, etc, but found nothing. Any ideas ?

	It does not seem feasible to use 1000 Directory entries, with its specific
"require user xxx" inside the httpd.conf file, and reload Apache each time a
user is added or removed. In that case, .htaccess seems better..
	If anyone has another solution (some magic module, maybe ?), I would like to

Thanks in advance.


The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message