Operating System - HP-UX
1833162 Members
4110 Online
110051 Solutions
New Discussion

Re: ftp permissions on a files

 
SOLVED
Go to solution
The Gunners
Regular Advisor

ftp permissions on a files

Hi there , I got a request from the Apps Team for the following , not sure how to proceed . Would appreciate any help/advice

When users ftp a file , the permissions at the moment are -rw-r----- 1 rblab_dd rb 2583 Jul 15 15:15 dd2306092.csv (as an example)

We require -rw-rw-rw- 1 rblab_dd rb 2583 Jul 15 15:15 dd2306092.csv
8 REPLIES 8
Steven Schweda
Honored Contributor

Re: ftp permissions on a files

A Forum search for, say,
ftp chmod
might reveal something.

Some description of the software on the
systems involved here, and their roles, might
also be interesting,
Walt Watson
Advisor

Re: ftp permissions on a files

Permissions on the file are passed by the profile of the account doing the upload. If you want to expand them, add a script to chgmod on the file(s) after teh upload to your desired security profile. Do suggest against world writable files as your question implies - auditors will haev a field day with that.
Ganesan R
Honored Contributor
Solution

Re: ftp permissions on a files

Hi Davey,

You need to set the umask value for ftpd daemon in /etc/inetd.conf like below.

ftp stream tcp nowait root /usr/lbin/ftpd ftpd -l -u 000

After that you will have to re-read the conf file using this command.
#inetd -c
Best wishes,

Ganesh.
The Gunners
Regular Advisor

Re: ftp permissions on a files

Hi Ganesan R , and everyone so far thanks for the replies ,
Specifically Ganesan R , if I carry out the tasks you advise , will that affect ftp running ? , and also will it affect other users of a different Application that are running ftp ? my gut feeling is it wont cause any major issue ?
Thanks a mill
The Gunners
Regular Advisor

Re: ftp permissions on a files

Hi Ganesan R ,
Just an update , I added in the -u 000 to that line in the inetd.conf as you suggessted and ran the
inetd -c. Got the Apps team to re-run the ftp from 2 users (which are in the same group by the way) and have two different results

Hi Dave

Still the same for rblab_dd

-rw-r----- 1 rblab_dd rb 1535339 Jul 29 10:37 ELAINE.DAT

For rbsys it is OK

-rw-rw-rw- 1 rbsys rb 1535339 Jul 29 10:39 ELAINE.DAT
Ganesan R
Honored Contributor

Re: ftp permissions on a files

Hi,

I don't know, why it is not working for one user. If you set the umask value of 000 for ftpd daemon, then all the incoming ftp files will be created with 666.

By the way, could you confirm the the umask value for both the users? Just verify though it is not going to make any changes.
Best wishes,

Ganesh.
Mel Burslan
Honored Contributor

Re: ftp permissions on a files

Make sure rblab_dd user logged off and logged back in. People sometimes expect miracles as I see more and more frequently. If they are using the same session that they started prior to making inetd changes, it will not take effect for them unless they quit the ftp session and come back in. This is especially true for the graphical ftp tools, which seem to be impervious to ftp connection timeouts. It won't hurt to try even if it is not the case.
HTH
________________________________
UNIX because I majored in cryptology...
The Gunners
Regular Advisor

Re: ftp permissions on a files

Thanks a mill guys , its working now , a new session was logged in and tested and this did the trick. Super guys , points on the way!