Set umask of FTP 'put'

Set umask of FTP 'put'

Post by Walter Goodma » Fri, 17 Apr 1998 04:00:00




> Please remove .NOSPAM in my email address when reply by mail. Thanks.


> >Hello all,

> >Does anyone know how to control the umask of 'put' files in FTP server?
> >I always get rw-rw-r-- when I log on my FTP server and put files in any
> >directory
> >that I have write permission.

> >Thanks.

> >Regards,

> >SS

On an HP with 9.x or 10.x you can edit /etc/inetd.conf and put the
protection mask in on the ftpd line.  Of course you will need to re-start
the inetd daemon.

Later

Walter Goodman

 
 
 

Set umask of FTP 'put'

Post by Mr. Make Belie » Fri, 17 Apr 1998 04:00:00




> > >Does anyone know how to control the umask of 'put' files in FTP server?
> > >I always get rw-rw-r-- when I log on my FTP server and put files in any
> > >directory
> > >that I have write permission.

> On an HP with 9.x or 10.x you can edit /etc/inetd.conf and put the
> protection mask in on the ftpd line.  Of course you will need to re-start
> the inetd daemon.

From the Solaris FAQ:

3.48) How can I prevent daemons from creating mode 666 files?

    By default, all daemons inherit the umask 0 from init.
    This is most problematic for a service like ftp, which in a
    standard configuration leaves all uploaded files with mode 666.

    To get daemons to use another umask execute the following
    commands in /bin/sh and reboot:

    umask 022  # make sure umask.sh gets created with the proper mode
    echo "umask 022" > /etc/init.d/umask.sh
    for d in /etc/rc?.d
    do
        ln /etc/init.d/umask.sh $d/S00umask.sh
    done

    Note: the trailing ".sh" of the scriptname is important, if
    you don't specify it, the script will will be executed in a
    sub-shell, not in the main shell that executes all other scripts.

 
 
 

Set umask of FTP 'put'

Post by DFRusse » Fri, 17 Apr 1998 04:00:00


Start ftp and type "site help"


|>
|> > Please remove .NOSPAM in my email address when reply by mail. Thanks.
|> >

|> > >Hello all,
|> > >
|> > >Does anyone know how to control the umask of 'put' files in FTP server?
|> > >I always get rw-rw-r-- when I log on my FTP server and put files in any
|> > >directory
|> > >that I have write permission.
|> > >
|> > >Thanks.
|> > >
|> > >
|> > >Regards,
|> > >
|> > >SS
|> > >
|> > >
|>
|>
|> On an HP with 9.x or 10.x you can edit /etc/inetd.conf and put the
|> protection mask in on the ftpd line.  Of course you will need to re-start
|> the inetd daemon.
|>
|> Later
|>
|> Walter Goodman
|>

--
Views expressed are personal and not necessarily shared by my employer.

 
 
 

Set umask of FTP 'put'

Post by S S Wa » Sat, 18 Apr 1998 04:00:00


Hello all,

Does anyone know how to control the umask of 'put' files in FTP server?
I always get rw-rw-r-- when I log on my FTP server and put files in any
directory
that I have write permission.

Thanks.

Regards,

SS

 
 
 

Set umask of FTP 'put'

Post by S S Wa » Sat, 18 Apr 1998 04:00:00


Please remove .NOSPAM in my email address when reply by mail. Thanks.


>Hello all,

>Does anyone know how to control the umask of 'put' files in FTP server?
>I always get rw-rw-r-- when I log on my FTP server and put files in any
>directory
>that I have write permission.

>Thanks.

>Regards,

>SS

 
 
 

Set umask of FTP 'put'

Post by Eric Luii » Wed, 22 Apr 1998 04:00:00



: Hello all,

: Does anyone know how to control the umask of 'put' files in FTP server?
: I always get rw-rw-r-- when I log on my FTP server and put files in any
: directory
: that I have write permission.

In general, the ftpd daemon should be called from an environment
(shell) with a umask restriction. Depending on the UNIX variant,
one can set this in the inetd script, the Sxx boot files or just
by replacing the ftpd executable by a script with umask calling
the moved (old) ftpd executable.
We have implemented this since 10 years in various UNIX variants.

Another work around for people with system administrators that
keep this too open is to "move systems": telnet to the system
you want to "put" to and use an ftp get grom that system.
The get file permissions are derived from your user environment
and thus are completely under YOUR control.

Regards, Eric

--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Eric Luiijf                              TNO Physics and Electronics Laboratory
Telematics and Information Security      P.O. Box 96864, 2509 JG The Hague
Webmaster http://www.tno.nl/instit/fel   The Netherlands
                                         Phone: +31 70 3740312

 
 
 

1. in ftp, put put *`date '+%Y%m%d'` doesn't work

In ftp I want to put a file from that ends in the current yyyymmdd.  eg.
filename_20000119 would be a the filename I want to put as it has the
current date (when I wrote this message) Using the following doesn't
work, any ideas?

put *_`date '+%Y%m%d'`

2. SMP problems!!!!!!!!!!

3. trouble with /etc/passwd

4. Anyone has the nVidia-released TNT2 drivers?

5. Bash 'umask' builtin doesn't set 'x' permissions?

6. Time Problem on new SCO Pentium System

7. Slow FTP 'gets', Fast 'puts'???

8. FTP: logging things other than 'get' and 'put'

9. Setting umask for ftp put?

10. 'put' files from unix to VMS via batch ftp.

11. FTP 'put' file permissions