diff --git a/pure-ftpd.changes b/pure-ftpd.changes index 0a607cc..06e48af 100644 --- a/pure-ftpd.changes +++ b/pure-ftpd.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Wed Oct 4 08:49:26 UTC 2023 - Thorsten Kukuk + +- Add pure-ftpd.ftpusers, the netcfg one is not maintained, outdated + and will be removed. +- pure-ftpd.pam: use own copy of ftpusers. +- Remove hard systemd requires, it's not necessary. + ------------------------------------------------------------------- Mon Jan 16 11:10:54 UTC 2023 - Stefan Schubert diff --git a/pure-ftpd.ftpusers b/pure-ftpd.ftpusers new file mode 100644 index 0000000..2883e75 --- /dev/null +++ b/pure-ftpd.ftpusers @@ -0,0 +1,16 @@ +# +# ftpusers This file describes the names of the users that may +# _*NOT*_ log into the system via the FTP server. +# This usually includes "root", "uucp", "news" and the +# like, because those users have too much power to be +# allowed to do "just" FTP... +# +adm +bin +daemon +games +mail +news +nobody +root +uucp diff --git a/pure-ftpd.pamd b/pure-ftpd.pamd index 08c1377..74ca64b 100644 --- a/pure-ftpd.pamd +++ b/pure-ftpd.pamd @@ -1,5 +1,5 @@ #%PAM-1.0 -auth required pam_listfile.so item=user sense=deny file=/etc/ftpusers onerr=succeed +auth required pam_listfile.so item=user sense=deny file=/etc/pure-ftpd/ftpusers onerr=succeed auth required pam_shells.so auth include common-auth account include common-account diff --git a/pure-ftpd.spec b/pure-ftpd.spec index 5182e5b..8684c0c 100644 --- a/pure-ftpd.spec +++ b/pure-ftpd.spec @@ -29,6 +29,7 @@ Source2: %{name}.keyring Source3: %{name}.init Source4: %{name}.pamd Source5: %{name}.xinetd +Source6: %{name}.ftpusers Source8: %{name}.service # PATCH-FEATURE-OPENSUSE %{name}-1.0.20_config.patch -- Custom service configs. Patch0: %{name}-1.0.20_config.patch @@ -57,7 +58,6 @@ Provides: pureftpd = %{version}-%{release} BuildRequires: postgresql-server-devel %endif BuildRequires: pkgconfig(systemd) -%{?systemd_requires} Requires(pre): user(ftp) %description @@ -117,7 +117,7 @@ CFLAGS="%{optflags} -I%{_includedir}/mysql" install -dD -m 0755 \ %{buildroot}%{_sysconfdir}/{%{name},%{name}/vhosts,openldap/schema} install -m 0644 pure-ftpd.conf %{buildroot}%{_sysconfdir}/%{name} - +install -m 0600 %{SOURCE6} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/ftpusers %if 0%{?suse_version} > 1500 install -dD -m 0755 %{buildroot}%{_pam_vendordir} install -m 0644 %{SOURCE4} %{buildroot}%{_pam_vendordir}/pure-ftpd @@ -188,6 +188,7 @@ fi %config %{_sysconfdir}/pam.d/pure-ftpd %endif %config(noreplace) %{_sysconfdir}/%{name}/pure-ftpd.conf +%config(noreplace) %{_sysconfdir}/%{name}/ftpusers %config(noreplace) %{_sysconfdir}/apparmor/profiles/extras/usr.sbin.pure-ftpd %{_unitdir}/%{name}.service