852bc1
#% define pre_release rc1
852bc1
%define pre_release %nil
852bc1
852bc1
Name:            cifs-utils
11a0c6
Version:         7.0
852bc1
Release:         1%{pre_release}%{?dist}
852bc1
Summary:         Utilities for mounting and managing CIFS mounts
852bc1
852bc1
License:         GPLv3
852bc1
URL:             http://linux-cifs.samba.org/cifs-utils/
852bc1
852bc1
BuildRequires:  gcc
852bc1
BuildRequires:  libcap-ng-devel libtalloc-devel krb5-devel keyutils-libs-devel autoconf automake libwbclient-devel pam-devel
852bc1
BuildRequires:  python3-docutils
852bc1
BuildRequires: make
852bc1
852bc1
Requires:        keyutils
852bc1
Requires(post):  /usr/sbin/alternatives
852bc1
Requires(preun): /usr/sbin/alternatives
852bc1
852bc1
Recommends: %{name}-info%{?_isa} = %{version}-%{release}
852bc1
852bc1
Source0:         https://download.samba.org/pub/linux-cifs/cifs-utils/%{name}-%{version}.tar.bz2
852bc1
852bc1
%description
852bc1
The SMB/CIFS protocol is a standard file sharing protocol widely deployed
852bc1
on Microsoft Windows machines. This package contains tools for mounting
852bc1
shares on Linux using the SMB/CIFS protocol. The tools in this package
852bc1
work in conjunction with support in the kernel to allow one to mount a
852bc1
SMB/CIFS share onto a client and use it as if it were a standard Linux
852bc1
file system.
852bc1
852bc1
%package devel
852bc1
Summary:        Files needed for building plugins for cifs-utils
852bc1
852bc1
%description devel
852bc1
The SMB/CIFS protocol is a standard file sharing protocol widely deployed
852bc1
on Microsoft Windows machines. This package contains the header file
852bc1
necessary for building ID mapping plugins for cifs-utils.
852bc1
852bc1
%package -n pam_cifscreds
852bc1
Summary:        PAM module to manage NTLM credentials in kernel keyring
852bc1
852bc1
%description -n pam_cifscreds
852bc1
The pam_cifscreds PAM module is a tool for automatically adding
852bc1
credentials (username and password) for the purpose of establishing
852bc1
sessions in multiuser mounts.
852bc1
852bc1
When a cifs filesystem is mounted with the "multiuser" option, and does
852bc1
not use krb5 authentication, it needs to be able to get the credentials
852bc1
for each user from somewhere. The pam_cifscreds module can be used to
852bc1
provide these credentials to the kernel automatically at login.
852bc1
852bc1
%prep
852bc1
%setup -q -n %{name}-%{version}%{pre_release}
852bc1
852bc1
%build
852bc1
fgrep -r -l '/usr/bin/env python' | xargs -n1 sed -i 's@/usr/bin/env python.*@%python3@g'
852bc1
autoreconf -i
852bc1
%configure --prefix=/usr ROOTSBINDIR=%{_sbindir}
852bc1
make %{?_smp_mflags}
852bc1
852bc1
%install
852bc1
rm -rf %{buildroot}
852bc1
make install DESTDIR=%{buildroot}
852bc1
mkdir -p %{buildroot}%{_sysconfdir}/%{name}
852bc1
mkdir -p %{buildroot}%{_sysconfdir}/request-key.d
852bc1
install -m 644 contrib/request-key.d/cifs.idmap.conf %{buildroot}%{_sysconfdir}/request-key.d
852bc1
install -m 644 contrib/request-key.d/cifs.spnego.conf %{buildroot}%{_sysconfdir}/request-key.d
852bc1
852bc1
%files
852bc1
%doc
852bc1
%{_bindir}/getcifsacl
852bc1
%{_bindir}/setcifsacl
852bc1
%{_bindir}/cifscreds
852bc1
%{_sbindir}/mount.cifs
852bc1
%{_sbindir}/mount.smb3
852bc1
%{_sbindir}/cifs.upcall
852bc1
%{_sbindir}/cifs.idmap
852bc1
%dir %{_libdir}/%{name}
852bc1
%{_libdir}/%{name}/idmapwb.so
852bc1
%{_mandir}/man1/getcifsacl.*
852bc1
%{_mandir}/man1/setcifsacl.*
852bc1
%{_mandir}/man1/cifscreds.*
852bc1
%{_mandir}/man8/cifs.upcall.*
852bc1
%{_mandir}/man8/cifs.idmap.*
852bc1
%{_mandir}/man8/mount.cifs.*
852bc1
%{_mandir}/man8/mount.smb3.*
852bc1
%{_mandir}/man8/idmapwb.*
852bc1
%dir %{_sysconfdir}/cifs-utils
852bc1
%ghost %{_sysconfdir}/cifs-utils/idmap-plugin
852bc1
%config(noreplace) %{_sysconfdir}/request-key.d/cifs.idmap.conf
852bc1
%config(noreplace) %{_sysconfdir}/request-key.d/cifs.spnego.conf
852bc1
852bc1
%post
852bc1
/usr/sbin/alternatives --install /etc/cifs-utils/idmap-plugin cifs-idmap-plugin %{_libdir}/%{name}/idmapwb.so 10
852bc1
852bc1
%preun
852bc1
if [ $1 = 0 ]; then
852bc1
	/usr/sbin/alternatives --remove cifs-idmap-plugin %{_libdir}/%{name}/idmapwb.so
852bc1
fi
852bc1
852bc1
%files devel
852bc1
%{_includedir}/cifsidmap.h
852bc1
852bc1
%files -n pam_cifscreds
852bc1
%{_libdir}/security/pam_cifscreds.so
852bc1
%{_mandir}/man8/pam_cifscreds.8.gz
852bc1
852bc1
# This subpackage also serves the purpose of avoiding a Python dependency on
852bc1
# the main package: https://bugzilla.redhat.com/show_bug.cgi?id=1909288.
852bc1
%package info
852bc1
Summary: Additional tools for querying information about CIFS mount
852bc1
Requires: %{name}%{?_isa} = %{version}-%{release}
852bc1
852bc1
%description info
852bc1
This subpackage includes additional tools for querying information
852bc1
about CIFS mount.
852bc1
852bc1
%files info
852bc1
%{_bindir}/smb2-quota
852bc1
%{_bindir}/smbinfo
852bc1
%{_mandir}/man1/smb2-quota.*
852bc1
%{_mandir}/man1/smbinfo.*
852bc1
852bc1
%changelog
11a0c6
* Mon Jan 30 2023 Pavel Filipenský <pfilipen@redhat.com> - 7.0-1
11a0c6
- Update to cifs-utils-7.0
11a0c6
- Resolves: rhbz#2163303
11a0c6
852bc1
* Wed Feb 02 2022 Alexander Bokovoy <abokovoy@redhat.com> - 6.14
852bc1
- Update to v6.14 release
852bc1
- Resolves: rhbz#1925956
852bc1
852bc1
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 6.11-5
852bc1
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
852bc1
  Related: rhbz#1991688
852bc1
852bc1
* Thu Apr 15 2021 Mohan Boddu <mboddu@redhat.com> - 6.11-4
852bc1
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
852bc1
852bc1
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 6.11-3
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
852bc1
852bc1
* Fri Dec 18 2020 Jonathan Lebon <jonathan@jlebon.com> - 6.11-2
852bc1
- Split out -info subpackage for smb2-quota and smbinfo
852bc1
  https://bugzilla.redhat.com/show_bug.cgi?id=1909288
852bc1
852bc1
* Mon Nov 02 2020 Alexander Bokovoy <abokovoy@redhat.com> - 6.11-1
852bc1
- Update to v6.11 release
852bc1
- Resolves: rhbz#1876400 - CVE-2020-14342 - cifs-utils: shell command injection
852bc1
852bc1
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 6.9-4
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
852bc1
852bc1
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 6.9-3
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
852bc1
852bc1
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 6.9-2
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
852bc1
852bc1
* Sun Apr 21 2019 Jeff Layton <jlayton@redhat.com>- 6.9-1
852bc1
- Update to v6.9 release
852bc1
852bc1
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 6.8-4
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
852bc1
852bc1
* Tue Jul 17 2018 Alexander Bokovoy <abokovoy@redhat.com> - 6.8-3
852bc1
- Use Python 3 version of rst2man
852bc1
852bc1
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 6.8-2
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
852bc1
852bc1
* Tue Apr 10 2018 Fedora Release Engineering <releng@fedoraproject.org> - 6.8-1
852bc1
- update to 6.8 release
852bc1
852bc1
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 6.7-6
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
852bc1
852bc1
* Tue Nov 07 2017 Jeff Layton <jlayton@redhat.com> - 6.7-5
852bc1
- more updates, switch to rst for manpages
852bc1
- update mount.cifs manpage to describe defaults better (BZ#1474539)
852bc1
852bc1
* Sun Oct 29 2017 Jeff Layton <jlayton@redhat.com> - 6.7-4
852bc1
- pull in all patches merged since 6.7 was released
852bc1
852bc1
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 6.7-3
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
852bc1
852bc1
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 6.7-2
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
852bc1
852bc1
* Thu Mar 02 2017 Jeff Layton <jlayton@redhat.com> - 6.7-1
852bc1
- update to 6.7 release
852bc1
852bc1
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 6.6-2
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
852bc1
852bc1
* Wed Sep 07 2016 Jeff Layton <jlayton@redhat.com> - 6.6-1
852bc1
- update to 6.6 release
852bc1
852bc1
* Wed Aug 24 2016 Jeff Layton <jlayton@redhat.com> - 6.5-3
852bc1
- more cifs.upcall cleanup work
852bc1
852bc1
* Wed Aug 24 2016 Jeff Layton <jlayton@redhat.com> - 6.5-2
852bc1
- clean up and streamline cifs.upcall handling for GSSAPI
852bc1
852bc1
* Thu Mar 10 2016 Sachin Prabhu <sprabhu@redhat.com> - 6.5-1
852bc1
- Update to 6.5 release
852bc1
- Fix URL to cifs-utils upstream source
852bc1
852bc1
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 6.4-5
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
852bc1
852bc1
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 6.4-4
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
852bc1
852bc1
* Wed Jan 21 2015 Ralf Corsépius <corsepiu@fedoraproject.org> - 6.4-3
852bc1
- Let package own %%{_sysconfdir}/cifs-utils (RHBZ#1184390).
852bc1
- Let package own %%{_libdir}/cifs-utils (RHBZ#1184391).
852bc1
852bc1
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 6.4-2
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
852bc1
852bc1
* Mon Aug 04 2014 Sachin Prabhu <sprabhu@redhat.com> - 6.4-1
852bc1
- update to 6.4 release
852bc1
852bc1
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 6.3-3
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
852bc1
852bc1
* Tue May 06 2014 Sachin Prabhu <sprabhu@redhat.com> 6.3-2
852bc1
- autoconf: allow PAM security install directory to be configurable
852bc1
- cifs: use krb5_kt_default() to determine default keytab location
852bc1
- cifskey: better use snprintf()
852bc1
- cifscreds: better error handling when key_search fails
852bc1
- cifscreds: better error handling for key_add
852bc1
852bc1
* Thu Jan 09 2014 Jeff Layton <jlayton@redhat.com> 6.3-1
852bc1
- update to 6.3 release
852bc1
852bc1
* Fri Dec 13 2013 Jeff Layton <jlayton@redhat.com> 6.2-5
852bc1
- fix linking of wbclient
852bc1
- add pam_cifscreds module and manpage
852bc1
852bc1
* Mon Oct 14 2013 Jeff Layton <jlayton@redhat.com> 6.2-4
852bc1
- fix use-after-free in asn1_write
852bc1
852bc1
* Fri Oct 11 2013 Jeff Layton <jlayton@redhat.com> 6.2-3
852bc1
- fixes for bugs reported by coverity:
852bc1
- update bad bit shift patch with one that patches getcifsacl.c too
852bc1
- remove some dead code from getcifsacl.c, asn1.c, and data_blob.c
852bc1
- fix bad handling of allocated memory in del_mtab in mount.cifs.c
852bc1
852bc1
* Wed Oct 09 2013 Jeff Layton <jlayton@redhat.com> 6.2-2
852bc1
- fix bad bit shift in setcifsacl.c
852bc1
852bc1
* Fri Oct 04 2013 Jeff Layton <jlayton@redhat.com> 6.2-1
852bc1
- update to 6.2 release
852bc1
852bc1
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 6.1-4
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
852bc1
852bc1
* Mon Jul 15 2013 Jeff Layton <jlayton@redhat.com> 6.1-3
852bc1
- allow setcifsacl to work if plugin can't be loaded (bz#984087)
852bc1
852bc1
* Mon Jul 15 2013 Jeff Layton <jlayton@redhat.com> 6.1-2
852bc1
- Convert idmapping plugin symlink to use alternatives system (bz#984088)
852bc1
852bc1
* Tue Jul 02 2013 Jeff Layton <jlayton@redhat.com> 6.1-1
852bc1
- update to 6.1 release
852bc1
852bc1
* Mon Mar 25 2013 Jeff Layton <jlayton@redhat.com> 6.0-1
852bc1
- update to 6.0 release
852bc1
852bc1
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.9-4
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
852bc1
852bc1
* Sun Jan 13 2013 Jeff Layton <jlayton@redhat.com> 5.9-3
852bc1
- comment fixes in cifsidmap.h
852bc1
852bc1
* Sun Jan 13 2013 Jeff Layton <jlayton@redhat.com> 5.9-2
852bc1
- fix regression in credential file handling
852bc1
852bc1
* Mon Jan 07 2013 Jeff Layton <jlayton@redhat.com> 5.9-1
852bc1
- update to 5.9
852bc1
- move mount.cifs to /usr/sbin per new packaging guidelines
852bc1
- add -devel package to hold cifsidmap.h
852bc1
852bc1
* Sun Nov 11 2012 Jeff Layton <jlayton@redhat.com> 5.8-1
852bc1
- update to 5.8
852bc1
852bc1
* Wed Nov 07 2012 Jeff Layton <jlayton@redhat.com> 5.7-3
852bc1
- update to latest patches queued for 5.8. More idmapping and ACL tool fixes.
852bc1
852bc1
* Sun Nov 04 2012 Jeff Layton <jlayton@redhat.com> 5.7-2
852bc1
- update to latest patches queued for 5.8. Mostly idmapping and ACL tool fixes.
852bc1
852bc1
* Tue Oct 09 2012 Jeff Layton <jlayton@redhat.com> 5.7-1
852bc1
- update to 5.7
852bc1
852bc1
* Fri Aug 24 2012 Jeff Layton <jlayton@redhat.com> 5.6-2
852bc1
- update to current upstream head
852bc1
852bc1
* Thu Jul 26 2012 Jeff Layton <jlayton@redhat.com> 5.6-1
852bc1
- update to 5.6
852bc1
852bc1
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.5-3
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
852bc1
852bc1
* Mon Jul 09 2012 Jeff Layton <jlayton@redhat.com> 5.5-2
852bc1
- remove -Werror flag
852bc1
- enable PIE and RELRO
852bc1
852bc1
* Wed May 30 2012 Jeff Layton <jlayton@redhat.com> 5.5-1
852bc1
- update to 5.5
852bc1
852bc1
* Wed Apr 25 2012 Jeff Layton <jlayton@redhat.com> 5.4-2
852bc1
- rebuild to fix dependencies due to libwbclient changes
852bc1
852bc1
* Wed Apr 18 2012 Jeff Layton <jlayton@redhat.com> 5.4-1
852bc1
- update to 5.4
852bc1
- add patch to fix up more warnings
852bc1
852bc1
* Mon Mar 19 2012 Jeff Layton <jlayton@redhat.com> 5.3-4
852bc1
- fix tests for strtoul success (bz# 800621)
852bc1
852bc1
* Wed Feb 08 2012 Jeff Layton <jlayton@redhat.com> 5.3-3
852bc1
- revert mount.cifs move. It's unnecessary at this point.
852bc1
852bc1
* Wed Feb 08 2012 Jeff Layton <jlayton@redhat.com> 5.3-2
852bc1
- move mount.cifs to /usr/sbin per new packaging guidelines
852bc1
852bc1
* Sat Jan 28 2012 Jeff Layton <jlayton@redhat.com> 5.3-1
852bc1
- update to 5.3
852bc1
852bc1
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.2-3
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
852bc1
852bc1
* Fri Dec 09 2011 Jeff Layton <jlayton@redhat.com> 5.2-2
852bc1
- add /etc/request-key.d files
852bc1
852bc1
* Fri Dec 09 2011 Jeff Layton <jlayton@redhat.com> 5.2-1
852bc1
- update to 5.2
852bc1
852bc1
* Fri Sep 23 2011 Jeff Layton <jlayton@redhat.com> 5.1-1
852bc1
- update to 5.1
852bc1
- add getcifsacl and setcifsacl to package
852bc1
852bc1
* Fri Jul 29 2011 Jeff Layton <jlayton@redhat.com> 5.0-2
852bc1
- mount.cifs: fix check_newline retcode check (bz# 726717)
852bc1
852bc1
* Wed Jun 01 2011 Jeff Layton <jlayton@redhat.com> 5.0-1
852bc1
- update to 5.0
852bc1
852bc1
* Mon May 16 2011 Jeff Layton <jlayton@redhat.com> 4.9-2
852bc1
- mount.cifs: pass unadulterated device string to kernel (bz# 702664)
852bc1
852bc1
* Fri Mar 04 2011 Jeff Layton <jlayton@redhat.com> 4.9-1
852bc1
- update to 4.9
852bc1
852bc1
* Tue Feb 08 2011 Jeff Layton <jlayton@redhat.com> 4.8.1-4
852bc1
- mount.cifs: reenable CAP_DAC_READ_SEARCH when mounting (bz# 675761)
852bc1
852bc1
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.8.1-3
852bc1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
852bc1
852bc1
* Tue Feb 01 2011 Jeff Layton <jlayton@redhat.com> 4.8.1-2
852bc1
- mount.cifs: don't update mtab if it's a symlink (bz# 674101)
852bc1
852bc1
* Fri Jan 21 2011 Jeff Layton <jlayton@redhat.com> 4.8.1-1
852bc1
- update to 4.8.1
852bc1
852bc1
* Sat Jan 15 2011 Jeff Layton <jlayton@redhat.com> 4.8-1
852bc1
- update to 4.8
852bc1
852bc1
* Tue Oct 19 2010 Jeff Layton <jlayton@redhat.com> 4.7-1
852bc1
- update to 4.7
852bc1
852bc1
* Fri Jul 30 2010 Jeff Layton <jlayton@redhat.com> 4.6-1
852bc1
- update to 4.6
852bc1
852bc1
* Tue Jun 01 2010 Jeff Layton <jlayton@redhat.com> 4.5-2
852bc1
- mount.cifs: fix parsing of cred= option (BZ#597756)
852bc1
852bc1
* Tue May 25 2010 Jeff Layton <jlayton@redhat.com> 4.5-1
852bc1
- update to 4.5
852bc1
852bc1
* Thu Apr 29 2010 Jeff Layton <jlayton@redhat.com> 4.4-3
852bc1
- mount.cifs: fix regression in prefixpath patch
852bc1
852bc1
* Thu Apr 29 2010 Jeff Layton <jlayton@redhat.com> 4.4-2
852bc1
- mount.cifs: strip leading delimiter from prefixpath
852bc1
852bc1
* Wed Apr 28 2010 Jeff Layton <jlayton@redhat.com> 4.4-1
852bc1
- update to 4.4
852bc1
852bc1
* Sat Apr 17 2010 Jeff Layton <jlayton@redhat.com> 4.3-2
852bc1
- fix segfault when address list is exhausted (BZ#583230)
852bc1
852bc1
* Fri Apr 09 2010 Jeff Layton <jlayton@redhat.com> 4.3-1
852bc1
- update to 4.3
852bc1
852bc1
* Fri Apr 02 2010 Jeff Layton <jlayton@redhat.com> 4.2-1
852bc1
- update to 4.2
852bc1
852bc1
* Tue Mar 23 2010 Jeff Layton <jlayton@redhat.com> 4.1-1
852bc1
- update to 4.1
852bc1
852bc1
* Mon Mar 08 2010 Jeff Layton <jlayton@redhat.com> 4.0-2
852bc1
- fix bad pointer dereference in IPv6 scopeid handling
852bc1
852bc1
* Wed Mar 03 2010 Jeff Layton <jlayton@redhat.com> 4.0-1
852bc1
- update to 4.0
852bc1
- minor specfile fixes
852bc1
852bc1
* Fri Feb 26 2010 Jeff Layton <jlayton@redhat.com> 4.0-1rc1
852bc1
- update to 4.0rc1
852bc1
- fix prerelease version handling
852bc1
852bc1
* Mon Feb 08 2010 Jeff Layton <jlayton@redhat.com> 4.0a1-1
852bc1
- first RPM package build
852bc1