Last active
August 29, 2015 13:59
-
-
Save rdeavila/10649656 to your computer and use it in GitHub Desktop.
Heartbleed: ver quais programas usam a biblioteca OpenSSL, e a sua versão.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Lê os arquivos abertos, e procura por programas que estejam usando | |
# a biblioteca do OpenSSL. | |
sudo lsof +c 0 | grep -w DEL | awk '1 { print $1 ": " $NF }' | grep libssl | sort -u | |
# Depois de atualizar, o comando abaixo mostra os serviços que precisam ser | |
# reiniciados. Enquanto não reiniciar, eles ainda usarão a versão antiga: | |
sudo find /proc -maxdepth 2 -name maps -exec grep -HE '/libssl\.so.* \(deleted\)' {} \; | cut -d/ -f3 | sort -u | xargs --no-run-if-empty ps uwwp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment