Welcome to MobyThreads.com!
FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in
All support for the MobyThreads Threaded phpBB MOD can now be found on welsolutions at this forum

cgi-bin problem

 
   Web Hosting and Web Master Forums (Home) -> Apache RSS
Next:  passwords on files and directories question  
Author Message
someone33

External


Since: Oct 28, 2003
Posts: 7



(Msg. 1) Posted: Tue Aug 17, 2004 12:30 pm
Post subject: cgi-bin problem
Archived from groups: alt>apache>configuration (more info?)

I am running Apache 1.3.14 on Win 98. PHP & Perl are installed and are
running correctly.
The directory structure is C:/Perl C:/apache/www/cgi-bin
C:/apache/www/...<other files and directories>

My problem is this: I am trying to use a published script to upload files
via a form from a webpage. When I click submit, I get the usual "Page
cannot be found". It appears that the "upload.cgi" in the cgi-bin directory
cannot be accessed.

I tried putting a file in the cgi-bin and then accessing it through IE6
using localhost/cgi-bin/.... I got the "Page cannot be found". I then
changed the directory name from cgi-bin to cgibin and went to
localhost/cgibin/... This time I could access the file OK.

It seem that the directory cannot be accessed when it has the hyphen in and
this is stopping the form from working. I posted to the php group, but a
response from there, suggested it was an Apache problem.

Any help much appreciated.

Geoff.

 >> Stay informed about: cgi-bin problem 
Back to top
Login to vote
dinges_danges_

External


Since: Aug 03, 2004
Posts: 88



(Msg. 2) Posted: Wed Aug 18, 2004 2:48 am
Post subject: Re: cgi-bin problem [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Geoff said the following on 17/08/2004 10:30:

 > I am running Apache 1.3.14 on Win 98. PHP & Perl are installed and are
 > running correctly.
 > The directory structure is C:/Perl C:/apache/www/cgi-bin
 > C:/apache/www/...<other files and directories>

I have no experience with Apache on a Windows platform, but generally a
CGI directory should not be part of the DocumentRoot. I couldn't find
any documents explaining why, but it has to do with security. If I find
them, I'll post them later.

 > I tried putting a file in the cgi-bin and then accessing it through IE6
 > using localhost/cgi-bin/.... I got the "Page cannot be found". I then
 > changed the directory name from cgi-bin to cgibin and went to
 > localhost/cgibin/... This time I could access the file OK.

There's probably a ScriptAlias line in your httpd.conf pointing
somewhere outside your DocumentRoot (like it should) and therefor your
"upload.cgi" couldn't be found. When you changed your directory name to
"cgibin" it's not matched by the ScriptAlias directive and therefor
Apache looked in your DocumentRoot where you've made the directory. You
probably could have figured this out by looking at the error logs.
Anyway, for more details about ScriptAlias, see:

<a style='text-decoration: underline;' href="http://httpd.apache.org/docs/mod/mod_alias.html#scriptalias" target="_blank">http://httpd.apache.org/docs/mod/mod_alias.html#scriptalias</a>

And you should probably read:

<a style='text-decoration: underline;' href="http://httpd.apache.org/docs/howto/cgi.html" target="_blank">http://httpd.apache.org/docs/howto/cgi.html</a>

 > Any help much appreciated.

HTH

--
Regards
Harrie<!-- ~MESSAGE_AFTER~ -->

 >> Stay informed about: cgi-bin problem 
Back to top
Login to vote
someone33

External


Since: Oct 28, 2003
Posts: 7



(Msg. 3) Posted: Wed Aug 18, 2004 2:20 pm
Post subject: Re: cgi-bin problem [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Many thanks for this info. I wasn't aware of this, I can now look in the
right place .

Geoff.

"Harrie" <dinges_danges_donges.RemoveThis@hotmail.com> wrote in message
news:41227d2e$0$21106$e4fe514c@news.xs4all.nl...
 > Geoff said the following on 17/08/2004 10:30:
 >
  > > I am running Apache 1.3.14 on Win 98. PHP & Perl are installed and are
  > > running correctly.
  > > The directory structure is C:/Perl C:/apache/www/cgi-bin
  > > C:/apache/www/...<other files and directories>
 >
 > I have no experience with Apache on a Windows platform, but generally a
 > CGI directory should not be part of the DocumentRoot. I couldn't find
 > any documents explaining why, but it has to do with security. If I find
 > them, I'll post them later.
 >
  > > I tried putting a file in the cgi-bin and then accessing it through IE6
  > > using localhost/cgi-bin/.... I got the "Page cannot be found". I then
  > > changed the directory name from cgi-bin to cgibin and went to
  > > localhost/cgibin/... This time I could access the file OK.
 >
 > There's probably a ScriptAlias line in your httpd.conf pointing
 > somewhere outside your DocumentRoot (like it should) and therefor your
 > "upload.cgi" couldn't be found. When you changed your directory name to
 > "cgibin" it's not matched by the ScriptAlias directive and therefor
 > Apache looked in your DocumentRoot where you've made the directory. You
 > probably could have figured this out by looking at the error logs.
 > Anyway, for more details about ScriptAlias, see:
 >
<font color=purple> > <a style='text-decoration: underline;' href="http://httpd.apache.org/docs/mod/mod_alias.html#scriptalias</font" target="_blank">http://httpd.apache.org/docs/mod/mod_alias.html#scriptalias</font</a>>
 >
 > And you should probably read:
 >
<font color=purple> > <a style='text-decoration: underline;' href="http://httpd.apache.org/docs/howto/cgi.html</font" target="_blank">http://httpd.apache.org/docs/howto/cgi.html</font</a>>
 >
  > > Any help much appreciated.
 >
 > HTH
 >
 > --
 > Regards
 > Harrie<!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: cgi-bin problem 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
ssi problem - I was trying to enable ssi on my apache web server. I've edited httpd.conf and add these lines: AddType text/html .shtml AddHandler server-parsed .shtml <font color=purple> ; Options +Includes</font> Despite of this, a...

SSL Problem - Hi, I have a problem with the configuration of Apache. When I start httpd I have this error : --- make_sock: could not bind to address 0.0.0.0:443 no listening sockets available, shutting down --- I want to disable the https because my port 443 is..

%3F / ? problem - Hi, I'm getting loads of 404s because Googlebot is transposing %3F for the ? symbol, ie :- /script.php?value=001728 200 is being referenced by google as /script.php%3Fvalue=001728 404 However pages containing %20 are working fine, ie :- ..

Problem with "/" - Why my apache give me an error if i don't write "/" at the and of URL in the Brower ? How parameter I must set for don't write "/" ? Thanx to all ... and sorry for my English ;-) bruce

SSL Problem - Hi All, SSL cert was installed on virtual host apache mod web server but none of the images for the site show up. when looking at the direct link to the image file I get an error 403 message. ie https://mysite.com/images/image.gif everything works fine....
   Web Hosting and Web Master Forums (Home) -> Apache All times are: Pacific Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]