Skip to content

Instantly share code, notes, and snippets.

@faishal
Created October 6, 2016 14:02
Show Gist options
  • Save faishal/add912b9b4c3899ec26c488a91446a84 to your computer and use it in GitHub Desktop.
Save faishal/add912b9b4c3899ec26c488a91446a84 to your computer and use it in GitHub Desktop.
Upgrade OpenSSH to 7.3p1 in Cent OS 6
#!/bin/bash
# Copyright © 2016 Faishal Saiyed
cd
timestamp=$(date +%s)
if [ ! -f openssh-7.3.zip ]; then wget https://github.com/faishal/openssh-portable/releases/download/cent.os.6.7.openssh.7.3p1/openssh-7.3.zip; fi;
unzip -o openssh-7.3.zip -d openssh-7.3p1
cd openssh-7.3p1/
cp /etc/pam.d/sshd pam-ssh-conf-$timestamp
rpm -U *.rpm
yes | cp pam-ssh-conf-$timestamp /etc/pam.d/sshd
/etc/init.d/sshd restart
@ajiraj2411
Copy link

Hi faishal, I changed this script into ansible. when rpm -U *.rpm my machine went unreachable. I can't go to the machine. Can you help me out?

@HammerZ3it
Copy link

Do not follow @sivasshankar4s script I made a test and it changes my root password... Dude trying to hack with his work luckily I made this on a test VM.

@faishal
Copy link
Author

faishal commented Jul 31, 2020

Do not follow @sivasshankar4s script I made a test and it changes my root password... Dude trying to hack with his work luckily I made this on a test VM.

Thanks for reporting this.

@sanmuga07
Copy link

Hi Faishal, I need 7.4p1 for Centos 6.10. Can you please help?

@yuusungwoo
Copy link

awesome script! thanks a lot!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment