libpwquality-vl.spec 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204
  1. Summary: A library for password generation and password quality checking
  2. Name: libpwquality
  3. Version: 1.4.0
  4. Release: 1%{?_dist_release}
  5. # The package is BSD licensed with option to relicense as GPLv2+
  6. # - this option is redundant as the BSD license allows that anyway.
  7. License: BSD or GPLv2+
  8. Group: System Environment/Base
  9. Source0: https://github.com/libpwquality/libpwquality/releases/download/libpwquality-%{version}/libpwquality-%{version}.tar.bz2
  10. Patch1: libpwquality-1.4.0-covscan.patch
  11. %global _moduledir /%{_lib}/security
  12. %global _secconfdir %{_sysconfdir}/security
  13. Requires: cracklib-dicts >= 2.8
  14. Requires: pam
  15. BuildRequires: cracklib
  16. BuildRequires: gettext
  17. BuildRequires: pam-devel
  18. BuildRequires: python-devel
  19. BuildRequires: python-rpm-macros
  20. BuildRequires: python3-devel
  21. BuildRequires: python3-rpm-macros
  22. URL: https://fedorahosted.org/libpwquality/
  23. # we don't want to provide private python extension libs
  24. %define __provides_exclude_from ^(%{python_sitearch}|%{python3_sitearch})/.*\.so$.
  25. Vendor: Project Vine
  26. Distribution: Vine Linux
  27. %description
  28. This is a library for password quality checks and generation
  29. of random passwords that pass the checks.
  30. This library uses the cracklib and cracklib dictionaries
  31. to perform some of the checks.
  32. %package devel
  33. Group: Development/Libraries
  34. Summary: Files needed for developing PAM-aware applications and modules for PAM
  35. Requires: libpwquality = %{version}-%{release}
  36. Requires: pkgconfig
  37. %description devel
  38. Files needed for development of applications using the libpwquality
  39. library.
  40. See the pwquality.h header file for the API.
  41. %package -n python-pwquality
  42. Group: Development/Libraries
  43. Summary: Python bindings for the libpwquality library
  44. Requires: libpwquality = %{version}-%{release}
  45. %description -n python-pwquality
  46. This is pwquality Python module that provides Python bindings
  47. for the libpwquality library. These bindings can be used
  48. for easy password quality checking and generation of random
  49. pronounceable passwords from Python applications.
  50. %package -n python3-pwquality
  51. Group: Development/Libraries
  52. Summary: Python bindings for the libpwquality library
  53. Requires: libpwquality = %{version}-%{release}
  54. %description -n python3-pwquality
  55. This is pwquality Python module that provides Python bindings
  56. for the libpwquality library. These bindings can be used
  57. for easy password quality checking and generation of random
  58. pronounceable passwords from Python applications.
  59. %prep
  60. %setup -q
  61. %patch1 -p1 -b .covscan
  62. rm -rf %{py3dir}
  63. cp -a . %{py3dir}
  64. %build
  65. %configure \
  66. --with-securedir=%{_moduledir} \
  67. --with-pythonsitedir=%{python_sitearch} \
  68. --with-python-binary=%{__python} \
  69. --disable-static
  70. make %{?_smp_mflags}
  71. pushd %{py3dir}
  72. %configure \
  73. --with-securedir=%{_moduledir} \
  74. --with-pythonsitedir=%{python3_sitearch} \
  75. --with-python-binary=%{__python3} \
  76. --disable-static
  77. make %{?_smp_mflags}
  78. popd
  79. %install
  80. make install DESTDIR=$RPM_BUILD_ROOT INSTALL='install -p'
  81. pushd %{py3dir}
  82. make -C python install DESTDIR=$RPM_BUILD_ROOT INSTALL='install -p'
  83. popd
  84. pushd $RPM_BUILD_ROOT%{_libdir}
  85. mv libpwquality.so.* $RPM_BUILD_ROOT/%{_lib}/
  86. ln -sf ../../%{_lib}/libpwquality.so.*.* libpwquality.so
  87. popd
  88. rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
  89. rm -f $RPM_BUILD_ROOT%{_moduledir}/*.la
  90. mkdir $RPM_BUILD_ROOT%{_secconfdir}/pwquality.conf.d
  91. %find_lang libpwquality
  92. %check
  93. # Nothing yet
  94. %post -p /sbin/ldconfig
  95. %postun -p /sbin/ldconfig
  96. %files -f libpwquality.lang
  97. %defattr(-,root,root,-)
  98. %{!?_licensedir:%global license %%doc}
  99. %license COPYING
  100. %doc README NEWS AUTHORS
  101. %{_bindir}/pwmake
  102. %{_bindir}/pwscore
  103. %{_moduledir}/pam_pwquality.so
  104. /%{_lib}/libpwquality.so.*
  105. %config(noreplace) %{_secconfdir}/pwquality.conf
  106. %{_mandir}/man1/*
  107. %{_mandir}/man5/*
  108. %{_mandir}/man8/*
  109. %files devel
  110. %defattr(-,root,root,-)
  111. %{_includedir}/pwquality.h
  112. %{_libdir}/libpwquality.so
  113. %{_libdir}/pkgconfig/*.pc
  114. %{_mandir}/man3/*
  115. %files -n python-pwquality
  116. %defattr(-,root,root,-)
  117. %{python_sitearch}/pwquality.so
  118. %{python_sitearch}/*.egg-info
  119. %files -n python3-pwquality
  120. %defattr(-,root,root,-)
  121. %{python3_sitearch}/*.so
  122. %{python3_sitearch}/*.egg-info
  123. %changelog
  124. * Wed Nov 28 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.4.0-1
  125. - new upstream release.
  126. - added python3 support.
  127. * Sun Nov 01 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.3.0-1
  128. - new upstream release
  129. * Sun Oct 26 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.2.4-1
  130. - new upstream release
  131. * Sat Jan 04 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.2.3-2
  132. - rebuild with VineSeed environment
  133. * Sat Oct 26 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.2.3-1
  134. - new upstream release
  135. * Sun Sep 30 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.2.0-1
  136. - initial build for Vine Linux
  137. * Thu Aug 16 2012 Tomas Mraz <tmraz@redhat.com> 1.2.0-1
  138. - add maxsequence check for too long monotonic character sequence.
  139. - clarified alternative licensing to GPLv2+.
  140. - add local_users_only option to skip the pwquality checks for
  141. non-locals. (thanks to Stef Walter)
  142. * Wed Jun 13 2012 Tomas Mraz <tmraz@redhat.com> 1.1.1-1
  143. - use rpm built-in filtering of provides (rhbz#830153)
  144. - remove strain debug fprintf() (rhbz#831567)
  145. * Thu May 24 2012 Tomas Mraz <tmraz@redhat.com> 1.1.0-1
  146. - fix leak when throwing PWQError exception
  147. - added pkgconfig file
  148. - call the simplicity checks before the cracklib check
  149. - add enforce_for_root option to the PAM module
  150. - updated translations from Transifex
  151. * Thu Dec 8 2011 Tomas Mraz <tmraz@redhat.com> 1.0.0-1
  152. - added a few additional password quality checks
  153. - bugfix in configuration file parsing
  154. * Fri Nov 11 2011 Tomas Mraz <tmraz@redhat.com> 0.9.9-1
  155. - added python bindings and documentation
  156. * Mon Oct 10 2011 Tomas Mraz <tmraz@redhat.com> 0.9-2
  157. - fixes for problems found in review (missing BR on pam-devel,
  158. License field, Source URL, Require pam, other cleanups)
  159. * Mon Oct 3 2011 Tomas Mraz <tmraz@redhat.com> 0.9-1
  160. - first spec file for libpwquality