wpa_supplicant-vl.spec 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352
  1. %define build_gui 1
  2. Summary: WPA/WPA2/IEEE 802.1X Supplicant
  3. Name: wpa_supplicant
  4. Version: 2.5
  5. Release: 1%{?_dist_release}
  6. License: BSD
  7. Group: System Environment/Base
  8. URL: http://w1.fi/wpa_supplicant/
  9. Source0: http://hostap.epitest.fi/releases/%{name}-%{version}.tar.gz
  10. Source1: %{name}.build-config
  11. Source2: %{name}.conf
  12. Source3: %{name}.init.d
  13. Source4: %{name}.sysconfig
  14. Source6: %{name}.logrotate
  15. # distro specific customization and not suitable for upstream,
  16. # works around busted drivers
  17. Patch0: wpa_supplicant-assoc-timeout.patch
  18. # ensures that debug output gets flushed immediately to help diagnose driver
  19. # bugs, not suitable for upstream
  20. Patch1: wpa_supplicant-flush-debug-output.patch
  21. # disto specific customization for log paths, not suitable for upstream
  22. Patch2: wpa_supplicant-dbus-service-file-args.patch
  23. # quiet an annoying and frequent syslog message
  24. Patch3: wpa_supplicant-quiet-scan-results-message.patch
  25. # allow more private key encryption algorithms
  26. Patch5: wpa_supplicant-openssl-more-algs.patch
  27. # Less aggressive roaming; signal strength is wildly variable
  28. Patch8: rh837402-less-aggressive-roaming.patch
  29. # CVE-2015-1863, backport from upstream master, will be in 2.5
  30. # http://w1.fi/cgit/hostap/commit/?id=9ed4eee345f85e3025c33c6e20aa25696e341ccd
  31. Patch9: 0001-P2P-Validate-SSID-element-length-before-copying-it-C.patch
  32. # Fix a crash - rh #1231973
  33. # http://w1.fi/cgit/hostap/commit/wpa_supplicant/dbus/dbus_new_handlers.c?id=8a78e227df1ead19be8e12a4108e448887e64d6f
  34. Patch10: rh1231973-dbus-fix-operations-for-p2p-mgmt.patch
  35. # Fix a security issue - rh #rh1241907
  36. # http://w1.fi/security/2015-5/0001-NFC-Fix-payload-length-validation-in-NDEF-record-par.patch
  37. Patch11: rh1241907-NFC-Fix-payload-length-validation-in-NDEF-record-par.patch
  38. ## Vine patches
  39. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  40. %if %{build_gui}
  41. BuildRequires: qt4-devel
  42. %endif
  43. BuildRequires: openssl-devel
  44. BuildRequires: readline-devel
  45. BuildRequires: dbus-devel
  46. BuildRequires: libnl3-devel
  47. BuildRequires: docbook-utils
  48. Requires(post): /sbin/chkconfig
  49. Requires(preun): /sbin/chkconfig /sbin/service
  50. Requires(postun): /sbin/service
  51. %description
  52. wpa_supplicant is a WPA Supplicant for Linux, BSD and Windows with support
  53. for WPA and WPA2 (IEEE 802.11i / RSN). Supplicant is the IEEE 802.1X/WPA
  54. component that is used in the client stations. It implements key negotiation
  55. with a WPA Authenticator and it controls the roaming and IEEE 802.11
  56. authentication/association of the wlan driver.
  57. %if %{build_gui}
  58. %package gui
  59. Summary: Graphical User Interface for %{name}
  60. Summary(ja): %{name} のグラフィカルユーザインタフェース
  61. Group: Applications/System
  62. %description gui
  63. Graphical User Interface for wpa_supplicant written using QT4
  64. %description -l ja gui
  65. QT4 を用いた wpa_supplicant のグラフィカルユーザインタフェース
  66. %endif
  67. %prep
  68. %setup -q
  69. %patch0 -p1 -b .assoc-timeout
  70. %patch1 -p1 -b .flush-debug-output
  71. %patch2 -p1 -b .dbus-service-file
  72. %patch3 -p1 -b .quiet-scan-results-msg
  73. %patch5 -p1 -b .more-openssl-algs
  74. %patch8 -p1 -b .rh837402-less-aggressive-roaming
  75. %build
  76. pushd wpa_supplicant
  77. cp %{SOURCE1} .config
  78. CFLAGS="${CFLAGS:-%optflags} -fPIE -DPIE" ; export CFLAGS ;
  79. CXXFLAGS="${CXXFLAGS:-%optflags} -fPIE -DPIE" ; export CXXFLAGS ;
  80. LDFLAGS="${LDFLAGS:-%optflags} -pie -Wl,-z,now" ; export LDFLAGS ;
  81. # yes, BINDIR=_sbindir
  82. BINDIR="%{_sbindir}" ; export BINDIR ;
  83. LIBDIR="%{_libdir}" ; export LIBDIR ;
  84. make %{?_smp_mflags}
  85. %if %{build_gui}
  86. QTDIR=%{_libdir}/qt4 make wpa_gui-qt4 %{?_smp_mflags}
  87. %endif
  88. make eapol_test
  89. popd
  90. %install
  91. rm -rf %{buildroot}
  92. # init scripts
  93. install -D -m 0755 %{SOURCE3} %{buildroot}/%{_sysconfdir}/rc.d/init.d/%{name}
  94. install -D -m 0644 %{SOURCE4} %{buildroot}/%{_sysconfdir}/sysconfig/%{name}
  95. install -D -m 0644 %{SOURCE6} %{buildroot}/%{_sysconfdir}/logrotate.d/%{name}
  96. # config
  97. install -D -m 0600 %{SOURCE2} %{buildroot}/%{_sysconfdir}/%{name}/%{name}.conf
  98. # binary
  99. install -d %{buildroot}/%{_sbindir}
  100. install -m 0755 %{name}/wpa_passphrase %{buildroot}/%{_sbindir}
  101. install -m 0755 %{name}/wpa_cli %{buildroot}/%{_sbindir}
  102. install -m 0755 %{name}/wpa_supplicant %{buildroot}/%{_sbindir}
  103. install -D -m 0644 %{name}/dbus/dbus-wpa_supplicant.conf %{buildroot}/%{_sysconfdir}/dbus-1/system.d/wpa_supplicant.conf
  104. install -D -m 0644 %{name}/dbus/fi.w1.wpa_supplicant1.service %{buildroot}/%{_datadir}/dbus-1/system-services/fi.w1.wpa_supplicant1.service
  105. install -D -m 0644 %{name}/dbus/fi.epitest.hostap.WPASupplicant.service %{buildroot}/%{_datadir}/dbus-1/system-services/fi.epitest.hostap.WPASupplicant.service
  106. %if %{build_gui}
  107. # gui
  108. install -d %{buildroot}/%{_bindir}
  109. install -m 0755 %{name}/wpa_gui-qt4/wpa_gui %{buildroot}/%{_bindir}
  110. %endif
  111. # running
  112. mkdir -p %{buildroot}/%{_localstatedir}/run/%{name}
  113. # man pages
  114. install -d %{buildroot}%{_mandir}/man{5,8}
  115. install -m 0644 %{name}/doc/docbook/*.8 %{buildroot}%{_mandir}/man8
  116. install -m 0644 %{name}/doc/docbook/*.5 %{buildroot}%{_mandir}/man5
  117. # some cleanup in docs
  118. rm -f %{name}/doc/.cvsignore
  119. rm -rf %{name}/doc/docbook
  120. chmod -R 0644 %{name}/examples/*.py
  121. %clean
  122. rm -rf %{buildroot}
  123. %post
  124. if [ $1 = 1 ]; then
  125. /sbin/chkconfig --add %{name}
  126. fi
  127. %preun
  128. if [ $1 = 0 ]; then
  129. /sbin/service %{name} stop > /dev/null 2>&1
  130. killall -TERM wpa_supplicant >/dev/null 2>&1
  131. /sbin/chkconfig --del %{name}
  132. fi
  133. %postun
  134. if [ $1 -ge 1 ]; then
  135. /sbin/service %{name} condrestart > /dev/null 2>&1
  136. fi
  137. %files
  138. %defattr(-, root, root)
  139. %doc COPYING %{name}/ChangeLog README %{name}/eap_testing.txt %{name}/todo.txt %{name}/wpa_supplicant.conf %{name}/examples
  140. %config(noreplace) %{_sysconfdir}/%{name}/%{name}.conf
  141. %config(noreplace) %{_sysconfdir}/sysconfig/%{name}
  142. %config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
  143. %{_sysconfdir}/rc.d/init.d/%{name}
  144. %{_sysconfdir}/dbus-1/system.d/%{name}.conf
  145. %{_datadir}/dbus-1/system-services/fi.epitest.hostap.WPASupplicant.service
  146. %{_datadir}/dbus-1/system-services/fi.w1.wpa_supplicant1.service
  147. %{_sbindir}/wpa_passphrase
  148. %{_sbindir}/wpa_supplicant
  149. %{_sbindir}/wpa_cli
  150. %dir %{_localstatedir}/run/%{name}
  151. %dir %{_sysconfdir}/%{name}
  152. %{_mandir}/man8/*
  153. %{_mandir}/man5/*
  154. %if %{build_gui}
  155. %files gui
  156. %defattr(-, root, root)
  157. %{_bindir}/wpa_gui
  158. %endif
  159. %changelog
  160. * Thu Oct 08 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> - 2.5-1
  161. - update to 2.5
  162. - update SOURCE1
  163. - remove Patch7 (libnl3-includes.patch)
  164. - add Patch 9,10,11 from Fedora
  165. - remove Patch 6, 700
  166. * Thu Feb 5 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> - 2.3-1
  167. - updated to 2.3
  168. - built with libnl3 instead of libnl
  169. - added Patch 6, 7 and 8 from Fedora
  170. - added Patch700
  171. * Mon Aug 22 2011 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 0.7.3-3
  172. - import Patch8 from Fedora 1:0.7.3-9 to fix some crashes
  173. - Wed Jul 27 2011 Dan Williams <dcbw@redhat.com> - 1:0.7.3-9
  174. - Fix various crashes with D-Bus interface (rh #678625) (rh #725517)
  175. * Mon Jan 10 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.7.3-2
  176. - rebuild with openssl-1.0.0c
  177. - add BuildRequires: qt4-designer, libnl-devel
  178. * Thu Jan 06 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 0.7.3-1
  179. - new upstream release
  180. - update patches
  181. - change License to BSD due to linkage against OpsnSSL since there is no
  182. OpenSSL exception in upstream GPLv2 license text.
  183. - build with qt4
  184. - update build config
  185. * Wed Jan 28 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 0.6.4-1
  186. - new upstream release
  187. - remove hostap/madwifi/prism54 drivers, use 'wext' instead.
  188. - drop upstream patches
  189. - import some fedora patches
  190. - Handle encryption keys correctly when switching 802.11 modes (rh #459399)
  191. - Better scanning behavior on resume from suspend/hibernate
  192. - Better interaction with newer kernels and drivers
  193. * Sun Aug 03 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 0.6.3-2
  194. - start wpa_supplicant by default.
  195. * Sun Aug 03 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 0.6.3-1
  196. - new upstream release
  197. - import some fedora patches
  198. * Thu May 17 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 0.5.7-0vl2
  199. - rebuild with new openssl
  200. * Mon May 14 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 0.5.7-0vl1
  201. - new upstream release
  202. * Wed Jun 21 2006 Daisuke SUZUKI <daisuke@linux.or.jp> 0.4.8-0vl1
  203. - initial build for Vine Linux based on FC package.
  204. * Thu Apr 27 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-10
  205. - Add fix for madwifi and WEP (wpa_supplicant/hostap bud #140) (#rh190075#)
  206. - Fix up madwifi-ng private ioctl()s for r1331 and later
  207. - Update madwifi headers to r1475
  208. * Tue Apr 25 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-9
  209. - Enable Wired driver, PKCS12, and Smartcard options (#rh189805#)
  210. * Tue Apr 11 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-8
  211. - Fix control interface key obfuscation a bit
  212. * Sun Apr 2 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-7
  213. - Work around older & incorrect drivers that return null-terminated SSIDs
  214. * Mon Mar 27 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-6
  215. - Add patch to make orinoco happy with WEP keys
  216. - Enable Prism54-specific driver
  217. - Disable ipw-specific driver; ipw2x00 should be using WEXT instead
  218. * Fri Mar 3 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-5
  219. - Increase association timeout, mainly for drivers that don't
  220. fully support WPA ioctls yet
  221. * Fri Mar 3 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-4
  222. - Add additional BuildRequires #rh181914#
  223. - Add prereq on chkconfig #rh182905# #rh182906#
  224. - Own /var/run/wpa_supplicant and /etc/wpa_supplicant #rh183696#
  225. * Wed Mar 1 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-3
  226. - Install wpa_passphrase too #rh183480#
  227. * Mon Feb 27 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-2
  228. - Don't expose private data on the control interface unless requested
  229. * Fri Feb 24 2006 Dan Williams <dcbw@redhat.com> - 0.4.8-1
  230. - Downgrade to 0.4.8 stable release rather than a dev release
  231. * Sun Feb 12 2006 Dan Williams <dcbw@redhat.com> - 0.5.1-3
  232. - Documentation cleanup (Terje Rosten <terje.rosten@ntnu.no>)
  233. * Sun Feb 12 2006 Dan Williams <dcbw@redhat.com> - 0.5.1-2
  234. - Move initscript to /etc/rc.d/init.d
  235. * Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 0.5.1-1.2
  236. - bump again for double-long bug on ppc(64)
  237. * Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 0.5.1-1.1
  238. - rebuilt for new gcc4.1 snapshot and glibc changes
  239. * Sun Feb 5 2006 Dan Williams <dcbw@redhat.com> 0.5.1-1
  240. - Update to 0.5.1
  241. - Add WE auth fallback to actually work with older drivers
  242. * Thu Jan 26 2006 Dan Williams <dcbw@redhat.com> 0.4.7-2
  243. - Bring package into Fedora Core
  244. - Add ap_scan control interface patch
  245. - Enable madwifi-ng driver
  246. * Sun Jan 15 2006 Douglas E. Warner <silfreed@silfreed.net> 0.4.7-1
  247. - upgrade to 0.4.7
  248. - added package w/ wpa_gui in it
  249. * Mon Nov 14 2005 Douglas E. Warner <silfreed@silfreed.net> 0.4.6-1
  250. - upgrade to 0.4.6
  251. - adding ctrl interface changes recommended
  252. by Hugo Paredes <hugo.paredes@e-know.org>
  253. * Sun Oct 9 2005 Douglas E. Warner <silfreed@silfreed.net> 0.4.5-1
  254. - upgrade to 0.4.5
  255. - updated config file wpa_supplicant is built with
  256. especially, the ipw2100 driver changed to just ipw
  257. and enabled a bunch more EAP
  258. - disabled dist tag
  259. * Thu Jun 30 2005 Douglas E. Warner <silfreed@silfreed.net> 0.4.2-3
  260. - fix typo in init script
  261. * Thu Jun 30 2005 Douglas E. Warner <silfreed@silfreed.net> 0.4.2-2
  262. - fixing init script using fedora-extras' template
  263. - removing chkconfig default startup
  264. * Tue Jun 21 2005 Douglas E. Warner <silfreed@silfreed.net> 0.4.2-1
  265. - upgrade to 0.4.2
  266. - new sample conf file that will use any unrestricted AP
  267. - make sysconfig config entry
  268. - new BuildRoot for Fedora Extras
  269. - adding dist tag to Release
  270. * Fri May 06 2005 Douglas E. Warner <silfreed@silfreed.net> 0.3.8-1
  271. - upgrade to 0.3.8
  272. * Thu Feb 10 2005 Douglas E. Warner <silfreed@silfreed.net> 0.3.6-2
  273. - compile ipw driver in
  274. * Wed Feb 09 2005 Douglas E. Warner <silfreed@silfreed.net> 0.3.6-1
  275. - upgrade to 0.3.6
  276. * Thu Dec 23 2004 Douglas E. Warner <silfreed@silfreed.net> 0.2.5-4
  277. - fixing init script
  278. * Mon Dec 20 2004 Douglas E. Warner <silfreed@silfreed.net> 0.2.5-3
  279. - fixing init script
  280. - adding post/preun items to add/remove via chkconfig
  281. * Mon Dec 20 2004 Douglas E. Warner <silfreed@silfreed.net> 0.2.5-2
  282. - adding sysV scripts
  283. * Mon Dec 20 2004 Douglas E. Warner <silfreed@silfreed.net> 0.2.5-1
  284. - Initial RPM release.