[users@httpd] Authentication between multiple virtual hosts

2016-08-19 Thread Joseph L. Casale
I have a couple sites protected with mod_ldap, the first site emits urls
with query parameters pointing  to the second site. Of course by default
if you have authenticated to both sites this works however that is not the
most convenient as access to the first site is usually what is of interest.

Given both virtual hosts reside on the same apache instance, what options
do I have facilitate sso within the first site so the above scenario works
without first authenticating to the second site?

The first site is a vanilla php app whereas the second site is unfortunately
a python wsgi application.

Thanks,
jlc

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] RewriteCond: backreferences in TestString

2016-08-19 Thread Eric Covener
> something like this:
> RewriteCond /patch/ver(70) -f
> RewriteRule ^([^?]*)\.php(.*)$ http://127.0.0.1:100%1%{REQUEST_URI} [NC,L,P]

That's valid, but it doesn't exactly match the subject of the email
(which would not work)

-- 
Eric Covener
cove...@gmail.com

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



[users@httpd] RewriteCond: backreferences in TestString

2016-08-19 Thread Alexey Vlasov
Hi,

I oo dynamically switch PHP versions but it turns out too many rules.
Can it somehow easier?

## PHP 5.2
RewriteCond /patch/ver52 -f
RewriteRule ^([^?]*)\.php(.*)$ http://127.0.0.1:10052%{REQUEST_URI} [NC,L,P]
...
## PHP 5.6
RewriteCond /patch/ver56 -f
RewriteRule ^([^?]*)\.php(.*)$ http://127.0.0.1:10056%{REQUEST_URI} [NC,L,P]

## PHP 7.0
RewriteCond /patch/ver70 -f
RewriteRule ^([^?]*)\.php(.*)$ http://127.0.0.1:10070%{REQUEST_URI} [NC,L,P]

For example, to PHP version of the flag file are substituted in the port
number?

something like this:
RewriteCond /patch/ver(70) -f
RewriteRule ^([^?]*)\.php(.*)$ http://127.0.0.1:100%1%{REQUEST_URI} [NC,L,P]

thanks

-
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org



Re: [users@httpd] 404 rewrite error using special character \

2016-08-19 Thread Marat Khalili
What about trying:

RewriteRule ^\# \%2523 [R,L,NE]

? (Not sure if NE is necessary, but it won't hurt.) Let's break the system!

BTW I don't think using # as part of the request path is a good idea, since 
browsers, libraries and proxies may treat it as fragment delimiter and behave 
accordingly (for instance, fail to reload page on just fragment change).
-- 

With Best Regards,
Marat Khalili

On August 19, 2016 8:20:28 AM GMT+03:00, elliott sterling 
 wrote:
> 
> 
>I learned that the error was that it was looking for folder or
>directory "/#".So after I created that folder I get endless
>redirect loop. So I am researching how to fix that.   
> 
> 
> 
>
> 
> 
>>  
>> On Aug 19, 2016 at 12:45 AM,  (mailto:icici...@gmail.com)>  wrote:
>>  
>>  
>>  
>>
>>  
>>
>>  
>> On Fri, Aug 19, 2016 at 12:16 PM (x-apple-data-detectors://1),
>elliott sterling  (mailto:elliottlsterl...@gmail.com)>  wrote:
>>  
>> >  Hello,
>> >  
>> >  My project for this client is such that his directories contain
>"#" in
>> >  the folder names, #test, and other symbols.The '#' is the only
>one
>> >  that gives me problems because I know its a anchor and htacess
>ignores
>> >  it.My rewrite code is:
>> >  
>> >  RewriteRule [^\#] \%23
>>  
>>
>>  
>> Try adding NE flag at the end:
>>  
>>  RewriteRule ^\# \%23 [R,L,NE]
>>  
>>  
>> >  
>> >  My goal was to convert the '#' to %23 because it works as
>> >   example.com/%23test/test.html
>(http://example.com/%23test/test.html)  but not as 
>example.com/#test/test.html (http://example.com/#test/test.html).
>> >  The error is get is:
>> >  
>> >  The requested URL /# was not found on this server.
>> >  
>> >  So I am on the write track as when i try ^# %23 the # is ignore or
>> >  other variations give me 500 error.Thanks for any help.
>> >  
>> > 
>-
>> >  To unsubscribe, e-mail:  users-unsubscr...@httpd.apache.org
>(mailto:users-unsubscr...@httpd.apache.org)
>> >  For additional commands, e-mail:  users-h...@httpd.apache.org
>(mailto:users-h...@httpd.apache.org)
>> >  
>>
>>