]> git.pld-linux.org Git - packages/openssh.git/blob - openssh.spec
- release 3
[packages/openssh.git] / openssh.spec
1 #
2 # Conditional build:    
3 # bcond_off_gnome - without gnome-askpass utility
4 Summary:        OpenSSH free Secure Shell (SSH) implementation
5 Summary(pl):    Publicznie dostêpna implementacja bezpiecznego shella (SSH)
6 Name:           openssh
7 Version:        2.9p1
8 Release:        3
9 License:        BSD
10 Group:          Applications/Networking
11 Group(de):      Applikationen/Netzwerkwesen
12 Group(pl):      Aplikacje/Sieciowe
13 Source0:        ftp://ftp.ca.openbsd.org/pub/OpenBSD/OpenSSH/portable/%{name}-%{version}.tar.gz
14 Source1:        %{name}d.conf
15 Source2:        %{name}.conf
16 Source3:        %{name}d.init
17 Source4:        %{name}d.pamd
18 Source5:        %{name}.sysconfig
19 Source6:        passwd.pamd
20 Patch0:         %{name}-libwrap.patch
21 Patch1:         %{name}-no_libnsl.patch
22 URL:            http://www.openssh.com/
23 BuildRequires:  XFree86-devel
24 BuildRequires:  autoconf
25 %{!?bcond_off_gnome:BuildRequires: gnome-libs-devel}
26 BuildRequires:  gtk+-devel
27 BuildRequires:  openssl-devel >= 0.9.6a
28 BuildRequires:  pam-devel
29 BuildRequires:  zlib-devel
30 BuildRequires:  libwrap-devel
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32 Prereq:         openssl >= 0.9.6
33 Obsoletes:      ssh < %{version}
34 Obsoletes:      ssh > %{version}
35
36 %define         _sysconfdir     /etc/ssh
37 %define         _libexecdir     %{_libdir}/%{name}
38
39 %description
40 Ssh (Secure Shell) a program for logging into a remote machine and for
41 executing commands in a remote machine. It is intended to replace
42 rlogin and rsh, and provide secure encrypted communications between
43 two untrusted hosts over an insecure network. X11 connections and
44 arbitrary TCP/IP ports can also be forwarded over the secure channel.
45
46 OpenSSH is OpenBSD's rework of the last free version of SSH, bringing
47 it up to date in terms of security and features, as well as removing
48 all patented algorithms to seperate libraries (OpenSSL).
49
50 This package includes the core files necessary for both the OpenSSH
51 client and server. To make this package useful, you should also
52 install openssh-clients, openssh-server, or both.
53
54 %description -l pl
55 Ssh (Secure Shell) to program s³u¿±cy do logowania siê na zdaln±
56 maszynê i uruchamiania na niej aplikacji. W zamierzeniu openssh ma
57 zast±piæ rlogin, rsh i dostarczyæ bezpieczne, szyfrowane po³±czenie
58 pomiedzy dwoma hostami.
59
60 %package clients
61 Summary:        OpenSSH Secure Shell protocol clients
62 Summary(pl):    Klienci protoko³u Secure Shell
63 Requires:       openssh
64 Group:          Applications/Networking
65 Group(de):      Applikationen/Netzwerkwesen
66 Group(pl):      Aplikacje/Sieciowe
67 Obsoletes:      ssh-clients < %{version}
68 Obsoletes:      ssh-clients > %{version}
69 Obsoletes:      sftp
70 Requires:       %{name} = %{version}
71
72 %description clients
73 Ssh (Secure Shell) a program for logging into a remote machine and for
74 executing commands in a remote machine. It is intended to replace
75 rlogin and rsh, and provide secure encrypted communications between
76 two untrusted hosts over an insecure network. X11 connections and
77 arbitrary TCP/IP ports can also be forwarded over the secure channel.
78
79 OpenSSH is OpenBSD's rework of the last free version of SSH, bringing
80 it up to date in terms of security and features, as well as removing
81 all patented algorithms to seperate libraries (OpenSSL).
82
83 This package includes the clients necessary to make encrypted
84 connections to SSH servers.
85
86 %description -l pl clients
87 Ssh (Secure Shell) to program s³u¿±cy do logowania siê na zdaln±
88 maszynê i uruchamiania na niej aplikacji. W zamierzeniu openssh ma
89 zast±piæ rlogin, rsh i dostarczyæ bezpieczne, szyfrowane po³±czenie
90 pomiedzy dwoma hostami.
91
92 Ten pakiet zawiera klientów s³u¿±cych do ³±czenia siê z serwerami SSH.
93
94 %package server
95 Summary:        OpenSSH Secure Shell protocol server (sshd)
96 Summary(pl):    Serwer protoko³u Secure Shell (sshd)
97 Requires:       openssh
98 Requires:       chkconfig >= 0.9
99 Group:          Networking/Daemons
100 Group(de):      Netzwerkwesen/Server
101 Group(pl):      Sieciowe/Serwery
102 Obsoletes:      ssh-server < %{version}, ssh-server > %{version}
103 Requires:       /bin/login
104 Requires:       util-linux
105 Prereq:         rc-scripts
106 Prereq:         chkconfig
107 Prereq:         %{name} = %{version}
108
109 %description server
110 Ssh (Secure Shell) a program for logging into a remote machine and for
111 executing commands in a remote machine. It is intended to replace
112 rlogin and rsh, and provide secure encrypted communications between
113 two untrusted hosts over an insecure network. X11 connections and
114 arbitrary TCP/IP ports can also be forwarded over the secure channel.
115
116 OpenSSH is OpenBSD's rework of the last free version of SSH, bringing
117 it up to date in terms of security and features, as well as removing
118 all patented algorithms to seperate libraries (OpenSSL).
119
120 This package contains the secure shell daemon. The sshd is the server
121 part of the secure shell protocol and allows ssh clients to connect to
122 your host.
123
124 %description -l pl server
125 Ssh (Secure Shell) to program s³u¿±cy do logowania siê na zdaln±
126 maszynê i uruchamiania na niej aplikacji. W zamierzeniu openssh ma
127 zast±piæ rlogin, rsh i dostarczyæ bezpieczne, szyfrowane po³±czenie
128 pomiedzy dwoma hostami.
129
130 Ten pakiet zawiera serwer sshd (do którego mog± ³±czyæ siê klienci
131 ssh).
132
133 %package gnome-askpass
134 Summary:        OpenSSH GNOME passphrase dialog
135 Summary(pl):    Odpytywacz has³a OpenSSH dla GNOME
136 Group:          Applications/Networking
137 Group(de):      Applikationen/Netzwerkwesen
138 Group(pl):      Aplikacje/Sieciowe
139 Requires:       %{name} = %{version}
140 Obsoletes:      ssh-extras < %{version}, ssh-extras > %{version}
141 Obsoletes:      ssh-askpass < %{version}, ssh-askpass > %{version}
142 Obsoletes:      openssh-askpass < %{version}, openssh-askpass > %{version}
143
144 %description gnome-askpass
145 Ssh (Secure Shell) a program for logging into a remote machine and for
146 executing commands in a remote machine. It is intended to replace
147 rlogin and rsh, and provide secure encrypted communications between
148 two untrusted hosts over an insecure network. X11 connections and
149 arbitrary TCP/IP ports can also be forwarded over the secure channel.
150
151 OpenSSH is OpenBSD's rework of the last free version of SSH, bringing
152 it up to date in terms of security and features, as well as removing
153 all patented algorithms to seperate libraries (OpenSSL).
154
155 This package contains the GNOME passphrase dialog.
156
157 %description -l pl gnome-askpass
158 Ssh (Secure Shell) to program s³u¿±cy do logowania siê na zdaln±
159 maszynê i uruchamiania na niej aplikacji. W zamierzeniu openssh ma
160 zast±piæ rlogin, rsh i dostarczyæ bezpieczne, szyfrowane po³±czenie
161 pomiedzy dwoma hostami.
162
163 Ten pakiet zawiera ,,odpytywacz has³a'' dla GNOME.
164
165 %prep
166 %setup  -q
167 %patch0 -p1
168 %patch1 -p1
169
170 %build
171 autoconf
172 %configure \
173         %{!?bcond_off_gnome:--with-gnome-askpass} \
174         --with-tcp-wrappers \
175         --with-pam \
176         --with-mantype=man \
177         --with-md5-passwords \
178         --with-ipaddr-display \
179         --with-4in6 \
180         --disable-suid-ssh \
181         --with-pid-dir=%{_localstatedir}/run
182
183 echo '#define LOGIN_PROGRAM           "/bin/login"' >>config.h
184
185 %{__make}
186
187 %{!?bcond_off_gnome: cd contrib && %{__cc} %{rpmcflags} `gnome-config --cflags gnome gnomeui gtk` } \
188 %{!?bcond_off_gnome:    gnome-ssh-askpass.c -o gnome-ssh-askpass } \
189 %{!?bcond_off_gnome:    `gnome-config --libs gnome gnomeui gtk` }
190
191 %install
192 rm -rf $RPM_BUILD_ROOT
193
194 install -d $RPM_BUILD_ROOT{%{_sysconfdir},/etc/{pam.d,rc.d/init.d,sysconfig,security}}
195
196 %{__make} install DESTDIR="$RPM_BUILD_ROOT"
197
198 install %{SOURCE4} $RPM_BUILD_ROOT/etc/pam.d/sshd
199 install %{SOURCE6} $RPM_BUILD_ROOT/etc/pam.d/passwdssh
200 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/sshd
201 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/sshd
202 install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/ssh_config
203 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/sshd_config
204 install -d $RPM_BUILD_ROOT%{_libexecdir}/ssh
205 %{!?bcond_off_gnome:install contrib/gnome-ssh-askpass $RPM_BUILD_ROOT%{_libexecdir}/ssh/ssh-askpass}
206
207 rm -f   $RPM_BUILD_ROOT%{_mandir}/man1/slogin.1
208 echo ".so man1/ssh.1" > $RPM_BUILD_ROOT%{_mandir}/man1/slogin.1
209
210 gzip -9nf *.RNG TODO README OVERVIEW CREDITS Change*
211
212 touch $RPM_BUILD_ROOT/etc/security/blacklist.sshd
213         
214 %clean
215 rm -rf $RPM_BUILD_ROOT
216
217 %post server
218 /sbin/chkconfig --add sshd
219 if [ ! -f %{_sysconfdir}/ssh_host_key -o ! -s %{_sysconfdir}/ssh_host_key ]; then
220         %{_bindir}/ssh-keygen -b 1024 -f %{_sysconfdir}/ssh_host_key -N '' 1>&2
221         chmod 600 %{_sysconfdir}/ssh_host_key
222 fi
223 if [ ! -f %{_sysconfdir}/ssh_host_dsa_key -o ! -s %{_sysconfdir}/ssh_host_dsa_key ]; then
224         %{_bindir}/ssh-keygen -d -f %{_sysconfdir}/ssh_host_dsa_key -N '' 1>&2
225         chmod 600 %{_sysconfdir}/ssh_host_dsa_key
226 fi
227 if [ -f /var/lock/subsys/sshd ]; then
228         /etc/rc.d/init.d/sshd restart 1>&2
229 else
230         echo "Run \"/etc/rc.d/init.d/sshd start\" to start openssh daemon."
231 fi
232 if ! grep ssh /etc/security/passwd.conf >/dev/null 2>&1 ; then
233         echo "ssh" >> /etc/security/passwd.conf
234 fi
235
236 %preun server
237 if [ "$1" = "0" ]; then
238         if [ -f /var/lock/subsys/sshd ]; then
239                 /etc/rc.d/init.d/sshd stop 1>&2
240         fi
241         /sbin/chkconfig --del sshd
242 fi
243
244 %files
245 %defattr(644,root,root,755)
246 %doc *.gz
247 %attr(755,root,root) %{_bindir}/ssh-key*
248 %{_mandir}/man1/ssh-key*.1*
249 %dir %{_sysconfdir}
250
251 %files clients
252 %defattr(644,root,root,755)
253 %attr(0755,root,root) %{_bindir}/ssh
254 %attr(0755,root,root) %{_bindir}/slogin
255 %attr(0755,root,root) %{_bindir}/sftp
256 %attr(0755,root,root) %{_bindir}/ssh-agent
257 %attr(0755,root,root) %{_bindir}/ssh-add
258 %attr(755,root,root) %{_bindir}/scp
259 %{_mandir}/man1/scp.1*
260 %{_mandir}/man1/ssh.1*
261 %{_mandir}/man1/slogin.1*
262 %{_mandir}/man1/sftp.1*
263 %{_mandir}/man1/ssh-agent.1*
264 %{_mandir}/man1/ssh-add.1*
265 %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/ssh_config
266
267 %files server
268 %defattr(644,root,root,755)
269 %attr(755,root,root) %{_sbindir}/sshd
270 %attr(755,root,root) %{_libexecdir}/sftp-server
271 %dir %{_libexecdir}
272 %{_mandir}/man8/sshd.8*
273 %{_mandir}/man8/sftp-server.8*
274 %attr(640,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/sshd_config
275 %attr(640,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/pam.d/sshd
276 %attr(640,root,root) %{_sysconfdir}/primes
277 %attr(754,root,root) /etc/rc.d/init.d/sshd
278 %attr(640,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/sysconfig/sshd
279 %attr(640,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/security/blacklist.sshd
280
281 %{!?bcond_off_gnome:%files gnome-askpass}
282 %{!?bcond_off_gnome:%defattr(644,root,root,755)}
283 %{!?bcond_off_gnome:%dir %{_libexecdir}/ssh}
284 %{!?bcond_off_gnome:%attr(755,root,root) %{_libexecdir}/ssh/ssh-askpass}
This page took 0.094174 seconds and 4 git commands to generate.