CGI - ABW in Linux

 
Post new topic   Reply to topic    Aprelium Forum Index -> FastCGI/CGI
View previous topic :: View next topic  
Author Message
HappyBG
-


Joined: 11 Jul 2005
Posts: 1

PostPosted: Mon Jul 11, 2005 8:10 pm    Post subject: CGI - ABW in Linux Reply with quote

I just installed Abyss Web Server in Linux, and I wanted to try a CGI script example. I created a cgi-bin folder in abissws directory where I copied the executable of my CGI script C program. In my HTML form at action I copied the path to my executable from gci-bin. And when I try to run this the browser say that it can not find the executable. Please tell me how to do with this problem, should I install something for CGI scripts ......?
Thanks
Back to top View user's profile Send private message
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Mon Jul 11, 2005 8:18 pm    Post subject: Reply with quote

This depends what type the CGI script is , also cgi-bin doesn't really exist in
the new internet days , Abyss Web Server doesn't require it. You should put
this script in a "Script Paths" that you setup in the abyss console.

Example: Script Paths
/your_script

Have a look at this for help on installing Scripting Languages.
http://www.aprelium.com/abyssws/features.html#scripting

Sincerely , TRUSTpunk
Back to top View user's profile Send private message Visit poster's website
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Tue Jul 12, 2005 3:22 pm    Post subject: Re: CGI - ABW in Linux Reply with quote

HappyBG,

Abyss Web Server do not require a special directory for scripts/CGI applications (such as cgi-bin). You can put your executable everywhere. But you should also let Abyss Web Server know that this file is executable.

To do so, let's say your executable is reachable using http://yoursite/dir1/dir2/exefile . Now go to "Scripting Parameters" and add to "Script Paths" the virtual path /dir1/dir2/exefile .

The exefile should have its executable bit set (which is done by default by your C compiler).
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
omaronly
-


Joined: 27 Nov 2004
Posts: 20

PostPosted: Thu Jul 14, 2005 2:47 am    Post subject: Reply with quote

...and don't forget to make that directory readable by the webserver. For example, IF your webserver runs as user and group nobody:nobody,

Code:
 chown -R nobody:nobody /full/path/to/your/directory


Also, it doesn't hurt to do this:

Code:
 chmod -R 775 /full/path/to/your/directory


So, when you 'ls' that directory, the directory itself and your cgi should look like this:

Code:
rwx rwx r-x
which has always worked for me, although one can be more strict with the permissions, though. Otherwise, Linux will not allow the script to be executed by the server, even if you designate it as such in abyss.

You know, Aprelium, it would be great if the linux version included a shell script which could do this when triggered by the control consol in this situation. Possibly, this could be included in the exe, or would that break cross-platform compatibility for you guys?[/code]
Back to top View user's profile Send private message
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Thu Jul 14, 2005 2:08 pm    Post subject: Reply with quote

omaronly wrote:

You know, Aprelium, it would be great if the linux version included a shell script which could do this when triggered by the control consol in this situation. Possibly, this could be included in the exe, or would that break cross-platform compatibility for you guys?

Do you suggest including something that will change the file permissions on the behalf of the users? We prefer not to do so because it can open the door for wrong manipulations and possible security issues.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> FastCGI/CGI All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot 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


Powered by phpBB phpBB Group