How do I make a cgi script World-executable

Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers How do I make a cgi script World-executable
# 1  
Old 06-12-2001
How do I make a cgi script World-executable

I'm trying to set up a form mail script on a website that when Submitted, a cgi script is executed and a perl translator (located in a secured and inaccessible folder) translates the script. After speaking to my hosting provider, I was told to "Telnet into the system and make the script executable." Thanks to Unix Forums user, PxT, I'm now able to access their server and login, but I'm not sure how to make this script executable. I think it has something to do with the chmod command. Please advise...

# 2  
Old 06-12-2001
now that you can log onto your providers servers you can look at there man pages.

type the following

man chmod

its very self explanitory
# 3  
Old 06-13-2001
ls -a will show you the permissions on the file, to the far left. They are grouped in three lots, the far left three are permissions set for the owner, the next three are permissions for the group and the last three are permissions for the world. There are three main flags on these permissions:

r = Read
w = write
x = execute

If one of these flags is present in whatever grouping it means that that person/group of people can conduct that action on the file. So, for e.g.

-rwx-rw--r-- 1 someone someuser 20984 Jun 13 10:22 file1

Would mean the owner has read, write and execute permission, the group only has read and write and the world only has read.

You can pass a set of three numbers, each one corresponding to the owner, group and world respectively, to the chmod command to adjust these permissions.

r = 4
w = 2
x = 1

So the command:

chmod 467 file1

Would change the permissions on file1 thus:

-r--rw--rwx 1 someone someuser 20984 Jun 13 10:22 file1

Now you can apply this information to change the permissions on your file to how you desire Smilie

As optimus said check the man pages, this is only very basic stuff on controlling permissions.

Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Bash script make itself executable

Is there a way to make this make itself executable? Thanks. :-) cat > << \EOF #!/bin/bash block_count=$(sudo tune2fs -l /dev/sda1 | awk '/^Block count:/ {print $NF}') reserved_block_count=$(sudo tune2fs -l /dev/sda1 | awk '/^Reserved block count:/ {print $NF}') perl -e... (4 Replies)
Discussion started by: drew77
4 Replies

2. Shell Programming and Scripting

Question on tweaking the PATH variable to allow the world to run my executable script

All, I am pretty new to Unix and still in the learning curve :) I have a simple requirement for which I did not get an answer yet (Atleast I do not know how to keyword the search for my requirement!!!). I have an executable script my.script1 in a folder /data/misc/scripts/dev, which when... (5 Replies)
Discussion started by: bharath.gct
5 Replies

3. Shell Programming and Scripting

Unable to make script executable

Hello everybody, I'm unable to make my shell script an executable file. The details are as follows: PATH includes my $HOME/bin i.e. /rchome/rc1/bin HOME directory is /rchome/rc1 script name is permissions set are 755 It's executing if I give below command sh but... (4 Replies)
Discussion started by: jitu.keshwani
4 Replies

4. Shell Programming and Scripting

How to make a script (Bash, KornShell, etc.) executable by mouse clicking?

Hello everybody, Is there any way to make a script (Bash, KornShell, etc.) executable by mouse clicking? For example you have a file, you run: $ chmod u+x Therefore it becomes executable and all you need is to run from the terminal: $./ (2 Replies)
Discussion started by: dariyoosh
2 Replies

5. Shell Programming and Scripting

run and make an executable file

as i said before i'm a beginner in shell programming and i have two questions: how to run an executable file in shell scripts like for example let's say the file called "prog.exe", what's the shell command to run this file? also how can i make the shell file an executable file (if it is... (5 Replies)
Discussion started by: _-_shadow_-_
5 Replies

6. Shell Programming and Scripting

Invoking CGI executable after setenv (in bash)

Hello, I have an executable cgi program that I can run manually from my Linux shell after setting environmental variables on the previous line, like this: setenv QUERY_STRING "workdir=/u/here/there/&nb1=5&nb2=1000" MyExecutable.cgiHow can I imitate this behavior in a bash script? I tried... (11 Replies)
Discussion started by: aplaydoc
11 Replies

7. UNIX for Dummies Questions & Answers

Howto make an URL world readable

Currently this url: Is only accessible through my local network (for external user need VPN). My question is how can I make that URL accessible for everybody even those outside my network? That url is served under Solaris 10 and I do have SU... (3 Replies)
Discussion started by: monkfan
3 Replies

8. Solaris

How to make a script executable by all users?

I have a script in my home direcroty which upon execution gives the essential system information like memory,cpu etc and is currently owned by root:root. Now I want to see that every non root user will run this file and grab the reqired system info. I know this is some thing associated with chown... (2 Replies)
Discussion started by: chrs0302
2 Replies

9. Shell Programming and Scripting

CGI passing arrays/hashes to another CGI script

If I have a Perl CGI script (script01), which fills an array(s) with information and outputs a HTML page with a link to another CGI page (script02); is there anyway to pass the array(s) from "script01" to "script02" when the page visitor clicks the link? Hope that makes sense! :) (2 Replies)
Discussion started by: WIntellect
2 Replies
Login or Register to Ask a Question