|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #2649 PHP for NS
Submitted: 1999-11-01 16:03 UTC Modified: 2002-06-16 14:18 UTC
From: srinivas dot katta at cwusa dot com Assigned:
Status: Not a bug Package: Installation problem
PHP Version: 3.0.12 OS: solaris-.5.5.1
Private report: No CVE-ID: None
 [1999-11-01 16:03 UTC] srinivas dot katta at cwusa dot com

One of my customers want to test the test.php3 file under /docs dir of
his web site.

Here is the test.php3 file info.
<?php print "<p>If you see this, php3 is installed";  ?>

Here is the system and web server info.

SunOS schering1 5.5.1 Generic_103640-24 sun4u sparc SUNW,Ultra-1
No database support.

Here is the more info.

I have done following things for to install the php over sun platform for
Netscape webs erver.

1)Compiled the php3 according to the info,which I have got info from the  following web site.

As per web site,I have used following options at config level.

./configure  --with-gd=no - --enable-debug=no         --enable-safe-mode=yes --with-exec-dir=/web1/webroot  --enable-magic-quotes=yes        --enable-force-cgi-redirect=yes  --enable-discard-path=yes 

Also,I have updated main.c file for following info.

-----------------PHP: main.c: (before compiling PHP make this change) 

    replace with "HTTP_REDIRECT_STATUS

Also,I have updated config files for the following info.


type=magnus-internal/php         exts=php3,phtml


    Init fn=load-modules shlib=/home/ns-home/plugins/             funcs=redirect-cgi


<Object name="php">
ObjectType fn="redirect-cgi" cgi_path="/usr/local/bin/php"   type="magnus-internal/php"


After all,I have found following error mesg from error log file.

a)Here is the one of the error mesgs,When I used to access the url

error on the browser
Server Error

This server has encountered an internal error which prevents it from  fulfilling your request. The most likely cause is
a misconfiguration. Please ask the administrator to look for messages in  the server's error log.

error from the error log.

[25/Oct/1999:16:02:48] config: for host trying to GET  /test.php3, handle-processed reports: no way to service request for  /test.php3

2)a)Here is the one of the error mesgs,When I used to access the url

(I  have added  following line to the begining of the file).



error on the browser
Security Alert! PHP CGI cannot be accessed directly. 

This PHP CGI binary was compiled with force-cgi-redirect enabled. This  means that a page will only be served up
if the REDIRECT_STATUS CGI variable is set. This variable is set, for  example, by Apache's Action directive

You may disable this restriction by recompiling the PHP binary with the  --disable-force-cgi-redirect switch. If
you do this and you have your PHP CGI binary accessible somewhere in your web tree, people will be able to
circumvent .htaccess security by loading files through the PHP parser. A  good way around this is to define doc_root
in your php3.ini file to something other than your top-level  DOCUMENT_ROOT. This way you can separate the
part of your web space which uses PHP from the normal part using  .htaccess security. If you do not have any
.htaccess restrictions anywhere on your site you can leave doc_root  undefined. 

Could you pl advice me how  can  I  configure the php3 files under
NS webserver.



Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-06-16 14:18 UTC]
Thank you for taking the time to report a problem with PHP.
Unfortunately, PHP 3 is no longer supported. Please download
the latest version of PHP 4 from

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Jun 24 06:01:31 2024 UTC