[EMAIL PROTECTED] detail for a rewrite

2005-12-11 Thread T F
My hosting service has my second domain name aliased to my single account.

For example, www.domain.net is aliased to www.domain.com

If a user points their browser to www.domain.com, then they are served www.domain.com/index.html

If the they point to www.domain.net, then they are served www.domain.net/o/index.html

In my .htaccess file, the following accomplishes this (but there is a glitch)

RewriteEngine on
RewriteCond %{HTTP_HOST} ^www\.domain\.net [NC]
RewriteRule ^$ http://www.domain.net/o/index.html [R]

If the user points to http://www.domain.net/o/ (with a trailing slash), then everything is fine.


But if they omit the trailing slash, then the url becomes (note the .com) http://www.domain.com/o/

I'd like for the url to remain .net. 

In fact, i'd like to devise a general solution, such that whenever any
document
in the the /o tree is requested, then the url will be rewritten to the
.net. For example if the user pointed
http://www.domain.com/o/file.html, then it would be rewritten to
http://www.domain.net/o/file.html

I've tried a number rewrite conditions and rules, and have consulted http://httpd.apache.org/docs/2.0/misc/rewriteguide.html

Any help would be greatly appreciated.

Thanks in advance,
Mike



RE: [EMAIL PROTECTED] PHP Prolem

2005-12-11 Thread Malka Cymbalista
I had a similar problem.  I added
   php_flag engine on 
to the appropriate Directory sections and since then all has been
well.  I must say that for a long time I never had any problems with php
but at some point every now and then (and it was not consistent) the
browser would display the php code instead of actually running it.  Ever
since I addedphp_flag engine on   to the config file, I have not had
the problem.
We are running apache 2.0.55 with mod_ssl 2.0.55, openSL 0.9.7g, php,
php 4.3.3, and mod_perl 2.0.1.
Hope this helps.
 
 [EMAIL PROTECTED] wrote on 12/9/2005 3:46 PM:
 I apologize for my ignorance but I still cannot make this work. Can 
 someone please offer specific direction on how to edit the .conf file

 to allow my appache server to properly display php files in
browsers?
  
 Thanks
 Todd
 
 
 
 From: myhapwcforever [mailto:[EMAIL PROTECTED] 
 Sent: Thu 12/8/2005 9:06 AM
 To: users@httpd.apache.org 
 Subject: Re: [EMAIL PROTECTED] PHP Prolem
 
 
 AddType application/x-httpd-php .php
 
 I met with your problem.And add it. ;)
  Original Message - 
 
   From: Todd Hofert mailto:[EMAIL PROTECTED]  
   To: users@httpd.apache.org 
   Sent: Thursday, December 08, 2005 8:57 PM
   Subject: RE: [EMAIL PROTECTED] PHP Prolem
 
   Where do I add this? I added it in the section that previously
read:

   IfModule mod_dir.c
   DirectoryIndex index.html 
   /IfModule

   Doing so now just opens the php file as text in the browser
window.

   Thanks in advance.
   Todd
 
 
 
   From: ludi [mailto:[EMAIL PROTECTED] 
   Sent: Wednesday, December 07, 2005 9:37 PM
   To: users@httpd.apache.org 
   Subject: Re: [EMAIL PROTECTED] PHP Prolem
   
   
   AddType application/x-httpd-php .php
   DirectoryIndex index.html index.html.var index.php
   Add to the httpd.conf
   
   
   2005/12/8, Todd Hofert [EMAIL PROTECTED]: 
 
   I just installed Apache 1.3 on local computer. I am now
trying to 
 install Zen-Cart and when I access the appropriate directory the
result 
 is a directory listing. The directions indicate that if you get a 
 directory listing you should speak to your Hosting Site about how to

 setup your server to auto-detect PHP filename extensions.
   
   So since I am the host, how do I configure Apache to
auto-detect PHP 
 filename extensions?
   
   Thanks
   Todd
   
   This e-mail and any attachments may contain confidential
and 
 privileged 
   information. If you are not the intended recipient,
please notify the
   sender immediately by return e-mail, delete this e-mail
and destroy 
 any
   copies. Any dissemination or use of this information by
a person 
 other 
   than the intended recipient is unauthorized and may be
illegal.
   


-
   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:
[EMAIL PROTECTED] 
 from the digest:
[EMAIL PROTECTED] 
   For additional commands, e-mail:
[EMAIL PROTECTED] 
   
   
 
 
   This e-mail and any attachments may contain confidential and 
 privileged information. If you are not the intended recipient, please

 notify the sender immediately by return e-mail, delete this e-mail
and 
 destroy any copies. Any dissemination or use of this information by a

 person other than the intended recipient is unauthorized and may be 
 illegal. 
 
   
 
 
 
 This e-mail and any attachments may contain confidential and
privileged
 information. If you are not the intended recipient, please notify
the
 sender immediately by return e-mail, delete this e-mail and destroy
any
 copies. Any dissemination or use of this information by a person
other
 than the intended recipient is unauthorized and may be illegal.


Malka Cymbalista
Webmaster, Weizmann Institute of Science
[EMAIL PROTECTED]
08-934-3036

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] How to hide http service?

2005-12-11 Thread myhapwcforever
You can use the reject . 
Or, you should bind the ipaddress on the 127.0.0.1.
- Original Message - 
From: Rich Bowen [EMAIL PROTECTED]
To: users@httpd.apache.org
Sent: Sunday, December 11, 2005 2:29 AM
Subject: Re: [EMAIL PROTECTED] How to hide http service?


 ludi wrote:
  Use the iptables
 
 Probably not a good idea, since the time that iptables gets reset, it 
 will be exposed. Better to just not listen on that interface.
 
  
  On 12/10/05, *w01F* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote:
  
  I want my Apache server to refuse all connections except localhost ,
  and make http service invisible to other machine in case to be hacked.
  
  Can anyon help me ? Thanks in advance!
  
  
  
  -
  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: [EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED]
from the digest: [EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  mailto:[EMAIL PROTECTED]
  
  
 
 
 -- 
 Rich Bowen
 [EMAIL PROTECTED]
 
 -
 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: [EMAIL PROTECTED]
   from the digest: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

Re: [EMAIL PROTECTED] Apache terminating child process

2005-12-11 Thread myhapwcforever
It was said that tomcate will shutdown if a lot of requires were received . But 
I'm not sure.
- Original Message - 
From: Prashant Hegde [EMAIL PROTECTED]
To: users@httpd.apache.org
Sent: Sunday, December 11, 2005 2:56 PM
Subject: [EMAIL PROTECTED] Apache terminating child process


Hello

I am using

Apache -ver
Server version: Apache/1.3.31 (Win32)
Server built:   Feb 16 2005 14:32:36


- We have a web based user interface which keeps refreshing using a
java script remote scripting call to the server every 30 seconds.
- We found that after a couple of hours ( no standard pattern) the
refreshing stops.
- After making sure we dont have any issues with our code,  we enabled
the logs on Tomcat and Apache. We found that the apache is receiving
master_main: Shutdown event signalled. Shutting the server down

- Later we found the following in the apache error log

forcing termination of child #0

- This forces the client to go blank. The refresh does not happen any more.

We could reproduce this problem by continuously pounding the server
with multiple HTTP requests.

I have the following questions, and appreciate any help in this regard,

a) Under what conditions does this happen. ?
b) Is there some tweaking that I can do in the configuration file,
which will prevent this kind
of behavior. There were two configuration items which were related to
thiskind of problem.

MaxRequestPerChild
MaxThreadsPerChild

Do we need to tune this?
c) Is there a some kind of a timeout that is kicking in to avoid some
denial of service attacks ?


Any help is greatly appreciated
Regards,
Prashant

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: [EMAIL PROTECTED] detail for a rewrite

2005-12-11 Thread Joshua Slive
On 12/11/05, T F [EMAIL PROTECTED] wrote:

  In my .htaccess file, the following accomplishes this (but there is a
 glitch)

  RewriteEngine on
  RewriteCond %{HTTP_HOST}   ^www\.domain\.net [NC]
  RewriteRule ^$   http://www.domain.net/o/index.html   [R]

  If the user points to http://www.domain.net/o/ (with a trailing slash),
 then everything is fine.

  But if they omit the trailing slash, then the url becomes (note the .com)
 http://www.domain.com/o/

Fixing the UseCanonicalName setting could probably fix that, but it
sounds like you can't access httpd.conf.


  I'd like for the url to remain .net.

  In fact, i'd like to devise a general solution, such that whenever any
 document in the the /o tree is requested, then the url will be rewritten to
 the .net.  For example if the user pointed
 http://www.domain.com/o/file.html, then it would be
 rewritten to http://www.domain.net/o/file.html

In the o/.htaccess:
 RewriteEngine on
 RewriteCond %{HTTP_HOST}   !^www\.domain\.net$ [NC]
 RewriteRule (.*)   http://www.domain.net/o/$1  [R]
(or something like that -- untested).

Joshua.

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[EMAIL PROTECTED] Problem setting up mod_alias for an external folder

2005-12-11 Thread Ken Tozier

Hi all

I'm a complete Apache noob and am having no luck getting an addition  
to the mod_alias section of my httpd.conf file working. I found and  
followed a tutorial here: http://www.macdevcenter.com/pub/a/mac/ 
2003/05/16/web_files.html but it didn't work.


Here's what I added to httpd.conf:

Alias /images/ /Users/mycomputer/Desktop/pmsnapshots/

Directory /Users/mycomputer/Desktop/pmsnapshots/
  Options Indexes MultiViews
  AllowOverride None
  Order allow,deny
  Allow from all
/Directory

Next I set the permissions on the target folder to group-www readonly

Then when I type 'localhost/images/' or '127.0.0.1/images/' into a  
Safari or Firefox address bar, I get:

Forbidden

You don't have permission to access /images/ on this server.

Apache/1.3.33 Server at mycomputer.local Port 80

Does anyone know whether Mac OS Tiger has some additional settings  
somewhere that need to be changed to allow the above to work?


Thanks for any help

Ken

-
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: [EMAIL PROTECTED]
 from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [EMAIL PROTECTED] PHP Prolem

2005-12-11 Thread Todd Hofert
Thanks to all who replied. Tis in addition to the original recommendation 
corrected the issue.
 
Thanks to all.



From: Malka Cymbalista [mailto:[EMAIL PROTECTED]
Sent: Sun 12/11/2005 4:50 AM
To: users@httpd.apache.org
Subject: RE: [EMAIL PROTECTED] PHP Prolem



I had a similar problem.  I added
   php_flag engine on
to the appropriate Directory sections and since then all has been
well.  I must say that for a long time I never had any problems with php
but at some point every now and then (and it was not consistent) the
browser would display the php code instead of actually running it.  Ever
since I addedphp_flag engine on   to the config file, I have not had
the problem.
We are running apache 2.0.55 with mod_ssl 2.0.55, openSL 0.9.7g, php,
php 4.3.3, and mod_perl 2.0.1.
Hope this helps.

 [EMAIL PROTECTED] wrote on 12/9/2005 3:46 PM:
 I apologize for my ignorance but I still cannot make this work. Can
 someone please offer specific direction on how to edit the .conf file

 to allow my appache server to properly display php files in
browsers?
 
 Thanks
 Todd

 

 From: myhapwcforever [mailto:[EMAIL PROTECTED]
 Sent: Thu 12/8/2005 9:06 AM
 To: users@httpd.apache.org
 Subject: Re: [EMAIL PROTECTED] PHP Prolem


 AddType application/x-httpd-php .php

 I met with your problem.And add it. ;)
  Original Message -

   From: Todd Hofert mailto:[EMAIL PROTECTED] 
   To: users@httpd.apache.org
   Sent: Thursday, December 08, 2005 8:57 PM
   Subject: RE: [EMAIL PROTECTED] PHP Prolem

   Where do I add this? I added it in the section that previously
read:
   
   IfModule mod_dir.c
   DirectoryIndex index.html
   /IfModule
   
   Doing so now just opens the php file as text in the browser
window.
   
   Thanks in advance.
   Todd

 

   From: ludi [mailto:[EMAIL PROTECTED]
   Sent: Wednesday, December 07, 2005 9:37 PM
   To: users@httpd.apache.org
   Subject: Re: [EMAIL PROTECTED] PHP Prolem
  
  
   AddType application/x-httpd-php .php
   DirectoryIndex index.html index.html.var index.php
   Add to the httpd.conf
  
  
   2005/12/8, Todd Hofert [EMAIL PROTECTED]:

   I just installed Apache 1.3 on local computer. I am now
trying to
 install Zen-Cart and when I access the appropriate directory the
result
 is a directory listing. The directions indicate that if you get a
 directory listing you should speak to your Hosting Site about how to

 setup your server to auto-detect PHP filename extensions.
  
   So since I am the host, how do I configure Apache to
auto-detect PHP
 filename extensions?
  
   Thanks
   Todd
  
   This e-mail and any attachments may contain confidential
and
 privileged
   information. If you are not the intended recipient,
please notify the
   sender immediately by return e-mail, delete this e-mail
and destroy
 any
   copies. Any dissemination or use of this information by
a person
 other
   than the intended recipient is unauthorized and may be
illegal.
  


-
   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:
[EMAIL PROTECTED]
 from the digest:
[EMAIL PROTECTED]
   For additional commands, e-mail:
[EMAIL PROTECTED]
  
  


   This e-mail and any attachments may contain confidential and
 privileged information. If you are not the intended recipient, please

 notify the sender immediately by return e-mail, delete this e-mail
and
 destroy any copies. Any dissemination or use of this information by a

 person other than the intended recipient is unauthorized and may be
 illegal.

  



 This e-mail and any attachments may contain confidential and
privileged
 information. If you are not the intended recipient, please notify
the
 sender immediately by return e-mail, delete this e-mail and destroy
any
 copies. Any dissemination or use of this information by a person
other
 than the intended recipient is unauthorized and may be illegal.


Malka Cymbalista
Webmaster, Weizmann Institute of Science
[EMAIL PROTECTED]
08-934-3036

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





This e-mail and any attachments may contain confidential and 

Re: [EMAIL PROTECTED] Problem setting up mod_alias for an external folder

2005-12-11 Thread Joshua Slive
On 12/11/05, Ken Tozier [EMAIL PROTECTED] wrote:

 Then when I type 'localhost/images/' or '127.0.0.1/images/' into a
 Safari or Firefox address bar, I get:
 Forbidden

 You don't have permission to access /images/ on this server.

 Apache/1.3.33 Server at mycomputer.local Port 80

 Does anyone know whether Mac OS Tiger has some additional settings
 somewhere that need to be changed to allow the above to work?

Start here:
http://httpd.apache.org/docs/1.3/misc/FAQ.html#forbidden

Joshua.

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] Apache2 SSI XBitHack not working

2005-12-11 Thread Joshua Slive
On 12/9/05, WJG [EMAIL PROTECTED] wrote:
 Here's a revised vhost snip:
 Directory /
 Options None
 AllowOverride None
 /Directory
 Directory /var/www/test
 Options MultiViews Includes

 AllowOverride None
 Order allow,deny
 allow from all

 AddType text/html .html
 AddOutputFilter INCLUDES .html

 XBitHack on
 /Directory

  So it didn't work with AddOutputFilter?  In that case, the problem has
  nothing to do with xbithack.  Please clarify.

 Sorry, you're right. It processes .shtml files, but not .html files even with
 the AddOutputFilter, with/out XBitHack.

Nothing obviously wrong there.  Anything interesting in the error log?
 Are you absolutely sure that the Directory section points to the
correct directory?  (Removing the allow from all should let you know.)

Other than that, it seems highly likely that you have something
elsewhere in httpd.conf (or an Include'd config file) that is changing
the configuration for .html files.  By default, there should be don
different between .html and .shtml.

In the worst case, I'd go back to the default httpd.conf that comes
with apache and see if you can get server-parsed .html to work there. 
Assuming you can, you can then slowly make changes to bring that
config file in line with what you have now until you see what breaks.

Joshua.

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] mod_cache broken in 2.2.0 ?

2005-12-11 Thread Joshua Slive
On 12/9/05, Dick Snippe [EMAIL PROTECTED] wrote:
 we use apache-2.0.x as a reverse caching proxy, using mod_cache,
 mod_mem_cache, mod_proxy and mod_proxy_http.

It wouldn't surprise me terribly if mod_mem_cache was broken in 2.2. 
It has received much less TLC than mod_disk_cache.  Given the lack of
response here, you should probably file a bug report.

Under many circumstances (especially on an OS with an efficient
sendfile syscall) you'll find that mod_disk_cache will be faster
anyway, since it passes much of the memory management job on to the OS
where it can be handled more efficiently.  So one option would be to
move to mod_disk_cache.

Joshua.

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] detail for a rewrite

2005-12-11 Thread T F
   In fact, i'd like to devise a general solution, such that whenever any
  document in the the /o tree is requested, then the url will be rewritten to
  the .net.  For example if the user pointed
  http://www.domain.com/o/file.html, then it would be
  rewritten to http://www.domain.net/o/file.html

 In the o/.htaccess:
  RewriteEngine on
  RewriteCond %{HTTP_HOST}   !^www\.domain\.net$ [NC]
  RewriteRule (.*)   http://www.domain.net/o/$1  [R]
 (or something like that -- untested).

 Joshua.

RewriteCond %{HTTP_HOST} !^www\.domain\.net [NC]
RewriteCond %{REQUEST_URI}   ^/o/.*
RewriteRule (.*)  /file.not.found.html [R]

Works finally.  Changed the game plan a little too.

Any .com request for resource in the o directory is now redirected to
a message file.

But this works too:

RewriteRule (.*)  http://www.domain.net/o/$1[R]

thanks!

Mike

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[EMAIL PROTECTED] force rewrite to occur before authentication, howto?

2005-12-11 Thread T F
For certain requests for resources in a password protected directory,
I'd like to redirect the user to an unprotected page.  In these cases,
I'd like the user not to know that the protected directory exists. 
The problem is that the login box pops up before the rewrite -- which
clues the user into the existence of the protected directory.

I need to correct this using .htaccess files since I do not have
access to httpd.conf

I've tried placing the rewrite code in the password protected
directory's .htaccess file, in which case I've set the rewrite lines
are before the authentication lines.

I've also tried putting the rewrite lines in top directory's .htaccess file.

Any help would be greatly appreciated.

Thanks in advance,
Mike

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] Problem setting up mod_alias for an external folder

2005-12-11 Thread Ken Tozier


On Dec 11, 2005, at 1:17 PM, Joshua Slive wrote:


On 12/11/05, Ken Tozier [EMAIL PROTECTED] wrote:


Then when I type 'localhost/images/' or '127.0.0.1/images/' into a
Safari or Firefox address bar, I get:
Forbidden

You don't have permission to access /images/ on this server.

Apache/1.3.33 Server at mycomputer.local Port 80

Does anyone know whether Mac OS Tiger has some additional settings
somewhere that need to be changed to allow the above to work?


Start here:
http://httpd.apache.org/docs/1.3/misc/FAQ.html#forbidden


Well that works on my test machine. Unfortunately, in the actual  
application, what I need to do is point Apache to an existing  
directory on a production server which contains the images I need to  
use. Moving or copying the tens of thousands of images to the Web  
server isn't an option. Installing another copy of Apache on the  
production server isn't an option and opening up the permissions of  
the entire production server hierarchy to the world isn't an option.


Is there no way to target a specific folder without exposing the  
entire hierarchy it exists in? Could this be worked around with a  
custom module?


-
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: [EMAIL PROTECTED]
 from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[EMAIL PROTECTED] Apache2 with Php5

2005-12-11 Thread Imrani
  Hi,I have installed Apache2 with PHP5support on FreeBSD 6.0 using ports collection. The installation process seemed to have gone fine but for some reason apache is not able to process the PHP files. It displayes all the code on the browser without processing. Does anyone know why this may be happening?More info is as follows:1. Noticed that there is php5 module in apache's httpd.conf. Does this prove that apache is configured with php?  -- LoadModule php5_module libexec/apache2/libphp5.so  2. Added/Edited following lines in httpd.conf  -- DirectoryIndex index.html index.html.var index.php-- AddType application/x-httpd-php .php  -- AddType text/html .shtml .php  3. S
 aved and
 restarted apache, but situation is still same.4. I can execute the php file from command line:  -- #localhost php test.php  this file use mysql_connect and mysql_close functions and executes pretty fine. But when I try to view in the browser, it displays just all that text that is NON-HTML. 5. file test.php has ownner group as www which is same user that is running apache and file permissions are 644 (rw-r--r--)Hope this gives enough info. Please let me know if I need to do more.Thank you,
	
		Yahoo! Shopping 
Find Great Deals on Holiday Gifts at Yahoo! Shopping 

Re: [EMAIL PROTECTED] Problem setting up mod_alias for an external folder

2005-12-11 Thread Ken Tozier

On Dec 11, 2005, at 1:17 PM, Joshua Slive wrote:



On 12/11/05, Ken Tozier [EMAIL PROTECTED] wrote:



Then when I type 'localhost/images/' or '127.0.0.1/images/' into a
Safari or Firefox address bar, I get:
Forbidden

You don't have permission to access /images/ on this server.

Apache/1.3.33 Server at mycomputer.local Port 80

Does anyone know whether Mac OS Tiger has some additional settings
somewhere that need to be changed to allow the above to work?



Start here:
http://httpd.apache.org/docs/1.3/misc/FAQ.html#forbidden



Well that works on my test machine. Unfortunately, in the actual  
application, what I need to do is point Apache to an existing  
directory on a production server which contains the images I need to  
use. Moving or copying the tens of thousands of images to the Web  
server isn't an option. Installing another copy of Apache on the  
production server isn't an option and opening up the permissions of  
the entire production server hierarchy to the world isn't an option.


Is there no way to target a specific folder without exposing the  
entire hierarchy it exists in? Could this be worked around with a  
custom module?



-
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: [EMAIL PROTECTED]
 from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] Apache2 with Php5

2005-12-11 Thread Rich Bowen

Imrani wrote:


Hi,
 
I have installed Apache2 with PHP5 support on FreeBSD 6.0 using ports 
collection. The installation process seemed to have gone fine but for 
some reason apache is not able to process the PHP files. It displayes 
all the code on the browser without processing. Does anyone know why 
this may be happening?




-- AddType application/x-httpd-php .php
-- AddType text/html .shtml .php


That second line overrides the first one.
What you want instead is:

AddHandler application/x-httpd-php .php

--
Rich Bowen
[EMAIL PROTECTED]

-
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: [EMAIL PROTECTED]
 from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] Apache2 with Php5

2005-12-11 Thread Imrani
Thanks Rich,It worked like a charm.  - ImraniRich Bowen [EMAIL PROTECTED] wrote:  Imrani wrote:  Hi,  I have installed Apache2 with PHP5 support on FreeBSD 6.0 using ports  collection. The installation process seemed to have gone fine but for  some reason apache is not able to process the PHP files. It displayes  all the code on the browser without processing. Does anyone know why  this may be happening? -- AddType application/x-httpd-php .php -- AddType text/html .shtml .phpThat second line overrides the first one.What you want instead is:AddHandler application/x-httpd-php .php-- Rich
 Bowen[EMAIL PROTECTED]-The official User-To-User support forum of the Apache HTTP Server Project.See for more info.To unsubscribe, e-mail: [EMAIL PROTECTED]" from the digest: [EMAIL PROTECTED]For additional commands, e-mail: [EMAIL PROTECTED]  
	
		Yahoo! Shopping 
Find Great Deals on Holiday Gifts at Yahoo! Shopping 

Re: [EMAIL PROTECTED] Problem setting up mod_alias for an external folder

2005-12-11 Thread Joshua Slive
On 12/11/05, Ken Tozier [EMAIL PROTECTED] wrote:
 On Dec 11, 2005, at 1:17 PM, Joshua Slive wrote:


  On 12/11/05, Ken Tozier [EMAIL PROTECTED] wrote:
 
 
  Then when I type 'localhost/images/' or '127.0.0.1/images/' into a
  Safari or Firefox address bar, I get:
  Forbidden
 
  You don't have permission to access /images/ on this server.
 
  Apache/1.3.33 Server at mycomputer.local Port 80
 
  Does anyone know whether Mac OS Tiger has some additional settings
  somewhere that need to be changed to allow the above to work?
 
 
  Start here:
  http://httpd.apache.org/docs/1.3/misc/FAQ.html#forbidden
 

 Well that works on my test machine. Unfortunately, in the actual
 application, what I need to do is point Apache to an existing
 directory on a production server which contains the images I need to
 use. Moving or copying the tens of thousands of images to the Web
 server isn't an option. Installing another copy of Apache on the
 production server isn't an option and opening up the permissions of
 the entire production server hierarchy to the world isn't an option.

 Is there no way to target a specific folder without exposing the
 entire hierarchy it exists in? Could this be worked around with a
 custom module?

By exposing the entire hierarchy do you mean giving file-system
search permissions (chmod +x)?  If so, no, you can't work around this
in apache.  It has nothing to do with apache.  It is the file-system
that is denying access.  If apache can't get to the directory, there
is no way to serve the files.

In general, giving careful search permissions on the tree while
restricting read permissions should be perfectly safe in most
circumstances.  A possible alternative might be to do some fancy
file-system tricks like remounting that particular directory in its
own spot that isn't so tightly protected.

Joshua.

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[EMAIL PROTECTED] Problem with Virtual Host on Apache v2.0.54

2005-12-11 Thread Andrey Kuznetsov
Apache v2.0.54 behind NAT and using DMZ.
I am able to access the website from outside through the NAT and else,
however I cannot set up my Virtual Host environment.

This is what I have in my config file, it works in terms it redirects
me to the first instance of priority which is ABC but I can never get
to EFG even though I type http://efg.dyndns.dk. My problem is being
able to access abc but not efg which is like the second domain hosted
on the same apache server\ip.
Thank you for helping out. Just ask if you need more info.

NameVirtualHost *

VirtualHost abc.dyndns.dk:80
ServerAdmin [EMAIL PROTECTED]
DocumentRoot C:/Program Files/Apache Group/Apache2/abc
ServerName abc.dyndns.dk
ErrorLog logs/error.log
CustomLog logs/access.log common
Options Indexes FollowSymLinks ExecCGI
/VirtualHost

VirtualHost efg.dyndns.dk:80
ServerAdmin [EMAIL PROTECTED]
DocumentRoot C:/Program Files/Apache Group/Apache2/efg
ServerName efg.dyndns.dk
ErrorLog logs/efg-error.log
CustomLog logs/efg-access.log common
Options Indexes FollowSymLinks ExecCGI
/VirtualHost

--
Live Long and Prosper,
by Andrey Kuznetsov aka Death Owl

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[EMAIL PROTECTED] Re: force rewrite to occur before authentication, howto?

2005-12-11 Thread T F
 The problem is that the login box pops up before the rewrite

I'm still not having any luck with this.  It appears as though
authentication is happening before the rewrite.  I need the
opposite:  need rewrite before the authentication.

Oddly, a google search turns up posts with both situations.
In some, people are in my boat (trying to get rewrite before auth)

In others, people are stating that Apache actually rewrites before
authentication (which is want I'm after).

for example, here is a 2001 post (same Joshua?)

http://www.mailarchives.org/list/apache-httpd-users/msg/2001/00078

RewriteRules get applied before authentication is performed.  Luckily,
Ralf thought of this problem and invented the convoluted syntax
%{LA-U:REMOTE_USER} to do an internal sub-request and grab the REMOTE_USER
value.  See:
http://httpd.apache.org/docs/mod/mod_rewrite.html#RewriteCond

tia,
Mike

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [EMAIL PROTECTED] Problem setting up mod_alias for an external folder

2005-12-11 Thread Ken Tozier


On Dec 11, 2005, at 8:12 PM, Joshua Slive wrote:

By exposing the entire hierarchy do you mean giving file-system
search permissions (chmod +x)?  If so, no, you can't work around this
in apache.  It has nothing to do with apache.  It is the file-system
that is denying access.  If apache can't get to the directory, there
is no way to serve the files.


I guess the confusion on my part is: Why isn't it possible to just  
treat the Apache process as you would any other user? Add Apache  
process x from machine y to group z that is allowed see a specified  
folder? Instead, we're forced to redefining the permissions of every  
directory in  the path just so Apache can see it. The permissions are  
already set up the way we want them re group access and in the  
overall scheme of things Apache should be just another user logged  
into the server.


The mechanics of coercing a resource URL into a file system path are  
trivial. With a correctly formatted path string in hand, just send a  
file open to the underlying file system. If you get a valid file  
handle back, great you have permission. If not you don't. No need to  
go through all this directory permission redefinition business.


Ken

-
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: [EMAIL PROTECTED]
 from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[EMAIL PROTECTED] [SOLVED] Re: [EMAIL PROTECTED] Apache2 SSI XBitHack not working

2005-12-11 Thread WJG
On Sunday 11 December 2005 13:23, Joshua Slive wrote:
 Nothing obviously wrong there
  Are you absolutely sure that the Directory section points to the
 correct directory?

Well, accidentally resolved the problem. Am testing the server on localhost, 
but the vhost ServerAlias didn't include localhost.localdomain and I was 
accessing the pages like so: http://localhost.localdomain/test/test.html. So, 
although it was returning the correct page, it wasn't processing it via 
INCLUDES. Once I put localhost.localdomain into the ServerAlias, and access 
it as http://localhost.localdomain/test.html, it correctly processes it.

I know, entirely my fault, and just slightly outside the scope of where I was 
looking for the problem. Thanks for your help Josh.

Jay

-
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: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]