stunnel-vl.spec 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494
  1. %define ver 5.32
  2. %define rel 1
  3. Summary: An SSL-encrypting socket wrapper
  4. Name: stunnel
  5. Version: %{ver}
  6. Release: %{rel}%{?_dist_release}
  7. License: GPLv2
  8. Group: Applications/Internet
  9. URL: https://www.stunnel.org/
  10. Source0: https://www.stunnel.org/downloads/stunnel-%{version}.tar.gz
  11. Source1: https://www.stunnel.org/downloads/stunnel-%{version}.tar.gz.asc
  12. Source2: Certificate-Creation
  13. Source3: sfinger.xinetd
  14. Source4: stunnel-sfinger.conf
  15. Source5: pop3-redirect.xinetd
  16. Source6: stunnel-pop3s-client.conf
  17. Source100: stunnel.init
  18. Patch0: stunnel-5.25-authpriv.patch
  19. Patch1: stunnel-5.25-config.patch
  20. Buildroot: %{_tmppath}/stunnel-root
  21. # util-linux is needed for rename
  22. BuildRequires: openssl-devel
  23. BuildRequires: pkgconfig
  24. BuildRequires: tcp_wrappers
  25. BuildRequires: util-linux
  26. Vendor: Project Vine
  27. Distribution: Vine Linux
  28. Packager: iwaim
  29. %description
  30. Stunnel is a socket wrapper which can provide SSL (Secure Sockets
  31. Layer) support to ordinary applications. For example, it can be used
  32. in conjunction with imapd to create an SSL secure IMAP server.
  33. %prep
  34. %setup -q
  35. %patch0 -p1 -b .authpriv
  36. %patch1 -p1 -b .config
  37. %build
  38. CFLAGS="$RPM_OPT_FLAGS -fPIC"; export CFLAGS
  39. if pkg-config openssl ; then
  40. CFLAGS="$CFLAGS `pkg-config --cflags openssl`";
  41. LDFLAGS="`pkg-config --libs-only-L openssl`"; export LDFLAGS
  42. fi
  43. %configure --disable-fips --enable-ipv6 \
  44. CPPFLAGS="-UPIDFILE -DPIDFILE='\"%{_localstatedir}/run/stunnel.pid\"'"
  45. make LDADD="-pie -Wl,-z,defs,-z,relro,-z,now"
  46. %install
  47. rm -rf $RPM_BUILD_ROOT
  48. mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/stunnel/conf.d
  49. touch $RPM_BUILD_ROOT%{_sysconfdir}/stunnel/stunnel.pem
  50. make install DESTDIR=$RPM_BUILD_ROOT
  51. # Move the translated man pages to the right subdirectories, and strip off the
  52. # language suffixes.
  53. for lang in pl ; do
  54. mkdir -p $RPM_BUILD_ROOT/%{_mandir}/${lang}/man8
  55. mv $RPM_BUILD_ROOT/%{_mandir}/man8/*.${lang}.8* $RPM_BUILD_ROOT/%{_mandir}/${lang}/man8/
  56. rename ".${lang}" "" $RPM_BUILD_ROOT/%{_mandir}/${lang}/man8/*
  57. done
  58. install -d -m755 %{buildroot}%{_initdir}
  59. install -m755 %{SOURCE100} %{buildroot}%{_initdir}/stunnel
  60. install -d m755 %{buildroot}%{_sysconfdir}/sysconfig
  61. cat <<EOF > %{buildroot}%{_sysconfdir}/sysconfig/stunnel
  62. ENABLED=0
  63. EOF
  64. mkdir -p srpm-docs
  65. cp %{SOURCE2} %{SOURCE3} %{SOURCE4} %{SOURCE5} %{SOURCE6} srpm-docs
  66. %clean
  67. rm -rf $RPM_BUILD_ROOT
  68. %pre
  69. getent group stunnel >/dev/null || groupadd -r stunnel
  70. getent passwd stunnel >/dev/null || \
  71. useradd -r -g stunnel -d /dev/null -s /sbin/nologin \
  72. -c "stunnel service account" stunnel
  73. %post
  74. /sbin/chkconfig --add stunnel
  75. %preun
  76. if [ $1 -eq 0 ]; then
  77. /sbin/chkconfig --del stunnel
  78. fi
  79. %files
  80. %defattr(-,root,root)
  81. %doc AUTHORS BUGS ChangeLog COPY* CREDITS PORTS README TODO
  82. %doc tools/stunnel.conf-sample
  83. %doc srpm-docs/*
  84. %lang(en) %doc doc/en/*
  85. %lang(po) %doc doc/pl/*
  86. %{_bindir}/stunnel
  87. %{_initdir}/stunnel
  88. %exclude %{_bindir}/stunnel3
  89. %exclude %{_datadir}/doc/stunnel
  90. %{_libdir}/stunnel
  91. %exclude %{_libdir}/stunnel/libstunnel.la
  92. %{_mandir}/man8/stunnel.8*
  93. %lang(pl) %{_mandir}/pl/man8/stunnel.8*
  94. %dir %{_sysconfdir}/%{name}
  95. %dir %{_sysconfdir}/%{name}/conf.d
  96. %exclude %{_sysconfdir}/stunnel/stunnel.conf-sample
  97. %exclude %{_sysconfdir}/stunnel/stunnel.pem
  98. %config(noreplace) %{_sysconfdir}/sysconfig/%{name}
  99. %changelog
  100. * Tue May 10 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.32-1
  101. - new upstream release.
  102. * Tue Mar 15 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.31-1
  103. - new upstream release.
  104. * Fri Nov 6 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.25-1
  105. - new upstream release.
  106. - fixed dates in %%changelog.
  107. - updated all patches.
  108. * Tue Jan 15 2013 IWAI, Masaharu <iwai@alib.jp> 4.54-1
  109. - initial build for Vine Linux
  110. *Mon Dec 10 2012 Avesh Agarwal <avagarwa@redhat.com> - 4.54-2
  111. - 884183: support for full relro.
  112. *Tue Oct 16 2012 Avesh Agarwal <avagarwa@redhat.com> - 4.54-1
  113. - New upstream realease 4.54
  114. - Updated local patches
  115. * Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.53-2
  116. - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
  117. * Mon May 14 2012 Avesh Agarwal <avagarwa@redhat.com> - 4.53-1
  118. - New upstream realease 4.53
  119. - Updated local patches
  120. * Tue Mar 6 2012 Avesh Agarwal <avagarwa@redhat.com> - 4.52-1
  121. - New upstream realease 4.52
  122. - Updated local patches
  123. * Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.50-2
  124. - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
  125. * Tue Jan 3 2012 Avesh Agarwal <avagarwa@redhat.com> - 4.50-1
  126. - New upstream realease 4.50
  127. - Updated local patches
  128. * Tue Sep 20 2011 Avesh Agarwal <avagarwa@redhat.com> - 4.44-1
  129. - New upstream realease 4.44
  130. - Updated local patches
  131. * Fri Aug 19 2011 Avesh Agarwal <avagarwa@redhat.com> - 4.42-1
  132. - New upstream realease 4.42
  133. - Updated local patches
  134. - Fixes #732069
  135. * Mon Aug 1 2011 Avesh Agarwal <avagarwa@redhat.com> - 4.41-1
  136. - New upstream realease 4.41
  137. - Updated local patches to match the new release
  138. * Tue Jun 28 2011 Avesh Agarwal <avagarwa@redhat.com> - 4.37-1
  139. - New upstream realease 4.37
  140. - Updated local patches to match the new release
  141. * Mon Apr 4 2011 Avesh Agarwal <avagarwa@redhat.com> - 4.35-1
  142. - New upstream realease 4.35
  143. - Updated authpriv and sample patches to match the new release
  144. * Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.34-2
  145. - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
  146. * Mon Oct 4 2010 Avesh Agarwal <avagarwa@redhat.com> - 4.34-1
  147. - New upstream realease 4.34
  148. - Updated authpriv and sample patches to match the new release
  149. * Wed Apr 7 2010 Avesh Agarwal <avagarwa@redhat.com> - 4.33-1
  150. - New upstream realease 4.33
  151. - Updated authpriv and sample patches to match the new release
  152. - Addresses bz 580117 (inted mode support issue)
  153. * Mon Mar 29 2010 Avesh Agarwal <avagarwa@redhat.com> - 4.32-1
  154. - New upstream realease 4.32
  155. - Updated authpriv and sample patches to match the new release
  156. * Tue Feb 16 2010 Avesh Agarwal <avagarwa@redhat.com> - 4.31-1
  157. - New upstream realease 4.31
  158. - Updated authpriv and sample patches to match the new release
  159. * Tue Jan 26 2010 Avesh Agarwal <avagarwa@redhat.com> - 4.30-1
  160. - New upstream realease 4.30
  161. - Updated authpriv and sample patches for the new release
  162. * Wed Dec 09 2009 Avesh Agarwal <avagarwa@redhat.com> - 4.29-1
  163. - New upstream realease 4.29
  164. - Updated authpriv and sample patches for the new release
  165. - Modified spec file to include dist tag
  166. * Fri Aug 21 2009 Tomas Mraz <tmraz@redhat.com> - 4.27-5
  167. - rebuilt with new openssl
  168. * Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.27-4
  169. - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
  170. * Sun May 3 2009 Miloslav Trmač <mitr@redhat.com> - 4.27-3
  171. - Fix the previous patch.
  172. * Wed Apr 29 2009 Miloslav Trmač <mitr@redhat.com> - 4.27-2
  173. - Avoid aliasing undefined by ISO C
  174. * Thu Apr 16 2009 Miloslav Trmač <mitr@redhat.com> - 4.27-1
  175. - Update to stunnel-4.27.
  176. * Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.26-3
  177. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  178. * Sun Jan 18 2009 Tomas Mraz <tmraz@redhat.com> - 4.26-2
  179. - disable openssl upstream fips mode
  180. * Mon Sep 22 2008 Miloslav Trmač <mitr@redhat.com> - 4.26-1
  181. - Update to stunnel-4.26.
  182. * Sun Jun 8 2008 Miloslav Trmač <mitr@redhat.com> - 4.25-2
  183. - Use a clearer error message if the service name is unknown in "accept"
  184. Resolves: #450344
  185. * Mon Jun 2 2008 Miloslav Trmač <mitr@redhat.com> - 4.25-1
  186. - Update to stunnel-4.25
  187. * Tue May 20 2008 Miloslav Trmač <mitr@redhat.com> - 4.24-2
  188. - Drop stunnel3
  189. Resolves: #442842
  190. * Mon May 19 2008 Miloslav Trmač <mitr@redhat.com> - 4.24-1
  191. - Update to stunnel-4.24
  192. * Fri Mar 28 2008 Miloslav Trmač <mitr@redhat.com> - 4.22-1
  193. - Update to stunnel-4.22
  194. * Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 4.20-6
  195. - Autorebuild for GCC 4.3
  196. * Tue Dec 4 2007 Miloslav Trmač <mitr@redhat.com> - 4.20-5
  197. - Rebuild with openssl-0.9.8g
  198. * Tue Oct 16 2007 Miloslav Trmač <mitr@redhat.com> - 4.20-4
  199. - Revert the port to NSS, wait for NSS-based stunnel 5.x instead
  200. Resolves: #301971
  201. - Mark localized man pages with %%lang (patch by Ville Skyttä)
  202. Resolves: #322281
  203. * Tue Aug 28 2007 Miloslav Trmač <mitr@redhat.com> - 4.20-3.nss
  204. - Port to NSS
  205. * Mon Dec 4 2006 Miloslav Trmac <mitr@redhat.com> - 4.20-2
  206. - Update BuildRequires for the separate tcp_wrappers-devel package
  207. * Thu Nov 30 2006 Miloslav Trmac <mitr@redhat.com> - 4.20-1
  208. - Update to stunnel-4.20
  209. * Sat Nov 11 2006 Miloslav Trmac <mitr@redhat.com> - 4.19-1
  210. - Update to stunnel-4.19
  211. * Wed Oct 25 2006 Miloslav Trmac <mitr@redhat.com> - 4.18-1
  212. - Update to stunnel-4.18
  213. - Remove unused stunnel.cnf from the src.rpm
  214. - Fix some rpmlint warnings
  215. * Fri Aug 18 2006 Jesse Keating <jkeating@redhat.com> - 4.15-2
  216. - rebuilt with latest binutils to pick up 64K -z commonpagesize on ppc*
  217. (#203001)
  218. * Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 4.15-1.1
  219. - rebuild
  220. * Sat Mar 18 2006 Miloslav Trmac <mitr@redhat.com> - 4.15-1
  221. - Update to stunnel-4.15
  222. * Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 4.14-3.2
  223. - bump again for double-long bug on ppc(64)
  224. * Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 4.14-3.1
  225. - rebuilt for new gcc4.1 snapshot and glibc changes
  226. * Tue Jan 31 2006 Miloslav Trmac <mitr@redhat.com> - 4.14-3
  227. - Use pthread threading to fix crash on x86_64 (#179236)
  228. * Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
  229. - rebuilt
  230. * Wed Nov 9 2005 Miloslav Trmac <mitr@redhat.com> - 4.14-2
  231. - Rebuild with newer openssl
  232. * Thu Nov 3 2005 Miloslav Trmac <mitr@redhat.com> - 4.14-1
  233. - Update to stunnel-4.14
  234. - Override changed default pid file location, keep it in %%{_localstatedir}/run
  235. * Sat Oct 22 2005 Miloslav Trmac <mitr@redhat.com> - 4.13-1
  236. - Update to stunnel-4.13
  237. * Fri Sep 30 2005 Miloslav Trmac <mitr@redhat.com> - 4.12-1
  238. - Update to stunnel-4.12
  239. * Thu Sep 22 2005 Miloslav Trmac <mitr@redhat.com> - 4.11-2
  240. - Enable IPv6 (#169050, patch by Peter Bieringer)
  241. - Don't ship another copy of man pages in HTML
  242. * Tue Jul 12 2005 Miloslav Trmac <mitr@redhat.com> - 4.11-1
  243. - Update to stunnel-4.11
  244. - Fix int/size_t mismatches in stack_info ()
  245. - Update Certificate-Creation for /etc/pki
  246. * Wed Jun 1 2005 Miloslav Trmac <mitr@redhat.com> - 4.10-2
  247. - Fix inetd mode
  248. - Remove unnecessary Requires: and BuildRequires:
  249. - Clean up the spec file
  250. * Tue Apr 26 2005 Nalin Dahyabhai <nalin@redhat.com> 4.10-1
  251. - update to 4.10
  252. * Tue Apr 26 2005 Nalin Dahyabhai <nalin@redhat.com> 4.08-2
  253. - add buildprereqs on libtool, util-linux; change textutils/fileutils dep to
  254. coreutils (#133961)
  255. * Wed Mar 16 2005 Nalin Dahyabhai <nalin@redhat.com> 4.08-1
  256. - update to 4.08
  257. - build stunnel as a PIE binary
  258. * Mon Nov 22 2004 Miloslav Trmac <mitr@redhat.com> - 4.05-4
  259. - Convert man pages to UTF-8
  260. * Tue Jun 15 2004 Elliot Lee <sopwith@redhat.com>
  261. - rebuilt
  262. * Thu May 27 2004 Nalin Dahyabhai <nalin@redhat.com> 4.05-2
  263. - move the sample configuration to %%doc, it shouldn't be used as-is (#124373)
  264. * Thu Mar 11 2004 Nalin Dahyabhai <nalin@redhat.com> 4.05-1
  265. - update to 4.05
  266. * Tue Mar 02 2004 Elliot Lee <sopwith@redhat.com>
  267. - rebuilt
  268. * Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
  269. - rebuilt
  270. * Thu Aug 7 2003 Elliot Lee <sopwith@redhat.com> 4.04-6
  271. - Fix libtool
  272. * Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
  273. - rebuilt
  274. * Fri Mar 21 2003 Nalin Dahyabhai <nalin@redhat.com> 4.04-4
  275. - fix xinetd configuration samples
  276. * Mon Feb 10 2003 Nalin Dahyabhai <nalin@redhat.com> 4.04-3
  277. - rebuild
  278. * Wed Jan 22 2003 Tim Powers <timp@redhat.com>
  279. - rebuilt
  280. * Wed Jan 15 2003 Nalin Dahyabhai <nalin@redhat.com> 4.04-1
  281. - update to 4.04
  282. * Tue Jan 7 2003 Nalin Dahyabhai <nalin@redhat.com> 4.03-1
  283. - use pkgconfig for information about openssl, if available
  284. * Fri Jan 3 2003 Nalin Dahyabhai <nalin@redhat.com>
  285. - update to 4.03
  286. * Mon Oct 21 2002 Nalin Dahyabhai <nalin@redhat.com> 4.02-1
  287. - update to 4.02
  288. * Fri Oct 4 2002 Nalin Dahyabhai <nalin@redhat.com> 4.00-1
  289. - don't create a dummy cert
  290. * Wed Sep 25 2002 Nalin Dahyabhai <nalin@redhat.com>
  291. - update to 4.00
  292. - remove textutils and fileutils as buildreqs, add automake/autoconf
  293. * Fri Jun 21 2002 Tim Powers <timp@redhat.com>
  294. - automated rebuild
  295. * Sun May 26 2002 Tim Powers <timp@redhat.com>
  296. - automated rebuild
  297. * Fri May 17 2002 Nalin Dahyabhai <nalin@redhat.com> 3.22-2
  298. - rebuild in new environment
  299. * Wed Jan 2 2002 Nalin Dahyabhai <nalin@redhat.com> 3.22-1
  300. - update to 3.22, correcting a format-string vulnerability
  301. * Wed Oct 31 2001 Nalin Dahyabhai <nalin@redhat.com> 3.21a-1
  302. - update to 3.21a
  303. * Tue Aug 28 2001 Nalin Dahyabhai <nalin@redhat.com> 3.20-1
  304. - log using LOG_AUTHPRIV facility by default (#47289)
  305. - make permissions on stunnel binary 0755
  306. - implicitly trust certificates in %%{_datadir}/ssl/trusted (#24034)
  307. * Fri Aug 10 2001 Nalin Dahyabhai <nalin@redhat.com> 3.19-1
  308. - update to 3.19 to avoid problems with stunnel being multithreaded, but
  309. tcp wrappers not being thrad-safe
  310. * Mon Jul 30 2001 Nalin Dahyabhai <nalin@redhat.com>
  311. - update to 3.17
  312. * Mon Jul 23 2001 Nalin Dahyabhai <nalin@redhat.com>
  313. - update to 3.16
  314. * Mon Jul 16 2001 Nalin Dahyabhai <nalin@redhat.com>
  315. - update to 3.15
  316. - enable tcp-wrappers support
  317. * Tue May 29 2001 Nalin Dahyabhai <nalin@redhat.com>
  318. - remove explicit requirement on openssl (specific version isn't enough,
  319. we have to depend on shared library version anyway)
  320. * Fri Apr 27 2001 Nalin Dahyabhai <nalin@redhat.com>
  321. - update to 3.14
  322. * Mon Mar 26 2001 Preston Brown <pbrown@redhat.com>
  323. - depend on make (#33148)
  324. * Fri Mar 2 2001 Nalin Dahyabhai <nalin@redhat.com>
  325. - rebuild in new environment
  326. * Tue Feb 6 2001 Nalin Dahyabhai <nalin@redhat.com>
  327. - update to 3.13 to get pthread, OOB, 64-bit fixes
  328. - don't need sdf any more
  329. * Thu Dec 28 2000 Nalin Dahyabhai <nalin@redhat.com>
  330. - pull in sdf to build the man page (#22892)
  331. * Fri Dec 22 2000 Nalin Dahyabhai <nalin@redhat.com>
  332. - update to 3.11
  333. - chuck the SIGHUP patch (went upstream)
  334. - chuck parts of the 64-bit clean patch (went upstream)
  335. * Thu Dec 21 2000 Nalin Dahyabhai <nalin@redhat.com>
  336. - update to 3.10
  337. - more 64-bit clean changes, hopefully the last bunch
  338. * Wed Dec 20 2000 Nalin Dahyabhai <nalin@redhat.com>
  339. - change piddir from the default /var/stunnel to /var/run
  340. - clean out pid file on SIGHUP
  341. * Fri Dec 15 2000 Nalin Dahyabhai <nalin@redhat.com>
  342. - update to 3.9 to get a security fix
  343. * Wed Oct 25 2000 Matt Wilson <msw@redhat.com>
  344. - change all unsigned longs to u_int32_t when dealing with network
  345. addresses
  346. * Fri Aug 18 2000 Nalin Dahyabhai <nalin@redhat.com>
  347. - make stunnel.pem also be (missingok)
  348. * Thu Jun 29 2000 Nalin Dahyabhai <nalin@redhat.com>
  349. - move to Applications/Internet group
  350. - clean up %%post script
  351. - make stunnel.pem %%ghost %%config(noreplace)
  352. - provide a sample file for use with xinetd
  353. * Thu Jun 8 2000 Nalin Dahyabhai <nalin@redhat.com>
  354. - FHS compliance fixes
  355. - modify defaults
  356. * Tue Mar 14 2000 Florian La Roche <Florian.LaRoche@redhat.com>
  357. - update to 3.8
  358. - do not create certificate if one already exists
  359. * Mon Feb 21 2000 Florian La Roche <Florian.LaRoche@redhat.com>
  360. - update to 3.7
  361. - add patch to find /usr/share/ssl
  362. - change some perms
  363. * Sat Oct 30 1999 Bernhard Rosenkraenzer <bero@redhat.com>
  364. - Modify spec file to match Red Hat standards
  365. * Thu Aug 12 1999 Damien Miller <damien@ibs.com.au>
  366. - Updated to 3.4a
  367. - Patched for OpenSSL 0.9.4
  368. - Cleaned up files section
  369. * Sun Jul 11 1999 Damien Miller <dmiller@ilogic.com.au>
  370. - Updated to 3.3
  371. * Sat Nov 28 1998 Damien Miller <dmiller@ilogic.com.au>
  372. - Initial RPMification