Shell Shock instalacja łatki: Różnice pomiędzy wersjami
Z ToProste
m (Utworzył nową stronę „== Patch dla Debian 6 == <syntaxhighlight lang="bash"> # check to ensure vulnerable env x='() { :;}; echo vulnerable' bash -c "echo this is a test" # make sure you are ...”) |
m |
||
Linia 1: | Linia 1: | ||
+ | Używasz Linuxa? Sprawdź czy Twój [[bash]] jest odporny na Shell Shock. Wydaj w [[Konsola |konsoli]] następujące polecenie: | ||
+ | <syntaxhighlight lang="bash">env x='() { :;}; echo vulnerable' bash -c "echo this is a test"</syntaxhighlight> | ||
+ | jeśli wynikiem jest: | ||
+ | <syntaxhighlight lang="text"> | ||
+ | vulnerable | ||
+ | this is a test | ||
+ | </syntaxhighlight> | ||
+ | to znaczy że masz problem! | ||
+ | Niżej zamieszone są skrypty które załatają tę lukę. | ||
+ | |||
+ | |||
== Patch dla Debian 6 == | == Patch dla Debian 6 == | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
Linia 55: | Linia 66: | ||
env x='() { :;}; echo vulnerable' bash -c "echo this is a test" | env x='() { :;}; echo vulnerable' bash -c "echo this is a test" | ||
</syntaxhighlight> | </syntaxhighlight> | ||
+ | |||
+ | |||
+ | [[Kategoria:Linux]] |
Wersja z 20:57, 25 wrz 2014
Używasz Linuxa? Sprawdź czy Twój bash jest odporny na Shell Shock. Wydaj w konsoli następujące polecenie:
env x='() { :;}; echo vulnerable' bash -c "echo this is a test"
jeśli wynikiem jest:
vulnerable this is a test
to znaczy że masz problem! Niżej zamieszone są skrypty które załatają tę lukę.
Patch dla Debian 6
# check to ensure vulnerable env x='() { :;}; echo vulnerable' bash -c "echo this is a test" # make sure you are on debian 6 cat /etc/issue # add the LTS sec repo echo "#LTS security" >> /etc/apt/sources.list echo "deb http://http.debian.net/debian/ squeeze-lts main contrib non-free" >> /etc/apt/sources.list echo "deb-src http://http.debian.net/debian/ squeeze-lts main contrib non-free" >> /etc/apt/sources.list # update and install patched bash apt-get update apt-get install bash # run a new shell bash # check patch success env x='() { :;}; echo vulnerable' bash -c "echo this is a test"
Patch dla Debian 7
# check to ensure vulnerable env x='() { :;}; echo vulnerable' bash -c "echo this is a test" # make sure you are on debian 7 cat /etc/issue # update and install patched bash apt-get update apt-get install bash # run a new shell bash # check patch success env x='() { :;}; echo vulnerable' bash -c "echo this is a test"
Patch dla Centos 6/7
# check vulnerability env x='() { :;}; echo vulnerable' bash -c "echo this is a test" yum -y install bash or yum -y update # check patch success env x='() { :;}; echo vulnerable' bash -c "echo this is a test"