1833870 Members
1540 Online
110063 Solutions
New Discussion

Re: FTP Permissions

 
SOLVED
Go to solution
mhess_1
Advisor

FTP Permissions

I am trying to set FTP permissions for a specific user account on my HPUX 11i machine. I can FTP to the machine as 'root', but not as this other user. I've check SAM and the /etc/ftpusers file, but must be missing something. Can you please tell me other areas or files to check in order to give a specific user FTP permission (so I can log onto my machine as this user). OR perhaps I missed something in SAM or with the ftpsuers file. Any ideas are welcome. Thanks!
10 REPLIES 10
Steven Schweda
Honored Contributor

Re: FTP Permissions

> [...] HPUX 11i [...]

Not a very complete description.

Does this user have a legal shell?

"man ftpd":

[...]
+ The user must have a standard shell returned by getusershell().
[...]


"man getusershell":


[...] as defined in the file /etc/shells (see
shells(4)).
[...]


"man shells":

[...]
DESCRIPTION
/etc/shells is an ASCII file containing a list of legal shells on the
system. Each shell is listed in the file by its absolute path name.
[...]
Safarali
Valued Contributor

Re: FTP Permissions

hi
what is the output of ftpusers files

give me the output of
grep user /etc/passwd

more /etc/shells

Regards
Safar
Jeeshan
Honored Contributor

Re: FTP Permissions

Hi

for restricting ftp access you can add his user name in ftpusers file in /etc/ftpd directory.
a warrior never quits
OFC_EDM
Respected Contributor

Re: FTP Permissions

I suggest not even using FTP. Isn't this still a big security issue?

Why not implement ssh/scp and use keys to restrict users?

Just my 0.5 cents :)
The Devil is in the detail.
mhess_1
Advisor

Re: FTP Permissions

All,

I am back on this taks of trying to FTP to my HPUX 11i machine. As I mentioned in my original post several months ago, I can FTP to this machine (from a PC using command line, Filezilla and CuteFTP) as user 'root' but not as user 'mark' (or any other user besides root). I want to use FTP instead of SSH because 1) I am not worried about security between my PC and HPUX box and 2) I am using a utility in CuteFTP to automatically transfer files from my PC to HPUX box. The main problem is that if I am user root, the permissions of the files are set for root and therefore unaccessible by routine used by user 'mark'. I also don't know how to do a CHMOD on my PC to automatically change permissions on that end. So, I'd really just like to be able to FTP as user mark.

To answer some of your questions from a while back:

1) SAM puts the ftpusers file in /etc not /etc/ftpd, but I tried putting this file in both placese with no success. It is my understanding that this file contains 'denied' users and so 'mark' is not in this file.

2) I do not have the shells file in /etc on my HPUX machine

3) The line for mark in the passwd file is: "mark:Zvt8jcUmTS:205:20:,,,:/users/mark:/bin/csh

What else can I look at or try. Please keep in mind that I am a novice UNIX user, so be gentle.

Thanks,

Mark
Patrick Wallek
Honored Contributor
Solution

Re: FTP Permissions

You may need to manually create the /etc/shells file:

The contents should be something like:

/sbin/sh
/usr/bin/sh
/bin/csh
/usr/bin/csh
/bin/ksh
/usr/bin/ksh

Steven Schweda
Honored Contributor

Re: FTP Permissions

Unless I've missed it, you still haven't
revealed what, exactly, doesn't work. "I
can't do something", tells neither what you
tried to do, nor what happened when you tried
to do it.

Using a command-line FTP client program on
the Windows system (assuming that "my PC"
_is_ a Windows system) might expose some
details which a fancy-GUI FTP client program
might hide. (Of course, that won't help
unless you report those details.)

Your HP-UX version is still a mystery.

uname -a

> 2) I do not have the shells file in /etc
> on my HPUX machine

Have you tried creating one?
mhess_1
Advisor

Re: FTP Permissions

Patrick,

You win! Easy answer. Creating the shells file worked.

Thanks!
Kenan Erdey
Honored Contributor

Re: FTP Permissions

man getusershell:

If /etc/shells does not exist or is not readable, getusershell() returns the following standard system shells:

/sbin/sh /usr/bin/sh /usr/bin/rsh /usr/bin/ksh /usr/bin/rksh /usr/bin/csh /usr/bin/keysh

you have /bin/csh in your passwd. that's why you need to create /etc/shells file

Computers have lots of memory but no imagination
Steven Schweda
Honored Contributor

Re: FTP Permissions

> man getusershell:

That didn't seem to work in April. Reading
is _so_ hard sometimes (for some people).