Back to hostname
This commit is contained in:
parent
ff55d42e29
commit
c9ee053494
|
@ -154,7 +154,7 @@ function any_key_verify {
|
||||||
dialog --title $"Check tripwire" \
|
dialog --title $"Check tripwire" \
|
||||||
--msgbox $"\nThe hash should not contain any spaces" 10 40
|
--msgbox $"\nThe hash should not contain any spaces" 10 40
|
||||||
else
|
else
|
||||||
DBHASH=$(sha512sum /var/lib/tripwire/${PROJECT_NAME}.twd | awk -F ' ' '{print $1}')
|
DBHASH=$(sha512sum /var/lib/tripwire/${HOSTNAME}.twd | awk -F ' ' '{print $1}')
|
||||||
if [[ "$DBHASH" == "$GIVEN_HASH" ]]; then
|
if [[ "$DBHASH" == "$GIVEN_HASH" ]]; then
|
||||||
dialog --title $"Check tripwire" \
|
dialog --title $"Check tripwire" \
|
||||||
--msgbox $"\nSuccess\n\nThe hash you gave matches the current tripwire database" 10 40
|
--msgbox $"\nSuccess\n\nThe hash you gave matches the current tripwire database" 10 40
|
||||||
|
@ -1305,7 +1305,7 @@ function security_settings {
|
||||||
}
|
}
|
||||||
|
|
||||||
function show_tripwire_verification_code {
|
function show_tripwire_verification_code {
|
||||||
if [ ! -f /var/lib/tripwire/${PROJECT_NAME}.twd ]; then
|
if [ ! -f /var/lib/tripwire/${HOSTNAME}.twd ]; then
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
clear
|
clear
|
||||||
|
@ -1346,7 +1346,7 @@ function reset_tripwire {
|
||||||
echo $'Creating tripwire database'
|
echo $'Creating tripwire database'
|
||||||
echo '
|
echo '
|
||||||
|
|
||||||
' | tripwire --init --cfgfile /etc/tripwire/tw.cfg --polfile /etc/tripwire/tw.pol --dbfile /var/lib/tripwire/${PROJECT_NAME}.twd
|
' | tripwire --init --cfgfile /etc/tripwire/tw.cfg --polfile /etc/tripwire/tw.pol --dbfile /var/lib/tripwire/${HOSTNAME}.twd
|
||||||
echo $'Resetting the Tripwire...'
|
echo $'Resetting the Tripwire...'
|
||||||
echo ''
|
echo ''
|
||||||
echo '
|
echo '
|
||||||
|
@ -1361,7 +1361,7 @@ function reset_tripwire {
|
||||||
systemctl restart nginx
|
systemctl restart nginx
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -f /var/lib/tripwire/${PROJECT_NAME}.twd ]; then
|
if [ -f /var/lib/tripwire/${HOSTNAME}.twd ]; then
|
||||||
show_tripwire_verification_code
|
show_tripwire_verification_code
|
||||||
echo $'Tripwire is now reset. Take a note of the above hash, or record'
|
echo $'Tripwire is now reset. Take a note of the above hash, or record'
|
||||||
echo $'the QR code using a mobile device. This will enable you to independently'
|
echo $'the QR code using a mobile device. This will enable you to independently'
|
||||||
|
|
Loading…
Reference in New Issue