At 18.36 28/11/2003 +0100, Ulisse Savi wrote:
Apache Server at eulisse.com If i make a search here : <http://www.eulisse.com/search.html>http://www.eulisse.com/search.html or i link my site here : <http://www.eulisse.com/cgi-bin/htsearch>http://www.eulisse.com/cgi-bin/htsearch i continue to have from days the same result : "The server encountered an internal error or misconfiguration and was unable to complete your request". I do not understand. Is it possible to not use htsearch in cgi-bin ? I think that there is a problem with chmod or similar. I do not understand. It use perl ? And the error is caused by the fact it not find perl script ? /usr/bin/perl ??? My cgi-perl system is O.K.. I have other program and all is good. <http://www.eulisse.com/cgi-bin/awstats.pl>http://www.eulisse.com/cgi-bin/awstats.pl http://www.eulisse.com/cgi-bin/auction.pl <http://www.eulisse.com/cgi-bin/doorway.cgi>http://www.eulisse.com/cgi-bin/doorway.cgi http://www.eulisse.com/cgi-bin/free_web_games.cgi
'htsearch' is an executable file. It is not perl or bash, it is a compiled C++ program. It must have execution permissions (x). I guess it is just a permissions problems.
I have these questions for you:
- what are the permissions of the htdig system directories (the one with the database, the binaries, the configuration files, etc.)
- which user and group is the Web server running as?
If you can, try and run from console or terminal 'htsearch', by logging with the user the Web server runs as.
For instance, if it runs as 'ulisse', try and log in as root then type 'su - ulisse', go in the cgi-bin directory which contains htsearch and type 'htsearch'. See what happens. Until this works, you can't use a CGI via Web.
understand. Perhaps it find the database in the server but when i write <http://www.eulisse.com/search.html>http://www.eulisse.com/search.html the database is not found ??? Is it possible to not use cgi-bin ? I tried to put htsearch in a normal directory. Here : <http://www.eulisse.com/htsearch>http://www.eulisse.com/htsearch and to change <http://www.eulisse.com/search.html>http://www.eulisse.com/search.html but when i search the word it load htsearch such as a file and it download htsearch such as a normal file zip or tar.
That's perfectly understandable. In Apache, an executable file can be run as a CGI only in particular directories, usually /cgi-bin/ but more in general through the use of the ScriptAlias directive. (Unless you use PHP which is not this case)
I make all right. I write : ./configure --prefix=/home/httpd/vhosts/eulisse.com/httpdocs/htdig/ --with-database-dir=/ulisse/db_htdig/ --with-cgi-bin-dir=/home/httpd/vhosts/eulisse.com/cgi-bin/ --bindir=/home/httpd/vhosts/eulisse.com/cgi-bin/ --with-image-dir=/home/httpd/vhosts/eulisse.com/httpdocs/images/ --with-search-dir=/home/httpd/vhosts/eulisse.com/httpdocs/ --with-search-form=search.html --with-image-url-prefix=/images/ --with-common-dir=/home/httpd/vhosts/eulisse.com/httpdocs/htdigcommon/ make
Also, I have noticed that you have set the prefix, the binaries, the common and configuration files (everything but the database) in a directory which is reachable via HTTP. It is not safe. As I told you yesterday, you just need the CGI bin and the HTML, images, etc. to be reachable through the Web. It is safe that every binary, configuration file and database be out of reach of malicious users.
htsearch Error ! chmod 755 htsearch error ! chmod 644 htsearch error ! chmod ???? Register global ? Or Safe mode ? I do not
Don't panic Ulisse; we'll make it work. :-) However, register global and safe mode are PHP options. Keep in mind that PHP is not necessary at this stage so ... remove any PHP stuff from your mind until you install it.
Ciao ciao,
-Gabriele
--
Gabriele Bartolini: Web Programmer, ht://Dig & IWA/HWG Member, ht://Check maintainer
Current Location: Melbourne, Victoria, Australia
[EMAIL PROTECTED] | http://www.prato.linux.it/~gbartolini | ICQ#129221447
> "Leave every hope, ye who enter!", Dante Alighieri, Divine Comedy, The Inferno
------------------------------------------------------- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ _______________________________________________ ht://Dig general mailing list: <[EMAIL PROTECTED]> ht://Dig FAQ: http://htdig.sourceforge.net/FAQ.html List information (subscribe/unsubscribe, etc.) https://lists.sourceforge.net/lists/listinfo/htdig-general

