1998-02-26 16:56:31 +00:00
|
|
|
# definitions for the check scripts
|
|
|
|
|
|
|
|
#--------------------------------
|
|
|
|
#------ constants ---------------
|
|
|
|
#--------------------------------
|
|
|
|
|
|
|
|
# Note that usrpass1 is also used in Makefile.am
|
|
|
|
usrname1="one"
|
|
|
|
usrpass1="def"
|
|
|
|
usrname2="two"
|
|
|
|
usrpass2=""
|
1998-04-30 14:06:01 +00:00
|
|
|
usrname3="three"
|
|
|
|
usrpass3="abc"
|
1998-04-08 19:42:07 +00:00
|
|
|
|
|
|
|
|
|
|
|
dsa_usrname1="pgp5"
|
|
|
|
# we use the sub key because we do not yet have the logic to
|
|
|
|
# to derive the first encryption key from a keyblock (I guess)
|
|
|
|
dsa_usrname2="0xCB879DE9"
|
|
|
|
|
|
|
|
dsa_keyrings="--keyring ./pubring.pkr --secret-keyring ./secring.skr"
|
|
|
|
|
|
|
|
|
1998-07-08 09:29:43 +00:00
|
|
|
plain_files="plain-1 plain-2 plain-3"
|
1998-07-14 17:10:28 +00:00
|
|
|
data_files="data-500 data-9000 data-32000 data-80000"
|
1998-02-26 16:56:31 +00:00
|
|
|
exp_files=""
|
|
|
|
|
1999-05-19 14:12:26 +00:00
|
|
|
# The testscripts expect the original language
|
|
|
|
LANG=
|
|
|
|
LANGUAGE=
|
1999-08-31 15:30:12 +00:00
|
|
|
LC_ALL=
|
2000-07-28 16:19:07 +00:00
|
|
|
LC_MESSAGES=
|
1998-02-26 16:56:31 +00:00
|
|
|
|
|
|
|
#--------------------------------
|
|
|
|
#------ utility functions -------
|
|
|
|
#--------------------------------
|
|
|
|
|
|
|
|
fatal () {
|
|
|
|
echo "$pgmname: fatal:" $* >&2
|
|
|
|
exit 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
error () {
|
|
|
|
echo "$pgmname:" $* >&2
|
|
|
|
exit 1
|
|
|
|
}
|
|
|
|
|
|
|
|
info () {
|
|
|
|
echo "$pgmname:" $* >&2
|
|
|
|
}
|
|
|
|
|
|
|
|
chdir () {
|
|
|
|
cd $1 || fatal "cannot cd to $1"
|
|
|
|
}
|
|
|
|
|
1999-08-04 08:45:27 +00:00
|
|
|
echo_n_init=no
|
|
|
|
echo_n () {
|
|
|
|
if test "$echo_n_init" = "no"; then
|
|
|
|
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
|
|
|
|
if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
|
|
|
|
echo_n_n=
|
|
|
|
echo_n_c='
|
|
|
|
'
|
|
|
|
else
|
|
|
|
echo_n_n='-n'
|
|
|
|
echo_n_c=
|
|
|
|
fi
|
|
|
|
else
|
|
|
|
echo_n_n=
|
|
|
|
echo_n_c='\c'
|
|
|
|
fi
|
|
|
|
echo_n_init=yes
|
|
|
|
fi
|
|
|
|
echo $echo_n_n "${1}$echo_n_c"
|
|
|
|
}
|
|
|
|
|
|
|
|
|
1998-02-26 16:56:31 +00:00
|
|
|
#cleanup () {
|
|
|
|
# rm $cleanup_files 2>/dev/null || true
|
|
|
|
# echo "#empty" >./options
|
|
|
|
#}
|
|
|
|
|
|
|
|
|
|
|
|
#add_cleanup () {
|
|
|
|
# cleanup_files="$cleanup_files $*"
|
|
|
|
#}
|
|
|
|
|
|
|
|
|
1998-10-25 19:00:01 +00:00
|
|
|
have_hash_algo () {
|
1999-05-06 12:26:10 +00:00
|
|
|
if ../g10/gpg --homedir . --version | grep "Hash:.*$1" >/dev/null
|
1998-11-25 11:55:58 +00:00
|
|
|
then
|
|
|
|
true
|
|
|
|
else
|
|
|
|
false
|
|
|
|
fi
|
1998-10-25 19:00:01 +00:00
|
|
|
}
|
|
|
|
|
1998-02-26 16:56:31 +00:00
|
|
|
set -e
|
1998-07-29 19:35:05 +00:00
|
|
|
pgmname=`basename $0`
|
1998-02-26 16:56:31 +00:00
|
|
|
#trap cleanup SIGHUP SIGINT SIGQUIT
|
|
|
|
|
1998-07-29 19:35:05 +00:00
|
|
|
[ -z "$srcdir" ] && fatal "not called from make"
|
1998-02-26 16:56:31 +00:00
|
|
|
|
|
|
|
cat <<EOF >./options
|
|
|
|
no-greeting
|
|
|
|
no-secmem-warning
|
1998-06-25 10:19:08 +00:00
|
|
|
load-extension ../cipher/tiger
|
1998-02-26 16:56:31 +00:00
|
|
|
batch
|
2000-07-28 16:19:07 +00:00
|
|
|
emulate-md-encode-bug
|
1998-02-26 16:56:31 +00:00
|
|
|
EOF
|
|
|
|
|