page content
How do I set the permissions on my CGI programs and other files?
As you don't have shell access you have to do this from within your FTP client program with which you upload your files. Do not change the permissions of the cgi-bin/ folder when doing so you could compromise the security of your website.
Most of the simpler FTP clients offer a graphical attribution of the permissions:
user group world
read () () ()
write () () ()
execute () () ()
You just have to click to grant the rights. As you can recognize the holder of the rights becomes less and less trustworthy: the user rights are for yourself, the group rights are for the groups you are a member of and the world are the visitors of your website.
As you are no group's member consider the group and the world as the entities that you have to grant very carefully rights to.
For a very simple CGI program you would grant for instance these rights:
user group world
-rwx --x --x
In certain cases your CGI could need read access for the world too:
user group world
-rwx r-x r-x
A good practise is to use always as few permissions as possible.
The above example could be also written in octal values, like this:
user group world
-rwx --x --x
would be 755.
and
user group world
-rwx --x --x
would be 711.
Putting it simple: you choose from 0-7 for each of the three groups, user, group and world.
0 means no access right at all
1 means execute rights (be careful)
2 means write rights (be careful)
4 means read rights (that's the only right needed for standard HTML files)
If you add the octal values together you combine the rights, for instance 1+2=3 3 means execute and write rights.
You may play around with these rights in your directory to better learn how to use them. Don't forget to always verify the rights you set. An error could be fatal to your content's security.
For your common HTML files you would grant only 644 permissions. This means that you, the user has read and write rights (4+2=6); the group has read rights (4) and the world has read access too (4); (sumed up this makes: 644). Generally your FTP client uses these careful permissions as default.
comments
add your comment
comments add advicecontact us
the comments
25th of July 2006 at 17:28 | posted by man
rfsdfsfsd sqf sqf qd q sfqsfd qsf qsfd qs
3rd of November 2013 at 8:20
comment awaiting validation.
13th of March 2014 at 0:45
comment awaiting validation.
22nd of October 2014 at 1:52
comment awaiting validation.
15th of December 2014 at 20:32
comment awaiting validation.
16th of December 2014 at 13:23
comment awaiting validation.
19th of November 2017 at 7:36
comment awaiting validation.
19th of November 2017 at 21:31
comment awaiting validation.
26th of November 2017 at 22:06
comment awaiting validation.
2nd of December 2017 at 3:36
comment awaiting validation.
23rd of December 2018 at 19:45
comment awaiting validation.
10th of April 2020 at 9:31
comment awaiting validation.
10th of May 2020 at 13:23
comment awaiting validation.
15th of June 2020 at 4:51
comment awaiting validation.
18th of July 2020 at 1:28
comment awaiting validation.
13th of August 2020 at 8:58
comment awaiting validation.
18th of September 2020 at 8:02
comment awaiting validation.
3rd of October 2020 at 7:22
comment awaiting validation.
23rd of November 2020 at 7:42
comment awaiting validation.
26th of December 2020 at 10:42
comment awaiting validation.
26th of December 2020 at 20:58
comment awaiting validation.
19th of January 2021 at 15:34
comment awaiting validation.
19th of January 2021 at 23:20
comment awaiting validation.
14th of March 2021 at 5:19
comment awaiting validation.
22nd of April 2021 at 12:16
comment awaiting validation.
11th of May 2021 at 17:02
comment awaiting validation.
3rd of August 2021 at 3:34
comment awaiting validation.
2nd of September 2021 at 21:33
comment awaiting validation.
4th of October 2021 at 1:27
comment awaiting validation.
19th of April 2022 at 3:46
comment awaiting validation.