Upgrading OpenSSH on CentOS 5

1) First, download the OpenSSH source tarball from the vendor and unpack it. You can find the tarballs at http://www.openssh.com/portable.html

wget http://mirror.mcs.anl.gov/openssh/portable/openssh-5.8p1.tar.gz
tar -xvzf openssh-5.8p1.tar.gz

2)Copy the spec file and tarball:

cp ./openssh-5.8p1/contrib/redhat/openssh.spec /usr/src/redhat/SPECS/
cp openssh-5.8p1.tar.gz /usr/src/redhat/SOURCES/

3)Do a little magic:

cd /usr/src/redhat/SPECS
perl -i.bak -pe ‘s/^(%define no_(gnome|x11)_askpass)\s+0$/$1 1/’ openssh.spec

4) build your RPM:

rpmbuild -bb openssh.spec

5) Now if you go back into /usr/src/redhat/RPMS/<arch> , you should see three RPMs. Go ahead and install them:

rpm -Uvh *.rpm

To verify the installed version, just type ‘ssh -v localhost’ and you should see the banner come up, indicating the new version.

 

 


Both comments and pings are currently closed.

Comments are closed.