projects
/
ossec-hids.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
obrisane nepotrebne datoteke od zadnjeg builda
[ossec-hids.git]
/
src
/
agentlessd
/
scripts
/
ssh_integrity_check_linux
diff --git
a/src/agentlessd/scripts/ssh_integrity_check_linux
b/src/agentlessd/scripts/ssh_integrity_check_linux
index
df69215
..
51b5796
100755
(executable)
--- a/
src/agentlessd/scripts/ssh_integrity_check_linux
+++ b/
src/agentlessd/scripts/ssh_integrity_check_linux
@@
-1,22
+1,19
@@
#!/usr/bin/env expect
#!/usr/bin/env expect
-# @(#) $Id: ssh_integrity_check_linux,v 1.11 2009/06/24 17:06:21 dcid Exp $
# Agentless monitoring
#
# Copyright (C) 2009 Trend Micro Inc.
# All rights reserved.
# Agentless monitoring
#
# Copyright (C) 2009 Trend Micro Inc.
# All rights reserved.
-#
+#
# This program is a free software; you can redistribute it
# and/or modify it under the terms of the GNU General Public
# This program is a free software; you can redistribute it
# and/or modify it under the terms of the GNU General Public
-# License (version 3) as published by the FSF - Free Software
+# License (version 2) as published by the FSF - Free Software
# Foundation.
# Foundation.
-
-# Main script.
+# Main script
source "agentless/main.exp"
source "agentless/main.exp"
-
-# SSHing to the box and passing the directories to check.
+# SSH to the box and pass the directories to check
if [catch {
spawn ssh $hostname
} loc_error] {
if [catch {
spawn ssh $hostname
} loc_error] {
@@
-24,12
+21,11
@@
if [catch {
exit 1;
}
exit 1;
}
-
source $sshsrc
source $susrc
set timeout 600
source $sshsrc
source $susrc
set timeout 600
-send "echo \"INFO: Starting.\"; for i in `find $args 2>/dev/null`;do tail \$i >/dev/null 2>&1 && md5=`md5sum \$i | cut -d \" \" -f 1` && sha1=`sha1sum \$i | cut -d \" \" -f 1` && echo FWD: `stat --printf \"%s:%a:%u:%g\" \$i`:\$md5:\$sha1 \$i; done; exit\r"
+send "unset HISTFILE echo \"INFO: Starting.\"; for i in `find $args 2>/dev/null`;do tail \$i >/dev/null 2>&1 && md5=`md5sum \$i | cut -d \" \" -f 1` && sha1=`sha1sum \$i | cut -d \" \" -f 1` && echo FWD: `stat --printf \"%s:%a:%u:%g\" \$i`:\$md5:\$sha1 \$i; done; exit\r"
send "exit\r"
expect {
send "exit\r"
expect {