Forum Moderators: phranque

Message Too Old, No Replies

cgi does not parse but download instead?

server not parsing cgi

         

justixia

9:33 pm on Aug 18, 2007 (gmt 0)

10+ Year Member



Hi, I'm posting my first issue here because I've been looking for more than 24h without finding a way to fix a problem on the server I'm working on.

I have a cgi file that stopped running, telling the browser to download instead! I'm not much of a server dude myself but I'm doing my best to sort this matter out as I'm now unable to complete some of my work as an administrator (the file i'm trying to run is the one allowing me to enter my admin panel)

I did quite a lot of research and I know that this matter has been treated already here but it may differ, on the root I can see an empty .htaccess file randomnly created when trying to run the cgi script.
the server is running a cPanel software
and I checked that Apache handlers were correct and/or Mime type were missing or else.What bothers me is that a backup of the same site is fully working on another server located elsewhere and this is why I reckon there must be some problem with the Apache configuration of the server I'm using. Please any idea, tests, anything?

Thanks

SteveLetwin

11:29 pm on Aug 18, 2007 (gmt 0)

10+ Year Member



Have you modified the cgi program, any apache configuration, or any cPanel settings?

What's the content of the .htaccess file that's created? You can delete it, but when you run the cgi program again it's recreated?

SteveLetwin

12:12 am on Aug 19, 2007 (gmt 0)

10+ Year Member



Also, the file that wants to be downloaded, is it the CGI script itself or the output of the CGI script?

justixia

7:42 am on Aug 19, 2007 (gmt 0)

10+ Year Member



Thanks for you reply.

I have an update.

Nothing has changed, the .htaccess file created is empty, no cPanel changes was made by me and can't say much about the Apache configuration because the file and site is hosted on a external server,I asked the server Hosting support and they told me that nothing has changed (I'm not sure of this, more like the people involved don't know what to do about it)

Anyway, what happen this morning is that I saved the file on download request and the file itself was empty, just after that I did try again and this time the page was browsed correctly but with a string

Set-Cookie: COOKIE_ADMIN=snaaapsaahassf; path=/ Date: Sun, 19 Aug 2007 07:34:38 GMT Content-Type: text/html; charset=ISO-8859-1 Content-type:text/html

When I insert my password it goes fine and enter but as soon as I click on any option it goes back asking the password again!

thanks for you time

justixia

3:01 pm on Aug 24, 2007 (gmt 0)

10+ Year Member



Update, I got a message about the error from the script developer which did issue a modified version of it and told me that the problem was easy to sort out as some server servers require perl scripts to print the header before certain code is used, anyone knows what is all about? Nowe I have the script working because it was fixed but if I use the original script is still giving me headache and I think that the fix should be at the server configuration and not the script which was working fine until something happened.

Thanks

phranque

12:04 am on Aug 25, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



it certainly looks like a header problem but there is not enough information to see where it is.

justixia

7:14 am on Aug 25, 2007 (gmt 0)

10+ Year Member



Thanks for your reply, unfortunately this is what I got, I did try to get the error in details but it seems a mystery, it is for me, I just wanted to fix or make changes to the server configuration in order to get the script working as usual and not using the Mod version of it, I will dig into the cgi file which was changed and back here with some more info.

Thanks