Re: Setting Permissions in CGI

by "Christopher Rhodes" <precion(at)scott.net>

 Date:  Sat, 8 Jan 2000 18:51:06 -0600
 To:  "JON RYDBERG" <nsnt(at)home.com>
 Cc:  <hwg-basics(at)hwg.org>
 References:  tds home
  todo: View Thread, Original
I hate to suggest this one, but there is a telnet program built into
Windows95/98.  Just type in telnet after going through Start - Run.  Here is
a basic run down of the chmod attributes and how they apply when typing them
into a UNIX command line.

First the command is chmod.  Following that immediately is the following
characters:  u=user, g=group, o=other, or a=all.  The user privilege only
modifies the user settings as it says, the group modifies it so that the
files associate group can have access or not have access, other modifies so
that those outside the user and group rights can have access or not, and
lastly all modifies every access at once (sometimes a time saver).

After you have established what privilages you want to set for whom (user,
group, other, or all) you would put a plus or minux depending on what rights
you want to give or take away.  Here is a list of those rights and what they
mean: r=read, w=write, and x=execute.  Now you are doing a CGI script that I
would suppose you want others to have access too via the web so you would
want to set this script as readable and writeable to user, nothing for group
(unless you want too I'll give an example for this), and readable and
executeable for other.  The following command will do this:  chmod
u+rw,g-rwx,o+rx <name of cgi>
If you wanted to give group users readable and executable access:  chmod
u+rw,g+rx,o+rx

I believe it is easier to do in this format from the command line and easier
to remember for the most part.  There is a way to do it with numbers, but I
will leave that to the real gurus.

I hope this helps.

~Christopher

----- Original Message -----
From: JON RYDBERG <nsnt(at)home.com>
To: Michael Jon Muehlendorf <haoka(at)wi.tds.net>
Cc: <hwg-basics(at)hwg.org>
Sent: Sunday, January 09, 2000 11:30 AM
Subject: Re: Setting Permissions in CGI


> I really appreciate your response and it is in fact along the lines of
> what I thought was going on....WS FTP isn't actually changing the
> permissions. In fact it is sooo simple in WS FTP that the permissions
> are nothing more than check boxes or radio buttons for that matter.
>
> Here's the tricky part....I know little about the unix operating
> environment and its commands. As well as telnet. Is there a telnet
> application I can use to type in the permissions? And how might I go
> about it. Perhaps there is something online which explains all of this
> so that I do not have to bother you.
>
> But thanks for the advice!
>
> Jon
>
> Michael Jon Muehlendorf wrote:
> >
> > At 11:14 AM 1/9/00 -0500, JON RYDBERG wrote:
> >
> > Hello Jon!
> >
> > Do you have Telnet access to your server?  I can't speak authoritatively
on
> > WS FTP Pro, but I would guess that it isn't quite doing the CHMOD, at
least
> > where the server is concerned, especially if you are running the CHMOD
> > command in batch mode as you upload.  I think WS FTP Pro tries to do too
> > much at one time.  Just my opinion, though.  Perhaps some of the FTP
gurus
> > among us could tell you how to do it with FTP.  As for myself, I always
set
> > my permissions from a Telnet prompt...this way, I am assured that they
are
> > set correctly.  Matter of fact, after any CHMOD command that I do, I
always
> > follow it with the "ls -al" command so that I can actually see how the
> > permissions are set from the file listing.
> >
> > I run several virtual servers with several different providers, and the
> > determining factor in choozing any hosting package is the Telnet access.
I
> > don't know about the rest of the group, but I wouldn't retain a host
that
> > didn't allow me that access.
> >
> > HTH,
> >
> > >Good Day All-
> > >
> > >I have a recurring problem regarding setting my permissions on files in
> > >the cgi-bin. I am using WS FTP Pro as my FTP app which makes it pretty
> > >simple to perform a chmod on the file. No matter what I set my
> > >permissions to in FTP Pro, they still do not work. The scripts can not
> > >be executed.
> > >
> > >When I call my host, 9netave (No so hot on the support side by the
way),
> > >I always get the same response..."you needed to set your permissions"
> > >and they do whatever ???? and it works.
> > >
> > >Any thoughts here.
> > >
> > >Am I really missing something.
> > >
> > >Please advise,
> > >Jon
> > >
> > >
> >
> > Michael Jon Muehlendorf
> > E-Mail: mailto:coyote(at)scenic-bluffs.com
> > WWW: http://www.scenic-bluffs.com/fsg/
>

HTML: hwg-basics mailing list archives, maintained by Webmasters @ IWA