[1] | 1 | #! /bin/sh
|
---|
| 2 |
|
---|
[27] | 3 | #
|
---|
| 4 | # Copyright Rainer Wichmann (2006)
|
---|
| 5 | #
|
---|
| 6 | # License Information:
|
---|
| 7 | # This program is free software; you can redistribute it and/or modify
|
---|
| 8 | # it under the terms of the GNU General Public License as published by
|
---|
| 9 | # the Free Software Foundation; either version 2 of the License, or
|
---|
| 10 | # (at your option) any later version.
|
---|
| 11 | #
|
---|
| 12 | # This program is distributed in the hope that it will be useful,
|
---|
| 13 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
| 15 | # GNU General Public License for more details.
|
---|
| 16 | #
|
---|
| 17 | # You should have received a copy of the GNU General Public License
|
---|
| 18 | # along with this program; if not, write to the Free Software
|
---|
| 19 | # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
---|
| 20 | #
|
---|
| 21 |
|
---|
[30] | 22 | # -----------------------------------------------------------------------
|
---|
| 23 | # Be Bourne compatible
|
---|
| 24 | # -----------------------------------------------------------------------
|
---|
| 25 |
|
---|
| 26 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
|
---|
| 27 | emulate sh
|
---|
| 28 | NULLCMD=:
|
---|
| 29 | elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
|
---|
| 30 | set -o posix
|
---|
| 31 | fi
|
---|
| 32 |
|
---|
| 33 | # -----------------------------------------------------------------------
|
---|
| 34 | # Make sure we support functions (from the autoconf manual)
|
---|
| 35 | # -----------------------------------------------------------------------
|
---|
| 36 |
|
---|
| 37 | TSHELL="${TSHELL-/bin/sh}"
|
---|
| 38 | if test x"$1" = "x--re-executed"
|
---|
| 39 | then
|
---|
| 40 | shift
|
---|
| 41 | elif "$TSHELL" -c 'foo () { (exit 0); exit 0; }; foo' >/dev/null 2>&1
|
---|
| 42 | then
|
---|
| 43 | :
|
---|
| 44 | else
|
---|
| 45 | for cmd in sh bash ash bsh ksh zsh sh5; do
|
---|
| 46 | X="$PATH:/bin:/usr/bin:/usr/afsws/bin:/usr/ucb:/usr/xpg4/bin";
|
---|
| 47 | OLD_IFS=${IFS}
|
---|
| 48 | IFS=':'; export IFS
|
---|
| 49 | for dir in $X; do
|
---|
| 50 | shell="$dir/$cmd"
|
---|
| 51 | if (test -f "$shell" || test -f "$shell.exe")
|
---|
| 52 | then
|
---|
| 53 | if "$shell" -c 'foo () { (exit 0); exit 0; }; foo' >/dev/null 2>&1
|
---|
| 54 | then
|
---|
| 55 | TSHELL="$shell"; export TSHELL
|
---|
| 56 | IFS=${OLD_IFS}; export IFS
|
---|
| 57 | exec "$shell" "$0" --re-executed ${1+"$@"}
|
---|
| 58 | fi
|
---|
| 59 | fi
|
---|
| 60 | done
|
---|
| 61 | IFS=${OLD_IFS}; export IFS
|
---|
| 62 | done
|
---|
| 63 | echo "-----------------------------------------------------------------"
|
---|
| 64 | echo "ERROR: Unable to locate a shell interpreter with function support" >&2
|
---|
| 65 | echo "-----------------------------------------------------------------"
|
---|
| 66 | { (exit 1); exit 1; }
|
---|
| 67 | fi
|
---|
| 68 |
|
---|
| 69 | # -----------------------------------------------------------------------
|
---|
| 70 | # Make sure we support 'let' (from the autoconf manual)
|
---|
| 71 | # -----------------------------------------------------------------------
|
---|
| 72 |
|
---|
| 73 | TSHELL="${TSHELL-/bin/sh}"
|
---|
| 74 | if test x"$1" = "x--re-run"
|
---|
| 75 | then
|
---|
| 76 | shift
|
---|
| 77 | elif "$TSHELL" -c 'a=5; let "a = a + 5"' >/dev/null 2>&1
|
---|
| 78 | then
|
---|
| 79 | :
|
---|
| 80 | else
|
---|
| 81 | for cmd in sh bash ash bsh ksh zsh sh5; do
|
---|
| 82 | X="$PATH:/bin:/usr/bin:/usr/afsws/bin:/usr/ucb:/usr/xpg4/bin";
|
---|
| 83 | OLD_IFS=${IFS}
|
---|
| 84 | IFS=':'; export IFS
|
---|
| 85 | for dir in $X; do
|
---|
| 86 | shell="$dir/$cmd"
|
---|
| 87 | if (test -f "$shell" || test -f "$shell.exe")
|
---|
| 88 | then
|
---|
| 89 | if "$shell" -c 'foo () { (exit 0); exit 0; }; foo' >/dev/null 2>&1
|
---|
| 90 | then
|
---|
| 91 | if "$shell" -c 'a=5; let "a = a + 5"' >/dev/null 2>&1
|
---|
| 92 | then
|
---|
| 93 | TSHELL="$shell"; export TSHELL
|
---|
| 94 | IFS=${OLD_IFS}; export IFS
|
---|
| 95 | exec "$shell" "$0" --re-run ${1+"$@"}
|
---|
| 96 | fi
|
---|
| 97 | fi
|
---|
| 98 | fi
|
---|
| 99 | done
|
---|
| 100 | IFS=${OLD_IFS}; export IFS
|
---|
| 101 | done
|
---|
| 102 | echo "-----------------------------------------------------------------"
|
---|
| 103 | echo "ERROR: Unable to locate a shell interpreter with support for 'let'" >&2
|
---|
| 104 | echo "-----------------------------------------------------------------"
|
---|
| 105 | { (exit 1); exit 1; }
|
---|
| 106 | fi
|
---|
| 107 |
|
---|
| 108 |
|
---|
| 109 | umask 0022
|
---|
| 110 |
|
---|
[19] | 111 | isok=`test -t 1 2>&1 | wc -c`
|
---|
| 112 | if [ "$isok" -eq 0 ]; then
|
---|
| 113 | test -t 1
|
---|
| 114 | isok=$?
|
---|
| 115 | fi
|
---|
[1] | 116 |
|
---|
| 117 | # The following two are the ANSI sequences for start and end embolden
|
---|
[19] | 118 | if [ x"$isok" = x0 ]; then
|
---|
| 119 | case $TERM in
|
---|
| 120 | vt*|ansi*|con*|xterm*|linux*|screen*|rxvt*)
|
---|
| 121 | S='[1;30m'
|
---|
| 122 | R=[31m
|
---|
| 123 | G=[32m
|
---|
| 124 | B=[36m
|
---|
| 125 | E=[m
|
---|
| 126 | ;;
|
---|
| 127 | *)
|
---|
| 128 | S=
|
---|
| 129 | R=
|
---|
| 130 | G=
|
---|
| 131 | B=
|
---|
| 132 | E=
|
---|
| 133 | ;;
|
---|
| 134 | esac
|
---|
| 135 | fi
|
---|
[1] | 136 |
|
---|
[19] | 137 |
|
---|
| 138 | usage() {
|
---|
| 139 | echo "test.sh [options] <test_number> [hostname]"
|
---|
[68] | 140 | echo " [-q|--quiet|-v|--verbose] [-s|--stoponerr] [-n|--no-cleanup]"
|
---|
[19] | 141 | echo " [--srcdir=top_srcdir] [--color=always|never|auto]"
|
---|
| 142 | echo
|
---|
| 143 | echo " ${S}test.sh 1${E} -- Compile with many different options"
|
---|
| 144 | echo " ${S}test.sh 2${E} -- Hash function (testrc_1)"
|
---|
| 145 | echo " ${S}test.sh 3${E} -- Standalone init/check"
|
---|
| 146 | echo " ${S}test.sh 4${E} -- Microstealth init/check"
|
---|
| 147 | echo " ${S}test.sh 5${E} -- External program call (testrc_1ext.in)"
|
---|
| 148 | echo " ${S}test.sh 6${E} -- Controlling the daemon"
|
---|
| 149 | echo " ${S}test.sh 7${E} -- GnuPG signed files / prelude log"
|
---|
[22] | 150 | echo " ${S}test.sh 8${E} -- Suidcheck"
|
---|
[68] | 151 | echo " ${S}test.sh 9${E} -- Process check"
|
---|
| 152 | echo " ${S}test.sh 10${E} -- Port check"
|
---|
[481] | 153 | echo " ${S}test.sh 11${E} -- CL verify option"
|
---|
| 154 | echo " ${S}test.sh 12${E} -- CL create DeltaDB"
|
---|
| 155 | echo " ${S}test.sh 13${E} -- CL create/verify partial DB"
|
---|
[550] | 156 | echo " ${S}test.sh 14${E} -- Signify signed files"
|
---|
[19] | 157 |
|
---|
[68] | 158 | echo " ${S}test.sh 20${E} -- Test c/s init/check (testrc_2.in)"
|
---|
| 159 | echo " ${S}test.sh 21${E} -- Test full c/s init/check (testrc_2.in)"
|
---|
| 160 | echo " ${S}test.sh 22${E} -- Test full c/s w/gpg (testrc_2.in)"
|
---|
| 161 | echo " ${S}test.sh 23${E} -- Test full c/s w/mysql (testrc_2.in)"
|
---|
| 162 | echo " ${S}test.sh 24${E} -- Test full c/s w/postgres (testrc_2.in)"
|
---|
[481] | 163 | echo " ${S}test.sh 25${E} -- Test server w/yulectl (testrc_2.in)"
|
---|
| 164 | echo " ${S}test.sh 26${E} -- Test c/s case one (testrc_2.in)"
|
---|
| 165 | echo " ${S}test.sh 27${E} -- Test c/s case two (testrc_2.in)"
|
---|
[22] | 166 | echo " ${S}test.sh all${E} -- All tests"
|
---|
| 167 | }
|
---|
| 168 | scripts () {
|
---|
[19] | 169 | echo
|
---|
[22] | 170 | echo "Scripts used by tests:"
|
---|
[19] | 171 | echo " (1) testcompile.sh (2) testhash.sh (3) testrun_1.sh (4) testrun_1a.sh"
|
---|
[22] | 172 | echo " (5) testext.sh (6) testtimesrv.sh (7) testrun_1b.sh (8) testrun_1c.sh"
|
---|
[481] | 173 | echo " (9) testrun_1d.sh (10) testrun_1e.sh (11) testrun_1f.sh (12) testrun_1g.sh"
|
---|
[550] | 174 | echo " (13) testrun_1h.sh (14) testrun_1i.sh"
|
---|
[68] | 175 | echo " (20) testrun_2.sh (21) testrun_2a.sh (22) testrun_2b.sh (23) testrun_2c.sh"
|
---|
[481] | 176 | echo " (24) testrun_2d.sh (25) testrun_2e.sh (26) testrun_2f.sh (27) testrun_2g.sh"
|
---|
[19] | 177 | }
|
---|
| 178 |
|
---|
| 179 | #
|
---|
| 180 | # Option parsing
|
---|
| 181 | #
|
---|
| 182 | verbose=
|
---|
| 183 | quiet=
|
---|
| 184 | stoponerr=
|
---|
| 185 | color=auto
|
---|
| 186 | cleanup=on
|
---|
| 187 | doall=
|
---|
[22] | 188 | usevalgrind=
|
---|
[19] | 189 |
|
---|
| 190 | while [ $# -gt 0 ]
|
---|
| 191 | do
|
---|
| 192 | case "$1" in
|
---|
| 193 | -h|--help) usage; exit 0;;
|
---|
[22] | 194 | --scripts) usage; scripts; exit 0;;
|
---|
[19] | 195 | -v|--verbose) verbose=on; quiet= ;;
|
---|
| 196 | -q|--quiet) quiet=on; verbose= ;;
|
---|
| 197 | -s|--stoponerr) stoponerr=on;;
|
---|
[68] | 198 | -n|--no-cleanup) cleanup= ;;
|
---|
[19] | 199 | --really-all) doall=on;;
|
---|
[22] | 200 | --valgrind) usevalgrind=on;;
|
---|
[19] | 201 | --srcdir=*) TOP_SRCDIR=`echo $1 | sed s,--srcdir=,,`; export TOP_SRCDIR;;
|
---|
| 202 | --color=*)
|
---|
| 203 | arg=`echo $1 | sed s,--color=,,`
|
---|
| 204 | case $arg in
|
---|
| 205 | auto) ;;
|
---|
| 206 | never|none|no)
|
---|
| 207 | S=
|
---|
| 208 | R=
|
---|
| 209 | G=
|
---|
| 210 | B=
|
---|
| 211 | E=
|
---|
| 212 | ;;
|
---|
| 213 | always|yes)
|
---|
| 214 | S='[1;30m'
|
---|
| 215 | R=[31m
|
---|
| 216 | G=[32m
|
---|
| 217 | G=[36m
|
---|
| 218 | E=[m
|
---|
| 219 | ;;
|
---|
| 220 | *) echo "Invalid argument $1"; exit 1;;
|
---|
| 221 | esac
|
---|
| 222 | ;;
|
---|
| 223 | -*) echo "Invalid argument $1"; exit 1;;
|
---|
| 224 | *) break;;
|
---|
| 225 | esac
|
---|
| 226 | shift
|
---|
| 227 | done
|
---|
| 228 |
|
---|
| 229 | export verbose
|
---|
| 230 | export quiet
|
---|
| 231 | export stoponerr
|
---|
| 232 | export cleanup
|
---|
| 233 | export doall
|
---|
| 234 | export S; export R; export G; export B; export E;
|
---|
| 235 |
|
---|
[1] | 236 | SCRIPTDIR=.
|
---|
| 237 |
|
---|
[19] | 238 | #
|
---|
| 239 | # 'make test' will copy the 'test' subdirectory and replace TEST_SRCDIR
|
---|
| 240 | #
|
---|
[1] | 241 | TEST_SRCDIR="XXXSRCXXX";
|
---|
| 242 | if test "x${TOP_SRCDIR}" = x; then
|
---|
| 243 | # not within source tree, and not called with 'make testN'
|
---|
| 244 | if test -f "${TEST_SRCDIR}/src/samhain.c"; then
|
---|
| 245 | TOP_SRCDIR="${TEST_SRCDIR}"; export TOP_SRCDIR
|
---|
| 246 | if test -f test/testcompile.sh; then
|
---|
| 247 | SCRIPTDIR=test
|
---|
| 248 | fi
|
---|
| 249 | # not within source tree, not called by 'make', and in 'test' subdir
|
---|
| 250 | elif test -f "../${TEST_SRCDIR}/src/samhain.c"; then
|
---|
| 251 | cd ..
|
---|
| 252 | SCRIPTDIR=test
|
---|
| 253 | TOP_SRCDIR="${TEST_SRCDIR}"; export TOP_SRCDIR
|
---|
| 254 | # within source tree, and not called with 'make testN'
|
---|
| 255 | else
|
---|
| 256 | if test -f ../src/samhain.c; then
|
---|
| 257 | cd ..
|
---|
| 258 | SCRIPTDIR=test
|
---|
| 259 | TOP_SRCDIR=.
|
---|
| 260 | export TOP_SRCDIR
|
---|
| 261 | elif test -f ./src/samhain.c; then
|
---|
| 262 | SCRIPTDIR=test
|
---|
| 263 | TOP_SRCDIR=.
|
---|
| 264 | export TOP_SRCDIR
|
---|
| 265 | else
|
---|
[19] | 266 | echo "Please use --srcdir=DIR, where DIR should be the"
|
---|
[1] | 267 | echo "top directory in the samhain source tree."
|
---|
| 268 | exit 1
|
---|
| 269 | fi
|
---|
| 270 | fi
|
---|
| 271 | else
|
---|
[19] | 272 | # called by make, or with --srcdir=TOP_SRCDIR
|
---|
| 273 | if test -f "${TOP_SRCDIR}/src/samhain.c"; then
|
---|
| 274 | SCRIPTDIR="${TOP_SRCDIR}/test"
|
---|
| 275 | elif test -f "../${TOP_SRCDIR}/src/samhain.c"; then
|
---|
| 276 | cd ..; SCRIPTDIR="${TOP_SRCDIR}/test"
|
---|
[1] | 277 | else
|
---|
[19] | 278 | echo "Please use --srcdir=DIR, where DIR should be the"
|
---|
| 279 | echo "top directory in the samhain source tree."
|
---|
| 280 | exit 1
|
---|
[1] | 281 | fi
|
---|
| 282 | fi
|
---|
| 283 |
|
---|
| 284 | export SCRIPTDIR
|
---|
| 285 |
|
---|
| 286 | PW_DIR=`pwd`; export PW_DIR
|
---|
[29] | 287 |
|
---|
[19] | 288 | #
|
---|
[29] | 289 | # group/world writeable will cause problems
|
---|
[19] | 290 | #
|
---|
[29] | 291 | chmod go-w .
|
---|
[19] | 292 | #
|
---|
[29] | 293 | #
|
---|
| 294 | #
|
---|
[128] | 295 | if test x$UID != x -a x$UID != x0; then
|
---|
[19] | 296 | TRUST="--with-trusted=0,2,$UID"
|
---|
| 297 | else
|
---|
[128] | 298 | TRUST="--with-trusted=0,2,1000"
|
---|
[19] | 299 | fi
|
---|
| 300 | export TRUST
|
---|
| 301 | #
|
---|
| 302 | # find a good 'make'
|
---|
| 303 | #
|
---|
| 304 | MAKE=`which gmake`
|
---|
| 305 | if test "x$?" = x1 ; then
|
---|
[170] | 306 | MAKE="make -s -j 3"
|
---|
[19] | 307 | else
|
---|
| 308 | MAKE=`which gmake | sed -e "s%\([a-z:]\) .*%\1%g"`
|
---|
| 309 | if test "x$MAKE" = x; then
|
---|
| 310 | MAKE="make -s"
|
---|
| 311 | elif test "x$MAKE" = xno; then
|
---|
| 312 | MAKE="make -s"
|
---|
| 313 | else
|
---|
| 314 | if test "x$MAKE" = "xwhich:"; then
|
---|
| 315 | MAKE="make -s"
|
---|
| 316 | else
|
---|
| 317 | MAKE="gmake -s"
|
---|
| 318 | gmake -v >/dev/null 2>&1 || MAKE="make -s"
|
---|
| 319 | fi
|
---|
| 320 | fi
|
---|
| 321 | fi
|
---|
| 322 | export MAKE
|
---|
[1] | 323 |
|
---|
[19] | 324 | failcount=0
|
---|
| 325 | okcount=0
|
---|
| 326 | skipcount=0
|
---|
| 327 | global_count=0
|
---|
| 328 | last_count=0
|
---|
| 329 |
|
---|
| 330 | # args: #test, #total, status, optional msg
|
---|
| 331 | log_msg ()
|
---|
| 332 | {
|
---|
| 333 | if [ x"$COLUMNS" != x ]; then
|
---|
| 334 | TERMWIDTH=$COLUMNS
|
---|
| 335 | elif [ x"$COLS" != x ]; then
|
---|
| 336 | TERMWIDTH=$COLS
|
---|
| 337 | else
|
---|
| 338 | TERMWIDTH=80
|
---|
| 339 | fi
|
---|
| 340 | cols=66;
|
---|
| 341 | #
|
---|
| 342 | if [ $1 -eq 0 ]; then
|
---|
| 343 | msg=" ${4}"
|
---|
| 344 | else
|
---|
| 345 | if [ ${1} -eq 1 ]; then
|
---|
| 346 | global_count=${last_count}
|
---|
| 347 | fi
|
---|
| 348 | let "v = $1 + global_count" >/dev/null
|
---|
| 349 | last_count=${v}
|
---|
| 350 | dd=''; if [ $v -lt 10 ]; then dd=" "; fi
|
---|
| 351 | dt=''; if [ $2 -lt 10 ]; then dt=" "; fi
|
---|
| 352 | if [ -z "$4" ]; then
|
---|
| 353 | msg=" test ${dd}${v}/${dt}${2}"
|
---|
| 354 | else
|
---|
| 355 | msg=" test ${dd}${v}/${dt}${2} ${4}"
|
---|
| 356 | fi
|
---|
| 357 | fi
|
---|
| 358 | #
|
---|
| 359 | if [ x"$3" = xfailure ]; then
|
---|
| 360 | ccode=$R
|
---|
| 361 | elif [ x"$3" = xsuccess ]; then
|
---|
| 362 | ccode=$G
|
---|
| 363 | else
|
---|
| 364 | ccode=$B
|
---|
| 365 | fi
|
---|
| 366 | if [ -z "${R}" ]; then
|
---|
| 367 | echo " [${3}] ${msg}"
|
---|
| 368 | else
|
---|
| 369 | # len=${#...} is not bourne shell
|
---|
| 370 | # also, need to account for terminal control sequences
|
---|
| 371 | len=`echo "$msg" | awk '/1;30m/ { print length()-10; }; !/1;30m/ { print length();}'`
|
---|
| 372 | let "cols = cols - len" >/dev/null
|
---|
[171] | 373 | if [ $cols -ge 0 ]; then
|
---|
| 374 | moveto='['$cols'C'
|
---|
| 375 | echo "${msg}${moveto}${ccode}[${3}]${E}"
|
---|
| 376 | else
|
---|
| 377 | echo "${msg}${ccode}[${3}]${E}"
|
---|
| 378 | fi
|
---|
[19] | 379 | fi
|
---|
| 380 | }
|
---|
| 381 |
|
---|
| 382 | log_fail () {
|
---|
[68] | 383 | [ -z "$quiet" ] && log_msg "$1" "$2" failure "$3";
|
---|
[19] | 384 | let "failcount = failcount + 1" >/dev/null;
|
---|
| 385 | test -z "$stoponerr" || exit 1;
|
---|
| 386 | }
|
---|
| 387 | log_ok () {
|
---|
[68] | 388 | [ -z "$quiet" ] && log_msg "$1" "$2" success "$3";
|
---|
[19] | 389 | let "okcount = okcount + 1" >/dev/null;
|
---|
| 390 | }
|
---|
| 391 | log_skip () {
|
---|
[68] | 392 | [ -z "$quiet" ] && log_msg "$1" "$2" skipped "$3";
|
---|
[19] | 393 | let "skipcount = skipcount + 1" >/dev/null;
|
---|
| 394 | }
|
---|
| 395 |
|
---|
| 396 | log_msg_fail () { log_msg 0 0 failure "$1"; }
|
---|
| 397 | log_msg_ok () { log_msg 0 0 success "$1"; }
|
---|
| 398 | log_msg_skip () { log_msg 0 0 skipped "$1"; }
|
---|
| 399 |
|
---|
| 400 | log_start () {
|
---|
| 401 | if [ -z "$quiet" ]; then
|
---|
| 402 | echo;
|
---|
| 403 | echo "${S}__ START TEST ${1} __${E}";
|
---|
| 404 | echo;
|
---|
| 405 | fi
|
---|
| 406 | }
|
---|
| 407 | log_end () {
|
---|
| 408 | if [ -n "$verbose" ]; then
|
---|
| 409 | echo;
|
---|
| 410 | echo "${S}__ END TEST ${1} __${E}";
|
---|
| 411 | echo;
|
---|
| 412 | fi
|
---|
| 413 | }
|
---|
| 414 |
|
---|
[51] | 415 | # This looks silly, but with solaris10/i386 on vmware,
|
---|
| 416 | # 'sleep' occasionally does not sleep...
|
---|
| 417 |
|
---|
| 418 | one_sec_sleep () {
|
---|
| 419 | onesdate=`date`
|
---|
| 420 | onestest=0
|
---|
| 421 | while [ $onestest -eq 0 ]; do
|
---|
| 422 | sleep 1
|
---|
| 423 | twosdate=`date`
|
---|
| 424 | if [ "x$twosdate" = "x$onesdate" ]; then
|
---|
| 425 | onestest=0
|
---|
| 426 | else
|
---|
| 427 | onestest=1
|
---|
| 428 | fi
|
---|
| 429 | done
|
---|
| 430 | }
|
---|
| 431 |
|
---|
| 432 | five_sec_sleep () {
|
---|
| 433 | for f in 1 2 3 4 5; do
|
---|
| 434 | one_sec_sleep
|
---|
| 435 | done
|
---|
| 436 | }
|
---|
| 437 |
|
---|
[19] | 438 | do_cleanup () {
|
---|
| 439 | rm -f testrc_1.dyn
|
---|
| 440 | rm -f testrc_2
|
---|
[27] | 441 | rm -f testrc_22
|
---|
[235] | 442 | rm -f testrc_1ext
|
---|
[19] | 443 | rm -f ./.samhain_file
|
---|
[481] | 444 | rm -f file.*.*-*-*-*-*
|
---|
[19] | 445 | rm -f ./.samhain_log*
|
---|
[27] | 446 | rm -f ./.samhain_lock*
|
---|
[172] | 447 | test -d testrun_testdata && chmod -f -R 0700 testrun_testdata
|
---|
[22] | 448 | test -d .quarantine && rm -rf .quarantine
|
---|
| 449 | rm -rf testrun_testdata
|
---|
[19] | 450 | rm -f test_log_db
|
---|
| 451 | rm -f test_log_prelude
|
---|
[27] | 452 | rm -f test_log_valgrind*
|
---|
[22] | 453 | rm -f test_log_yulectl
|
---|
| 454 | rm -f yule.html
|
---|
[27] | 455 | rm -f yule.html2
|
---|
[171] | 456 | rm -f test_dnmalloc
|
---|
[481] | 457 | rm -f tmp_list_file
|
---|
| 458 | rm -f test_filter.txt
|
---|
[19] | 459 | }
|
---|
| 460 |
|
---|
| 461 | print_summary ()
|
---|
| 462 | {
|
---|
[68] | 463 | # let "gcount = okcount + skipcount + failcount" >/dev/null;
|
---|
| 464 | gcount=$MAXTEST;
|
---|
| 465 | let "failcount = gcount - okcount - skipcount" >/dev/null;
|
---|
| 466 |
|
---|
[19] | 467 | [ -z "$quiet" ] && {
|
---|
| 468 | echo
|
---|
| 469 | echo "__ ${S}Tests: ${gcount} Ok: ${okcount} Skipped: ${skipcount} Failed: ${failcount}${E}"
|
---|
| 470 | }
|
---|
| 471 | if [ $failcount -eq 0 ]; then
|
---|
| 472 | [ -z "$quiet" ] && { echo "__ ${G}All tests passed successfully.${E}"; echo; }
|
---|
| 473 | elif [ $failcount -eq 1 ]; then
|
---|
| 474 | [ -z "$quiet" ] && { echo "__ ${R}There was 1 failure.${E}"; echo; }
|
---|
| 475 | else
|
---|
| 476 | [ -z "$quiet" ] && { echo "__ ${R}There were $failcount failures.${E}"; echo; }
|
---|
| 477 | fi
|
---|
| 478 | [ -z "$cleanup" ] || do_cleanup;
|
---|
| 479 | }
|
---|
| 480 |
|
---|
| 481 | find_path () { (
|
---|
| 482 | save_IFS=$IFS; IFS=:
|
---|
| 483 |
|
---|
| 484 | for dir in $PATH; do
|
---|
| 485 | IFS=$as_save_IFS
|
---|
| 486 | test -z "$dir" && dir=.
|
---|
| 487 | if test -f "$dir/$1"; then
|
---|
| 488 | echo "$dir/$1";
|
---|
| 489 | break;
|
---|
| 490 | fi
|
---|
| 491 | done
|
---|
| 492 | IFS=${save_IFS};
|
---|
| 493 | ); }
|
---|
| 494 |
|
---|
| 495 | find_hostname () {
|
---|
[174] | 496 |
|
---|
| 497 | uname -a | grep Linux >/dev/null
|
---|
| 498 | if [ $? -eq 0 ]; then
|
---|
| 499 | tmp=`hostname -f 2>/dev/null`
|
---|
| 500 | if [ $? -ne 0 ]; then
|
---|
| 501 | tmp=`hostname 2>/dev/null`
|
---|
| 502 | fi
|
---|
| 503 | else
|
---|
[19] | 504 | tmp=`hostname 2>/dev/null`
|
---|
| 505 | fi
|
---|
| 506 | if [ -z "$tmp" ]; then
|
---|
| 507 | tmp="localhost"
|
---|
| 508 | fi
|
---|
[30] | 509 | #
|
---|
| 510 | # first one is hostname, others are aliases
|
---|
| 511 | #
|
---|
| 512 | tmp2=`cat /etc/hosts | egrep "^ *[0123456789].* $tmp" | awk '{ print $2 }'`
|
---|
| 513 | if [ -z "$tmp2" ]; then
|
---|
| 514 | echo "$tmp"
|
---|
| 515 | else
|
---|
| 516 | echo "$tmp2"
|
---|
| 517 | fi
|
---|
[19] | 518 | }
|
---|
| 519 |
|
---|
| 520 | rm -f ./test_log
|
---|
| 521 |
|
---|
| 522 | # first one is hostname, others are aliases
|
---|
| 523 | #
|
---|
| 524 | hostname=`cat /etc/hosts | egrep "^ *127.0.0.1" | awk '{ print $2 }'`
|
---|
| 525 | if [ x"$hostname" = xlocalhost ]; then
|
---|
| 526 | hostname="127.0.0.1"
|
---|
| 527 | fi
|
---|
| 528 |
|
---|
[22] | 529 | # Seems that 'valgrind' causes random hangs :-(
|
---|
| 530 | #
|
---|
| 531 | if [ -z "$usevalgrind" ]; then
|
---|
| 532 | VALGRIND=
|
---|
| 533 | else
|
---|
| 534 | VALGRIND=`find_path valgrind`;
|
---|
| 535 | fi
|
---|
| 536 | [ -z "$VALGRIND" ] || {
|
---|
| 537 | VALGRIND="$VALGRIND --quiet --tool=memcheck --suppressions=.test.supp";
|
---|
| 538 | export VALGRIND;
|
---|
| 539 | [ -z "$verbose" ] || log_msg_ok "using valgrind"
|
---|
| 540 | cat > ".test.supp" <<End-of-data
|
---|
| 541 | #
|
---|
| 542 | # there are unitialized bytes in the struct...
|
---|
| 543 | #
|
---|
| 544 | {
|
---|
| 545 | pushdata_01
|
---|
| 546 | Memcheck:Param
|
---|
| 547 | write(buf)
|
---|
| 548 | obj:/lib/ld-*.so
|
---|
| 549 | fun:sh_hash_pushdata
|
---|
| 550 | fun:sh_files_filecheck
|
---|
| 551 | fun:sh_dirs_chk
|
---|
| 552 | }
|
---|
| 553 | {
|
---|
| 554 | pushdata_02
|
---|
| 555 | Memcheck:Param
|
---|
| 556 | write(buf)
|
---|
| 557 | obj:/lib/ld-*.so
|
---|
| 558 | fun:sh_hash_pushdata
|
---|
| 559 | fun:sh_files_filecheck
|
---|
| 560 | fun:sh_files_checkdir
|
---|
| 561 | }
|
---|
| 562 | {
|
---|
| 563 | pushdata_03
|
---|
| 564 | Memcheck:Param
|
---|
| 565 | write(buf)
|
---|
| 566 | obj:/lib/ld-*.so
|
---|
| 567 | fun:sh_hash_pushdata
|
---|
| 568 | fun:sh_hash_writeout
|
---|
| 569 | fun:main
|
---|
| 570 | }
|
---|
| 571 |
|
---|
| 572 | End-of-data
|
---|
| 573 | }
|
---|
| 574 |
|
---|
[1] | 575 | if test x$1 = x1; then
|
---|
[19] | 576 | . ${SCRIPTDIR}/testcompile.sh
|
---|
| 577 | testcompile
|
---|
| 578 | print_summary
|
---|
| 579 | exit $?
|
---|
[1] | 580 | fi
|
---|
| 581 | if test x$1 = x2; then
|
---|
[19] | 582 | . ${SCRIPTDIR}/testhash.sh
|
---|
| 583 | testhash
|
---|
| 584 | print_summary
|
---|
| 585 | exit $?
|
---|
[1] | 586 | fi
|
---|
| 587 | if test x$1 = x3; then
|
---|
[19] | 588 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 589 | testrun1
|
---|
| 590 | print_summary
|
---|
| 591 | exit $?
|
---|
[1] | 592 | fi
|
---|
| 593 | if test x$1 = x4; then
|
---|
[19] | 594 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 595 | . ${SCRIPTDIR}/testrun_1a.sh
|
---|
| 596 | testrun1a
|
---|
| 597 | print_summary
|
---|
| 598 | exit $?
|
---|
[1] | 599 | fi
|
---|
| 600 | if test x$1 = x5; then
|
---|
[19] | 601 | . ${SCRIPTDIR}/testext.sh
|
---|
| 602 | testext0
|
---|
| 603 | print_summary
|
---|
| 604 | exit $?
|
---|
[1] | 605 | fi
|
---|
| 606 | if test x$1 = x6; then
|
---|
[19] | 607 | . ${SCRIPTDIR}/testtimesrv.sh
|
---|
| 608 | testtime0
|
---|
| 609 | print_summary
|
---|
| 610 | exit $?
|
---|
[1] | 611 | fi
|
---|
| 612 | if test x$1 = x7; then
|
---|
[19] | 613 | . ${SCRIPTDIR}/testrun_1b.sh
|
---|
| 614 | testrun1b
|
---|
| 615 | print_summary
|
---|
| 616 | exit $?
|
---|
[1] | 617 | fi
|
---|
[22] | 618 | if test x$1 = x8; then
|
---|
| 619 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 620 | . ${SCRIPTDIR}/testrun_1c.sh
|
---|
| 621 | testrun1c
|
---|
| 622 | print_summary
|
---|
| 623 | exit $?
|
---|
| 624 | fi
|
---|
[68] | 625 | if test x$1 = x9; then
|
---|
| 626 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 627 | . ${SCRIPTDIR}/testrun_1d.sh
|
---|
| 628 | testrun1d
|
---|
| 629 | print_summary
|
---|
| 630 | exit $?
|
---|
| 631 | fi
|
---|
[1] | 632 | if test x$1 = x10; then
|
---|
[68] | 633 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 634 | . ${SCRIPTDIR}/testrun_1e.sh
|
---|
| 635 | testrun1e
|
---|
| 636 | print_summary
|
---|
| 637 | exit $?
|
---|
| 638 | fi
|
---|
[481] | 639 | if test x$1 = x11; then
|
---|
| 640 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 641 | . ${SCRIPTDIR}/testrun_1f.sh
|
---|
| 642 | testrun1f
|
---|
| 643 | print_summary
|
---|
| 644 | exit $?
|
---|
| 645 | fi
|
---|
| 646 | if test x$1 = x12; then
|
---|
| 647 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 648 | . ${SCRIPTDIR}/testrun_1g.sh
|
---|
| 649 | testrun1g
|
---|
| 650 | print_summary
|
---|
| 651 | exit $?
|
---|
| 652 | fi
|
---|
| 653 | if test x$1 = x13; then
|
---|
| 654 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 655 | . ${SCRIPTDIR}/testrun_1h.sh
|
---|
| 656 | testrun1h
|
---|
| 657 | print_summary
|
---|
| 658 | exit $?
|
---|
| 659 | fi
|
---|
[550] | 660 | if test x$1 = x14; then
|
---|
| 661 | . ${SCRIPTDIR}/testrun_1i.sh
|
---|
| 662 | testrun1i
|
---|
| 663 | print_summary
|
---|
| 664 | exit $?
|
---|
| 665 | fi
|
---|
[68] | 666 | if test x$1 = x20; then
|
---|
[19] | 667 | . ${SCRIPTDIR}/testrun_2.sh
|
---|
| 668 | testrun2 $hostname
|
---|
| 669 | print_summary
|
---|
| 670 | exit $?
|
---|
[1] | 671 | fi
|
---|
[68] | 672 | if test x$1 = x21; then
|
---|
[19] | 673 | . ${SCRIPTDIR}/testrun_2a.sh
|
---|
| 674 | testrun2a $hostname
|
---|
| 675 | print_summary
|
---|
| 676 | exit $?
|
---|
[1] | 677 | fi
|
---|
[68] | 678 | if test x$1 = x22; then
|
---|
[19] | 679 | . ${SCRIPTDIR}/testrun_2a.sh
|
---|
| 680 | . ${SCRIPTDIR}/testrun_2b.sh
|
---|
| 681 | testrun2b $hostname
|
---|
| 682 | print_summary
|
---|
| 683 | exit $?
|
---|
[1] | 684 | fi
|
---|
[68] | 685 | if test x$1 = x23; then
|
---|
[19] | 686 | . ${SCRIPTDIR}/testrun_2a.sh
|
---|
| 687 | . ${SCRIPTDIR}/testrun_2c.sh
|
---|
| 688 | testrun2c $hostname
|
---|
| 689 | print_summary
|
---|
| 690 | exit $?
|
---|
[1] | 691 | fi
|
---|
[68] | 692 | if test x$1 = x24; then
|
---|
[19] | 693 | . ${SCRIPTDIR}/testrun_2a.sh
|
---|
| 694 | . ${SCRIPTDIR}/testrun_2d.sh
|
---|
| 695 | testrun2d $hostname
|
---|
| 696 | print_summary
|
---|
| 697 | exit $?
|
---|
[1] | 698 | fi
|
---|
[481] | 699 | if test x$1 = x25; then
|
---|
| 700 | . ${SCRIPTDIR}/testrun_2e.sh
|
---|
| 701 | testrun2e $hostname
|
---|
| 702 | print_summary
|
---|
| 703 | exit $?
|
---|
| 704 | fi
|
---|
| 705 | if test x$1 = x26; then
|
---|
| 706 | . ${SCRIPTDIR}/testrun_2f.sh
|
---|
| 707 | testrun2f $hostname
|
---|
| 708 | print_summary
|
---|
| 709 | exit $?
|
---|
| 710 | fi
|
---|
| 711 | if test x$1 = x27; then
|
---|
| 712 | . ${SCRIPTDIR}/testrun_2g.sh
|
---|
| 713 | testrun2g $hostname
|
---|
| 714 | print_summary
|
---|
| 715 | exit $?
|
---|
| 716 | fi
|
---|
[1] | 717 | if test x$1 = xall; then
|
---|
[19] | 718 | TEST_MAX=0
|
---|
| 719 | . ${SCRIPTDIR}/testcompile.sh
|
---|
| 720 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 721 | . ${SCRIPTDIR}/testhash.sh
|
---|
| 722 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 723 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 724 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 725 | . ${SCRIPTDIR}/testrun_1a.sh
|
---|
| 726 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 727 | . ${SCRIPTDIR}/testext.sh
|
---|
| 728 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 729 | . ${SCRIPTDIR}/testtimesrv.sh
|
---|
| 730 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 731 | . ${SCRIPTDIR}/testrun_1b.sh
|
---|
| 732 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
[22] | 733 | . ${SCRIPTDIR}/testrun_1c.sh
|
---|
| 734 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
[68] | 735 | . ${SCRIPTDIR}/testrun_1d.sh
|
---|
| 736 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 737 | . ${SCRIPTDIR}/testrun_1e.sh
|
---|
| 738 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
[481] | 739 | . ${SCRIPTDIR}/testrun_1f.sh
|
---|
| 740 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 741 | . ${SCRIPTDIR}/testrun_1g.sh
|
---|
| 742 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 743 | . ${SCRIPTDIR}/testrun_1h.sh
|
---|
| 744 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
[550] | 745 | . ${SCRIPTDIR}/testrun_1i.sh
|
---|
| 746 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
[19] | 747 | . ${SCRIPTDIR}/testrun_2.sh
|
---|
| 748 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 749 | . ${SCRIPTDIR}/testrun_2a.sh
|
---|
| 750 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 751 | . ${SCRIPTDIR}/testrun_2b.sh
|
---|
| 752 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 753 | . ${SCRIPTDIR}/testrun_2c.sh
|
---|
| 754 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 755 | . ${SCRIPTDIR}/testrun_2d.sh
|
---|
| 756 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
[481] | 757 | . ${SCRIPTDIR}/testrun_2e.sh
|
---|
| 758 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 759 | . ${SCRIPTDIR}/testrun_2f.sh
|
---|
| 760 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
| 761 | . ${SCRIPTDIR}/testrun_2g.sh
|
---|
| 762 | let "TEST_MAX = TEST_MAX + MAXTEST" >/dev/null
|
---|
[19] | 763 | #
|
---|
| 764 | # ${SCRIPTDIR}/testtimesrv.sh
|
---|
| 765 | # ${SCRIPTDIR}/testrun_1b.sh
|
---|
| 766 | # ${SCRIPTDIR}/testrun_2.sh $2
|
---|
| 767 | # ${SCRIPTDIR}/testrun_2a.sh $2
|
---|
| 768 | #
|
---|
| 769 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 770 | testcompile
|
---|
| 771 | testhash
|
---|
| 772 | #
|
---|
| 773 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 774 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 775 | testrun1
|
---|
| 776 | #
|
---|
| 777 | . ${SCRIPTDIR}/testrun_1a.sh
|
---|
| 778 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 779 | testrun1a
|
---|
| 780 | #
|
---|
| 781 | testext0
|
---|
| 782 | #
|
---|
| 783 | . ${SCRIPTDIR}/testtimesrv.sh
|
---|
| 784 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 785 | testtime0
|
---|
| 786 | #
|
---|
| 787 | . ${SCRIPTDIR}/testrun_1b.sh
|
---|
| 788 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 789 | testrun1b
|
---|
| 790 | #
|
---|
[22] | 791 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 792 | . ${SCRIPTDIR}/testrun_1c.sh
|
---|
| 793 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 794 | testrun1c
|
---|
| 795 | #
|
---|
[68] | 796 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 797 | . ${SCRIPTDIR}/testrun_1d.sh
|
---|
| 798 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 799 | testrun1d
|
---|
| 800 | #
|
---|
| 801 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 802 | . ${SCRIPTDIR}/testrun_1e.sh
|
---|
| 803 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 804 | testrun1e
|
---|
| 805 | #
|
---|
[481] | 806 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 807 | . ${SCRIPTDIR}/testrun_1f.sh
|
---|
| 808 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 809 | testrun1f
|
---|
| 810 | #
|
---|
| 811 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 812 | . ${SCRIPTDIR}/testrun_1g.sh
|
---|
| 813 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 814 | testrun1g
|
---|
| 815 | #
|
---|
| 816 | . ${SCRIPTDIR}/testrun_1.sh
|
---|
| 817 | . ${SCRIPTDIR}/testrun_1h.sh
|
---|
| 818 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 819 | testrun1h
|
---|
| 820 | #
|
---|
[550] | 821 | . ${SCRIPTDIR}/testrun_1i.sh
|
---|
| 822 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 823 | testrun1i
|
---|
| 824 | #
|
---|
[19] | 825 | . ${SCRIPTDIR}/testrun_2.sh
|
---|
| 826 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 827 | testrun2 $hostname
|
---|
| 828 | #
|
---|
| 829 | . ${SCRIPTDIR}/testrun_2a.sh
|
---|
| 830 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 831 | testrun2a $hostname
|
---|
| 832 | #
|
---|
| 833 | . ${SCRIPTDIR}/testrun_2b.sh
|
---|
| 834 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 835 | testrun2b $hostname
|
---|
| 836 | #
|
---|
| 837 | . ${SCRIPTDIR}/testrun_2c.sh
|
---|
| 838 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 839 | testrun2c $hostname
|
---|
| 840 | #
|
---|
| 841 | . ${SCRIPTDIR}/testrun_2d.sh
|
---|
| 842 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 843 | testrun2d $hostname
|
---|
| 844 | #
|
---|
[481] | 845 | . ${SCRIPTDIR}/testrun_2e.sh
|
---|
| 846 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 847 | testrun2e $hostname
|
---|
| 848 | #
|
---|
| 849 | . ${SCRIPTDIR}/testrun_2f.sh
|
---|
| 850 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 851 | testrun2f $hostname
|
---|
| 852 | #
|
---|
| 853 | . ${SCRIPTDIR}/testrun_2g.sh
|
---|
| 854 | MAXTEST=${TEST_MAX}; export MAXTEST
|
---|
| 855 | testrun2g $hostname
|
---|
| 856 | #
|
---|
[19] | 857 | print_summary
|
---|
| 858 | exit 0
|
---|
[1] | 859 | fi
|
---|
| 860 |
|
---|
[19] | 861 | usage;
|
---|
[1] | 862 |
|
---|
[19] | 863 | exit 1;
|
---|
[1] | 864 |
|
---|
[60] | 865 | # gpg -a --clearsign --not-dash-escaped testrc.gpg
|
---|
| 866 | # gpg -a --clearsign --not-dash-escaped .samhain_file
|
---|
| 867 | # tar czvf foo.tgz testrc.gpg.asc .samhain_file.asc
|
---|
| 868 | # cat foo.tgz >>test/test.sh
|
---|
| 869 |
|
---|
[19] | 870 | __ARCHIVE_FOLLOWS__
|
---|
[481] | 871 | p{Uí=lÛFÇé©Å!sÑ-diD&%r |
---|
| 872 | #QŽÖ |
---|
| 873 | ÙQ0ÒbÍ€d+Kеk¢@75kå¡l}!KaDÔ:µC=öÐÕ |
---|
| 874 | ¥ØRA
|
---|
| 875 | 8MûÄñþw÷ã;Ùñ(Å#ÛêR 1ìÜ[2?=^º0þ@bŒ~ËÒ^ÆÇR4ãcXôåž3IÑvd |
---|
| 876 | BÊUY¯î÷ºöÿ)7]n |
---|
| 877 | bD11QBpIH&yQ6EÙÎ/Àä"ÏÉtBž&ع² |
---|
| 878 | pÍ,B¡,bL KÈRseèäUêȶe6xDZÔ{EÙ §jENkÐ0 |
---|
| 879 | h!YÓÊP3·ÉŸqG(kºi;P)Êl8î |
---|
| 880 | Ø:ÚQml¹JÔTÂî1³6²JjÙcR |
---|
| 881 | Û¯ëŠÅ. %d8Iä:ì7ÁÙ×
|
---|
| 882 | ¶@sü9!1RÉÙeC+OªgMªÞŸÔQ |
---|
| 883 | ÓBi Iýb±Šõç5Û-ã\ |
---|
| 884 | MÇ}.TËæT#g+÷c4l`g6Á¬jgxŒÏ
|
---|
| 885 | Ñ |
---|
| 886 | e[Óbz±p£9ÀÆjg6AHFºiànxVÇõ+Gª#ñÒ®@¢e«ŠÅ4QÓ, |
---|
| 887 | ;±4H i9ᢊ
|
---|
| 888 | |
---|
| 889 | |
---|
| 890 | ># èÚ±z
|
---|
| 891 | §+nhÔÝÁåð&SN0ZIŒ8Œ«h8ÛÂZb<^~$J+³QÕ(î| |
---|
| 892 | Ý
|
---|
| 893 | ëvzYüÖËüô¢w;ÁÖü§tÂ|:}OºãÒŽ^_âJÅto ,ÑR"ž÷(
|
---|
| 894 | € £«|# |
---|
| 895 | àr"zè
|
---|
| 896 | Š¹÷_ÿþÇõ<Nm¹ÿÇ%]ÃüÏŸ:ÿ³¬ÿ,ÿ3vó?KûIþŒüÿëo?õc¢ |
---|
| 897 | `Þ{Òïñ;C]ÁeTÿª^^qËçNãTÆpëPÃÃÓÆ7]= |
---|
| 898 | <ûkPqjï
|
---|
| 899 | Á£?Ô/O |
---|
| 900 | PÔãӧà&š|9=¬üþðÉêÆÌš |
---|
| 901 | üöþ0k!ÏDù/ÂúqªúMeð¬2šžÕît·[ýÝf³ßkµúµn£Õì4v[ûÝ~³ÛÚoWö:m¬7÷zZ
|
---|
| 902 | ¿zõ"¬ |
---|
| 903 | Œ&žñ墣úw_Snùhÿ8uiÁõ«ûµN£±Ûk÷;j»ßݯï |
---|
| 904 | tkœfµW7v»Õ^§^ëvêõÇ»œNïåàNÏzäÆ÷·Ÿ-5OA_ |
---|
| 905 | óÚj¿çÊVüâæ(¯ ¢Éó$Ûﮢì
|
---|
| 906 | » |
---|
| 907 | ž^HM |
---|
| 908 | øb[Œy'ñ
|
---|
| 909 | ëhIæŒëw5o2 |
---|
| 910 | ÒÐb!f|81œ|·o
|
---|
| 911 | @ @ @ ð.ò7<Ì(
|
---|