2 %bcond_with skey # with S/KEY support
3 #skey_fn.c: In function 'skey_fn':
4 #skey_fn.c:167: error: too many arguments to function 'skeychallenge'
6 Summary: TACACS+ daemon
7 Summary(pl.UTF-8): Demon TACACS+
11 License: BSD-like, GPL
12 Group: Networking/Daemons
13 Source0: ftp://ftp.shrubbery.net/pub/tac_plus/tacacs+-%{version}.tar.gz
14 # Source0-md5: 55c9aaac4ea5263438919594bf537666
18 Source6: %{name}.rotate
19 Source8: %{name}.sysconfig
20 URL: http://www.shrubbery.net/tac_plus/
23 BuildRequires: libtool
24 BuildRequires: libwrap-devel
25 BuildRequires: pam-devel
26 BuildRequires: perl-base
27 BuildRequires: rpm-pythonprov
28 BuildRequires: rpmbuild(macros) >= 1.268
29 %{?with_skey:BuildRequires: skey-devel}
30 Requires(post,preun): /sbin/chkconfig
31 Requires(postun): /usr/sbin/groupdel
32 Requires(postun): /usr/sbin/userdel
33 Requires(pre): /bin/id
34 Requires(pre): /usr/bin/getgid
35 Requires(pre): /usr/sbin/groupadd
36 Requires(pre): /usr/sbin/useradd
37 Requires(pre): fileutils
39 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41 # library use symbols provided by the binary
42 %define skip_post_check_so .*lib.*/libtacacs.so.*
45 TACACS+ daemon using with Cisco's NASs (or other vendors) for AAA
46 (Authentication, Authorization and Accounting) propose.
48 %description -l pl.UTF-8
49 Demon TACACS+ używany wraz z NAS-ami Cisco (lub innych producentów) do
50 celów uwierzytelniania, autoryzacji i rozliczania (AAA -
51 Authentication, Authorization and Accounting).
54 Summary: Header files for tacacs+ library
55 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki tacacs+
56 Group: Development/Libraries
57 Requires: %{name} = %{version}-%{release}
60 Header files for tacacs+ library.
62 %description devel -l pl.UTF-8
63 Pliki nagłówkowe biblioteki tacacs+.
66 Summary: Static tacacs+ library
67 Summary(pl.UTF-8): Statyczna biblioteka tacacs+
68 Group: Development/Libraries
69 Requires: %{name}-devel = %{version}-%{release}
72 Static tacacs+ library.
74 %description static -l pl.UTF-8
75 Statyczna biblioteka tacacs+.
78 %setup -q -n %{name}+-%{version}
86 %{?with_skey:--with-skey}
89 %{?with_skey:INCLUDES="-I%{_includedir}/security"}
92 rm -rf $RPM_BUILD_ROOT
93 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/%{name},/etc/{logrotate.d,pam.d,rc.d/init.d,sysconfig},/var/log}
96 DESTDIR=$RPM_BUILD_ROOT
98 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
99 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
100 install %{SOURCE3} $RPM_BUILD_ROOT/etc/pam.d/tac_plus
101 install %{SOURCE6} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
102 install %{SOURCE8} $RPM_BUILD_ROOT/etc/sysconfig/%{name}
104 for n in tac_plus.acct tac_plus.log tacwho.log; do
105 :> $RPM_BUILD_ROOT/var/log/$n
109 rm -rf $RPM_BUILD_ROOT
112 %groupadd -g 29 -r -f radius
113 %useradd -u 29 -d %{_localstatedir} -s /bin/false -M -r -c "%{name}" -g radius radius
117 for n in /var/log/{tac_plus.acct,tac_plus.log,tacwho.log}; do
118 [ -f $n ] && continue
123 /sbin/chkconfig --add %{name}
124 %service %{name} restart
127 if [ "$1" = "0" ]; then
128 %service %{name} stop
129 /sbin/chkconfig --del %{name}
134 if [ "$1" = "0" ]; then
140 %defattr(644,root,root,755)
141 %doc CHANGES COPYING FAQ users_guide
142 %attr(755,root,root) %{_bindir}/tac_p*
143 %dir %{_sysconfdir}/%{name}
144 %attr(640,root,radius) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/tacacs.cfg
145 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name}
146 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/tac_plus
147 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}
148 %attr(754,root,root) /etc/rc.d/init.d/%{name}
149 %{_mandir}/man5/tac_p*.5*
150 %{_mandir}/man8/tac_p*.8*
151 %attr(755,root,root) %{_libdir}/libtacacs.so.1.*.*
152 %attr(755,root,root) %ghost %{_libdir}/libtacacs.so.?
154 %attr(660,root,radius) %ghost /var/log/tac*
157 %defattr(644,root,root,755)
158 %attr(755,root,root) %{_libdir}/libtacacs.so
159 %{_includedir}/tacacs.h
162 %defattr(644,root,root,755)
163 %{_libdir}/libtacacs.a
164 %{_libdir}/libtacacs.la