blob: 434f32eea89af754483245c0113386d23698fdf6 [file] [log] [blame]
Damien Miller36884401999-12-26 12:26:21 +11001# Version of OpenSSH
Damien Miller0986b552000-11-11 08:36:38 +11002%define oversion 2.3.0p2
Damien Miller36884401999-12-26 12:26:21 +11003
4# Version of ssh-askpass
Damien Millerc78abaa2000-11-06 12:07:21 +11005%define aversion 1.0.3
Damien Miller36884401999-12-26 12:26:21 +11006
Damien Miller5a119bc2000-07-12 14:34:11 +10007# Do we want to disable building of x11-askpass? (1=yes 0=no)
8%define no_x11_askpass 0
9
10# Do we want to disable building of gnome-askpass? (1=yes 0=no)
11%define no_gnome_askpass 0
12
Damien Millerd4a8b7e1999-10-27 13:42:43 +100013Summary: OpenSSH free Secure Shell (SSH) implementation
14Name: openssh
Damien Miller36884401999-12-26 12:26:21 +110015Version: %{oversion}
Damien Millerd4a8b7e1999-10-27 13:42:43 +100016Release: 1
Damien Millerab8d1922000-08-08 16:53:28 +100017Packager: Damien Miller <djm@mindrot.org>
Damien Miller11402af2000-05-07 18:05:59 +100018URL: http://www.openssh.com/
Damien Millerab8d1922000-08-08 16:53:28 +100019Source0: ftp://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-%{oversion}.tar.gz
Damien Miller969c07e2000-11-06 13:06:43 +110020%if ! %{no_x11_askpass}
Damien Miller50f14f82000-09-01 14:14:37 +110021Source1: http://www.ntrnet.net/~jmknoble/software/x11-ssh-askpass/x11-ssh-askpass-%{aversion}.tar.gz
Damien Miller969c07e2000-11-06 13:06:43 +110022%endif
Damien Millerd4a8b7e1999-10-27 13:42:43 +100023Copyright: BSD
24Group: Applications/Internet
25BuildRoot: /tmp/openssh-%{version}-buildroot
Damien Millerc6d5ce81999-11-15 16:01:07 +110026Obsoletes: ssh
Damien Miller1383bd82000-04-06 12:32:37 +100027PreReq: openssl >= 0.9.5a
28Requires: openssl >= 0.9.5a
Damien Miller969c07e2000-11-06 13:06:43 +110029BuildPreReq: perl, openssl-devel, tcp_wrappers
Damien Millerff649d82000-10-16 13:35:19 +110030BuildPreReq: /bin/login, /usr/bin/rsh, /usr/include/security/pam_appl.h
Damien Millerab8d1922000-08-08 16:53:28 +100031%if ! %{no_gnome_askpass}
Damien Miller36884401999-12-26 12:26:21 +110032BuildPreReq: gnome-libs-devel
Damien Miller5a119bc2000-07-12 14:34:11 +100033%endif
Damien Miller36682061999-11-15 17:19:24 +110034
35%package clients
36Summary: OpenSSH Secure Shell protocol clients
Damien Millerff649d82000-10-16 13:35:19 +110037Requires: openssh = %{version}-%{release}
Damien Millerab8d1922000-08-08 16:53:28 +100038Group: Applications/Internet
Damien Millerc6d5ce81999-11-15 16:01:07 +110039Obsoletes: ssh-clients
Damien Millerd4a8b7e1999-10-27 13:42:43 +100040
Damien Miller3f51bf51999-11-09 14:46:02 +110041%package server
Damien Miller36682061999-11-15 17:19:24 +110042Summary: OpenSSH Secure Shell protocol server (sshd)
Damien Miller3f51bf51999-11-09 14:46:02 +110043Group: System Environment/Daemons
Damien Millerc6d5ce81999-11-15 16:01:07 +110044Obsoletes: ssh-server
Damien Millerff649d82000-10-16 13:35:19 +110045PreReq: openssh = %{version}-%{release}, chkconfig >= 0.9
Damien Millerb27ef9e2000-09-30 14:29:44 +110046Requires: initscripts >= 4.16
Damien Miller3f51bf51999-11-09 14:46:02 +110047
48%package askpass
Damien Miller36884401999-12-26 12:26:21 +110049Summary: OpenSSH X11 passphrase dialog
50Group: Applications/Internet
Damien Millerff649d82000-10-16 13:35:19 +110051Requires: openssh = %{version}-%{release}
Damien Miller36884401999-12-26 12:26:21 +110052Obsoletes: ssh-extras
Damien Miller36884401999-12-26 12:26:21 +110053
Damien Miller36884401999-12-26 12:26:21 +110054%package askpass-gnome
Damien Miller36682061999-11-15 17:19:24 +110055Summary: OpenSSH GNOME passphrase dialog
Damien Miller3f51bf51999-11-09 14:46:02 +110056Group: Applications/Internet
Damien Millerff649d82000-10-16 13:35:19 +110057Requires: openssh = %{version}-%{release}
Damien Miller36682061999-11-15 17:19:24 +110058Obsoletes: ssh-extras
Damien Miller3f51bf51999-11-09 14:46:02 +110059
Damien Millerd4a8b7e1999-10-27 13:42:43 +100060%description
61Ssh (Secure Shell) a program for logging into a remote machine and for
62executing commands in a remote machine. It is intended to replace
63rlogin and rsh, and provide secure encrypted communications between
64two untrusted hosts over an insecure network. X11 connections and
65arbitrary TCP/IP ports can also be forwarded over the secure channel.
66
67OpenSSH is OpenBSD's rework of the last free version of SSH, bringing it
68up to date in terms of security and features, as well as removing all
Damien Millerff649d82000-10-16 13:35:19 +110069patented algorithms to separate libraries (OpenSSL).
Damien Millerd4a8b7e1999-10-27 13:42:43 +100070
Damien Miller36682061999-11-15 17:19:24 +110071This package includes the core files necessary for both the OpenSSH
72client and server. To make this package useful, you should also
73install openssh-clients, openssh-server, or both.
74
75%description clients
76Ssh (Secure Shell) a program for logging into a remote machine and for
77executing commands in a remote machine. It is intended to replace
78rlogin and rsh, and provide secure encrypted communications between
79two untrusted hosts over an insecure network. X11 connections and
80arbitrary TCP/IP ports can also be forwarded over the secure channel.
81
82OpenSSH is OpenBSD's rework of the last free version of SSH, bringing it
83up to date in terms of security and features, as well as removing all
Damien Millerff649d82000-10-16 13:35:19 +110084patented algorithms to separate libraries (OpenSSL).
Damien Miller36682061999-11-15 17:19:24 +110085
Damien Miller3f51bf51999-11-09 14:46:02 +110086This package includes the clients necessary to make encrypted connections
87to SSH servers.
88
89%description server
90Ssh (Secure Shell) a program for logging into a remote machine and for
91executing commands in a remote machine. It is intended to replace
92rlogin and rsh, and provide secure encrypted communications between
93two untrusted hosts over an insecure network. X11 connections and
94arbitrary TCP/IP ports can also be forwarded over the secure channel.
95
96OpenSSH is OpenBSD's rework of the last free version of SSH, bringing it
97up to date in terms of security and features, as well as removing all
Damien Millerff649d82000-10-16 13:35:19 +110098patented algorithms to separate libraries (OpenSSL).
Damien Miller3f51bf51999-11-09 14:46:02 +110099
Damien Miller36682061999-11-15 17:19:24 +1100100This package contains the secure shell daemon. The sshd is the server
101part of the secure shell protocol and allows ssh clients to connect to
102your host.
Damien Miller3f51bf51999-11-09 14:46:02 +1100103
Damien Miller36884401999-12-26 12:26:21 +1100104%description askpass
105Ssh (Secure Shell) a program for logging into a remote machine and for
106executing commands in a remote machine. It is intended to replace
107rlogin and rsh, and provide secure encrypted communications between
108two untrusted hosts over an insecure network. X11 connections and
109arbitrary TCP/IP ports can also be forwarded over the secure channel.
110
111OpenSSH is OpenBSD's rework of the last free version of SSH, bringing it
112up to date in terms of security and features, as well as removing all
Damien Millerff649d82000-10-16 13:35:19 +1100113patented algorithms to separate libraries (OpenSSL).
Damien Miller36884401999-12-26 12:26:21 +1100114
115This package contains Jim Knoble's <jmknoble@pobox.com> X11 passphrase
116dialog.
Damien Miller36884401999-12-26 12:26:21 +1100117
Damien Millerf6adfa91999-12-26 13:08:15 +1100118%description askpass-gnome
Damien Miller3f51bf51999-11-09 14:46:02 +1100119Ssh (Secure Shell) a program for logging into a remote machine and for
120executing commands in a remote machine. It is intended to replace
121rlogin and rsh, and provide secure encrypted communications between
122two untrusted hosts over an insecure network. X11 connections and
123arbitrary TCP/IP ports can also be forwarded over the secure channel.
124
125OpenSSH is OpenBSD's rework of the last free version of SSH, bringing it
126up to date in terms of security and features, as well as removing all
Damien Millerff649d82000-10-16 13:35:19 +1100127patented algorithms to separate libraries (OpenSSL).
Damien Miller3f51bf51999-11-09 14:46:02 +1100128
129This package contains the GNOME passphrase dialog.
130
Damien Millerff649d82000-10-16 13:35:19 +1100131%prep
132
Damien Miller969c07e2000-11-06 13:06:43 +1100133%if ! %{no_x11_askpass}
Damien Millerff649d82000-10-16 13:35:19 +1100134%setup -q -a 1
Damien Miller969c07e2000-11-06 13:06:43 +1100135%else
136%setup -q
137%endif
Damien Millerff649d82000-10-16 13:35:19 +1100138
139%build
140
Damien Millerafeaca92000-11-11 09:09:57 +1100141%define _sysconfdir /etc/ssh
142
Damien Millerff649d82000-10-16 13:35:19 +1100143%configure \
Damien Millerff649d82000-10-16 13:35:19 +1100144 --libexecdir=%{_libexecdir}/openssh \
145 --with-tcp-wrappers \
146 --with-ipv4-default \
147 --with-rsh=/usr/bin/rsh \
148 --with-default-path=/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin
149
150make
151
152%if ! %{no_x11_askpass}
153pushd x11-ssh-askpass-%{aversion}
154xmkmf -a
155make
156popd
157%endif
158
159%if ! %{no_gnome_askpass}
160pushd contrib
161gcc -O -g `gnome-config --cflags gnome gnomeui` \
162 gnome-ssh-askpass.c -o gnome-ssh-askpass \
163 `gnome-config --libs gnome gnomeui`
164popd
165%endif
166
167%install
168rm -rf $RPM_BUILD_ROOT
169%{makeinstall} \
Damien Millerff649d82000-10-16 13:35:19 +1100170 libexecdir=$RPM_BUILD_ROOT%{_libexecdir}/openssh \
171 DESTDIR=/ # Hack to disable key generation
172
173
174install -d $RPM_BUILD_ROOT/etc/pam.d/
175install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
176install -d $RPM_BUILD_ROOT%{_libexecdir}/openssh
177install -m644 contrib/redhat/sshd.pam $RPM_BUILD_ROOT/etc/pam.d/sshd
178install -m755 contrib/redhat/sshd.init $RPM_BUILD_ROOT/etc/rc.d/init.d/sshd
179
180%if ! %{no_x11_askpass}
181install -s x11-ssh-askpass-%{aversion}/x11-ssh-askpass $RPM_BUILD_ROOT/usr/libexec/openssh/x11-ssh-askpass
182ln -s /usr/libexec/openssh/x11-ssh-askpass $RPM_BUILD_ROOT/usr/libexec/openssh/ssh-askpass
183%endif
184
185%if ! %{no_gnome_askpass}
186install -s contrib/gnome-ssh-askpass $RPM_BUILD_ROOT/usr/libexec/openssh/gnome-ssh-askpass
187%endif
188
189perl -pi -e "s|$RPM_BUILD_ROOT||g" $RPM_BUILD_ROOT%{_mandir}/man*/*
190
191%clean
192rm -rf $RPM_BUILD_ROOT
193
194%post server
195/sbin/chkconfig --add sshd
196if test -r /var/run/sshd.pid ; then
197 /etc/rc.d/init.d/sshd restart >&2
198fi
199
200%preun server
201if [ "$1" = 0 ] ; then
202 /etc/rc.d/init.d/sshd stop >&2
203 /sbin/chkconfig --del sshd
204fi
205
206%files
207%defattr(-,root,root)
Damien Miller981eeed2000-12-27 19:06:05 +1100208%doc ChangeLog OVERVIEW README* INSTALL
Damien Millerab360502000-11-06 12:52:25 +1100209%doc CREDITS LICENCE
Damien Millerff649d82000-10-16 13:35:19 +1100210%attr(0755,root,root) %{_bindir}/ssh-keygen
211%attr(0755,root,root) %{_bindir}/scp
Ben Lindstrom4cc90a42000-12-10 22:12:54 +0000212%attr(0755,root,root) %{_bindir}/ssh-keyscan
Damien Millerff649d82000-10-16 13:35:19 +1100213%attr(0644,root,root) %{_mandir}/man1/ssh-keygen.1*
Ben Lindstrom4cc90a42000-12-10 22:12:54 +0000214%attr(0644,root,root) %{_mandir}/man1/ssh-keyscan.1*
Damien Millerff649d82000-10-16 13:35:19 +1100215%attr(0644,root,root) %{_mandir}/man1/scp.1*
Damien Milleree188d32000-11-13 23:13:55 +1100216%attr(0755,root,root) %dir %{_sysconfdir}
217%attr(0600,root,root) %config(noreplace) %{_sysconfdir}/primes
Damien Millerff649d82000-10-16 13:35:19 +1100218%attr(0755,root,root) %dir %{_libexecdir}/openssh
219
220%files clients
221%defattr(-,root,root)
222%attr(4755,root,root) %{_bindir}/ssh
223%attr(0755,root,root) %{_bindir}/ssh-agent
224%attr(0755,root,root) %{_bindir}/ssh-add
225%attr(0644,root,root) %{_mandir}/man1/ssh.1*
226%attr(0644,root,root) %{_mandir}/man1/ssh-agent.1*
227%attr(0644,root,root) %{_mandir}/man1/ssh-add.1*
Damien Milleree188d32000-11-13 23:13:55 +1100228%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/ssh_config
Damien Millerff649d82000-10-16 13:35:19 +1100229%attr(-,root,root) %{_bindir}/slogin
230%attr(-,root,root) %{_mandir}/man1/slogin.1*
231
232%files server
233%defattr(-,root,root)
234%attr(0755,root,root) %{_sbindir}/sshd
235%attr(0755,root,root) %{_libexecdir}/openssh/sftp-server
236%attr(0644,root,root) %{_mandir}/man8/sshd.8*
237%attr(0644,root,root) %{_mandir}/man8/sftp-server.8*
Damien Milleree188d32000-11-13 23:13:55 +1100238%attr(0600,root,root) %config(noreplace) %{_sysconfdir}/sshd_config
Damien Millerff649d82000-10-16 13:35:19 +1100239%attr(0600,root,root) %config(noreplace) /etc/pam.d/sshd
240%attr(0755,root,root) %config /etc/rc.d/init.d/sshd
241
242%if ! %{no_x11_askpass}
243%files askpass
244%defattr(-,root,root)
245%doc x11-ssh-askpass-%{aversion}/README
246%doc x11-ssh-askpass-%{aversion}/ChangeLog
247%doc x11-ssh-askpass-%{aversion}/SshAskpass*.ad
248%attr(0755,root,root) %{_libexecdir}/openssh/ssh-askpass
249%attr(0755,root,root) %{_libexecdir}/openssh/x11-ssh-askpass
250%endif
251
252%if ! %{no_gnome_askpass}
253%files askpass-gnome
254%defattr(-,root,root)
255%attr(0755,root,root) %{_libexecdir}/openssh/gnome-ssh-askpass
256%endif
257
Damien Millerd4a8b7e1999-10-27 13:42:43 +1000258%changelog
Damien Millerff649d82000-10-16 13:35:19 +1100259* Mon Oct 18 2000 Damien Miller <djm@mindrot.org>
260- Merge some of Nalin Dahyabhai <nalin@redhat.com> changes from the
261 Redhat 7.0 spec file
Damien Miller676092f2000-09-05 14:16:18 +1100262* Tue Sep 05 2000 Damien Miller <djm@mindrot.org>
263- Use RPM configure macro
Damien Millerab8d1922000-08-08 16:53:28 +1000264* Tue Aug 08 2000 Damien Miller <djm@mindrot.org>
265- Some surgery to sshd.init (generate keys at runtime)
266- Cleanup of groups and removal of keygen calls
Damien Miller5a119bc2000-07-12 14:34:11 +1000267* Wed Jul 12 2000 Damien Miller <djm@mindrot.org>
268- Make building of X11-askpass and gnome-askpass optional
Damien Millere69f18c2000-06-12 16:38:54 +1000269* Mon Jun 12 2000 Damien Miller <djm@mindrot.org>
270- Glob manpages to catch compressed files
Damien Millerddaffa42000-03-15 12:31:18 +1100271* Wed Mar 15 2000 Damien Miller <djm@ibs.com.au>
272- Updated for new location
273- Updated for new gnome-ssh-askpass build
Damien Miller36884401999-12-26 12:26:21 +1100274* Sun Dec 26 1999 Damien Miller <djm@mindrot.org>
275- Added Jim Knoble's <jmknoble@pobox.com> askpass
Damien Miller36682061999-11-15 17:19:24 +1100276* Mon Nov 15 1999 Damien Miller <djm@mindrot.org>
277- Split subpackages further based on patch from jim knoble <jmknoble@pobox.com>
Damien Miller38c60881999-11-13 13:09:31 +1100278* Sat Nov 13 1999 Damien Miller <djm@mindrot.org>
Damien Millerc6d5ce81999-11-15 16:01:07 +1100279- Added 'Obsoletes' directives
Damien Miller742d2cb1999-11-09 14:28:26 +1100280* Tue Nov 09 1999 Damien Miller <djm@ibs.com.au>
281- Use make install
Damien Miller3f51bf51999-11-09 14:46:02 +1100282- Subpackages
Damien Miller356a0b01999-11-08 15:30:59 +1100283* Mon Nov 08 1999 Damien Miller <djm@ibs.com.au>
284- Added links for slogin
285- Fixed perms on manpages
Damien Miller2bbb9d01999-10-30 09:46:20 +1000286* Sat Oct 30 1999 Damien Miller <djm@ibs.com.au>
287- Renamed init script
Damien Miller070f7a11999-10-29 10:29:29 +1000288* Fri Oct 29 1999 Damien Miller <djm@ibs.com.au>
289- Back to old binary names
Damien Miller06230761999-10-28 14:03:14 +1000290* Thu Oct 28 1999 Damien Miller <djm@ibs.com.au>
291- Use autoconf
292- New binary names
Damien Millerd4a8b7e1999-10-27 13:42:43 +1000293* Wed Oct 27 1999 Damien Miller <djm@ibs.com.au>
294- Initial RPMification, based on Jan "Yenya" Kasprzak's <kas@fi.muni.cz> spec.
295