Date: Mon, 21 May 2018 00:35:34 +0700 From: Eugene Grosbein <eugen@grosbein.net> To: tech-lists <tech-lists@zyxst.net>, freebsd-questions@freebsd.org Cc: freebsd-stable@freebsd.org Subject: Re: ftpd in base Message-ID: <5B01B1E6.2090106@grosbein.net> In-Reply-To: <bc63650d-ada4-59ac-0f30-6fed5fc69b98@zyxst.net> References: <bc63650d-ada4-59ac-0f30-6fed5fc69b98@zyxst.net>
next in thread | previous in thread | raw e-mail | index | archive | help
20.05.2018 18:49, tech-lists wrote: > Hi, > > context: 11.2-BETA2 #0 r333924/amd64 > > I'm trying to get chrooted ftpd (in base) to write files uploaded to the user dir as mode 666 (umask 111). > I have a line in inetd.conf that looks like this: > > ftp stream tcp nowait root /usr/libexec/ftpd ftpd -l -u 111 > > The user logs in OK and uploads OK but the perms are always 644. There is no login.conf overriding this. By default, there IS login class "default" in our /etc/login.conf with 0644 umask value. > The users shell is /usr/sbin/nologin as these are ftp-only accounts. This exact config works fine on linux (specifically ubuntu) > > Why is ftpd ignoring -u ? How can I fix? Our ftpd applies -u and by default instantly overrides it with login class setting. You should add your own login class to /etc/login.conf with 0111 value then run "cap_mkdb /etc/login.conf" and "pw usermod ftpusername -L ftploginclass"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5B01B1E6.2090106>