httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "S. Levent Yilmaz" <leventyil...@gmail.com>
Subject Re: [users@httpd] per location group based authentication
Date Wed, 13 Jul 2011 22:21:17 GMT
Hi again,

Apologies for the double post. The question was to set  "Require group
<group-name>" for a dynamically set group-name, based on directory/location
where the Require is specified.  One potential answer was to set an
(environment?) variable via mod_rewrite.  That is possible of course, but it
seems that using variables with Require directive is not possible.

I appreciate any guidance on this,

Thank you!
- Levent


On Fri, Jul 8, 2011 at 1:39 AM, S. Levent Yilmaz <leventyilmaz@gmail.com>wrote:

> Thanks for the response. That seems doable, however, I wasn't able to
> figure out how to use  an (environment) variable with Require
> directive?  I couldn't tell that from the docs
> http://httpd.apache.org/docs/current/en/env.html that this is in fact
> possible; and if it is, how to reference the variable.
>
>
>
>
> On Thu, Jul 7, 2011 at 8:48 PM, Igor Cicimov <icicimov@gmail.com> wrote:
> > Have you tried setting a variable and use it as group name? Have a look
> at
> > SetEnvIf and RewriteRule options for setting variables.
> >
> > Igor
> >
> > On Fri, Jul 8, 2011 at 2:11 AM, S. Levent Yilmaz <leventyilmaz@gmail.com
> >
> > wrote:
> >>
> >> Hi all,
> >>
> >> I am trying to setup URI based authentication, and am not sure if this
> >> is doable. Currently, manually set permissions look like (omitting all
> >> non-pertinent config details):
> >>
> >> <Location /git/foo>
> >>  Require group foo
> >> </Location>
> >>
> >> <Location /git/bar>
> >>  Require group bar
> >> </Location>
> >>
> >> ...
> >>
> >> Is there anyway to do this automatically, where the group name is
> >> derived from the URI somehow?
> >>
> >> Let me provide some more details in order to explain the context
> >> better.  I am trying to setup a simple CGI  based Git service over
> >> http.  The question as you can see is not about Git at all, and
> >> therefore could be relevant to any other CGI based service or similar.
> >> Git server setup looks like:
> >>
> >> ScriptAlias /git/   /usr/lib/git-core/git-http-backend/
> >> <Location /git/>
> >>   SetEnv GIT_PROJECT_ROOT /var/www/git
> >>   # authentication settings
> >> </Location>
> >>
> >> where, each request in the form "http://myserver.com/git/foo" or
> >> "http://myserver.com/git/bar" is handled by git-http-backend to serve
> >> the git repositories "/var/www/git/foo" and "/var/www/git/bar",
> >> respectively.  I ran into this road block of setting up authentication
> >> per repository basis. Hence the question.
> >>
> >> Thank you very much!
> >>
> >> - Levent
> >>
> >> ---------------------------------------------------------------------
> >> The official User-To-User support forum of the Apache HTTP Server
> Project.
> >> See <URL:http://httpd.apache.org/userslist.html> for more info.
> >> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> >>   "   from the digest: users-digest-unsubscribe@httpd.apache.org
> >> For additional commands, e-mail: users-help@httpd.apache.org
> >>
> >
> >
>
>

Mime
View raw message