Commit 4e8c3794 authored by Werner Koch's avatar Werner Koch

release 0.2.9

parent 5a05af2b
This diff is collapsed.
Thu Feb 26 17:09:27 1998 Werner Koch (wk@isil.d.shuttle.de)
* configure.in, acinclude.m4, intl/, po/: New macros taken
from GNOME, switched to automake 1.2f
Thu Feb 26 09:05:46 1998 Werner Koch (wk@isil.d.shuttle.de)
* configure.in (doc/Makefile): New
Thu Feb 26 07:40:47 1998 Werner Koch (wk@isil.d.shuttle.de)
* configure.in: Changed gettext stuff
Wed Feb 25 11:44:10 1998 Werner Koch (wk@isil.d.shuttle.de)
* checks/*test : restructured the directory.
Tue Feb 24 15:59:12 1998 Werner Koch (wk@isil.d.shuttle.de) Tue Feb 24 15:59:12 1998 Werner Koch (wk@isil.d.shuttle.de)
* configure.in: Changed the name of the package to GNUPG and * configure.in: Changed the name of the package to GNUPG and
......
...@@ -33,13 +33,36 @@ in any CPU directory, because there maybe no C substitute. ...@@ -33,13 +33,36 @@ in any CPU directory, because there maybe no C substitute.
Don't forget to delete "config.cache" and run "./config.status --recheck". Don't forget to delete "config.cache" and run "./config.status --recheck".
The Random Device
=================
The current version of GNUPG needs the support of a random device.
If there is no such device, it uses a very simple RNG, which does
not generate strong random numbers.
Random devices are available in Linux, FreeBSD and OpenBSD.
The device files may not exist on your system, please check this
and create them if needed.
The Linux files should look like this:
cr--r--r-- 1 root sys 1, 8 May 28 1997 /dev/random
cr--r--r-- 1 root sys 1, 9 Feb 16 08:23 /dev/urandom
You can create them with:
mknod /dev/random c 1 8
mknod /dev/random c 1 8
The FreeBSD files [from the 970202 snapshot]:
crw-r--r-- 1 root wheel 2, 3 Feb 25 16:54 /dev/random
crw-r--r-- 1 root wheel 2, 4 Feb 25 16:54 /dev/urandom
You can create them with:
mknod /dev/random c 2 3
mknod /dev/urandom c 2 4
Installation Installation
============ ============
pgp is not installed as suid:root; if you want to do it, do it manually. gpg is not installed as suid:root; if you want to do it, do it manually.
The ~/.gpg directory will be created if it does not exist. Your first The ~/.gnupg directory will be created if it does not exist. Your first
action should be to create a key pair: "gpg --gen-key". action should be to create a key pair: "gpg --gen-key".
......
## Process this file with automake to produce Makefile.in ## Process this file with automake to produce Makefile.in
SUBDIRS = intl po zlib util mpi cipher tools g10 checks SUBDIRS = intl po zlib util mpi cipher tools g10 doc checks
EXTRA_DIST = VERSION EXTRA_DIST = VERSION
......
# Makefile.in generated automatically by automake 1.2d from Makefile.am # Makefile.in generated automatically by automake 1.2f from Makefile.am
# Copyright (C) 1994, 1995, 1996, 1997 Free Software Foundation, Inc. # Copyright (C) 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation # This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it, # gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved. # with or without modifications, as long as this notice is preserved.
...@@ -72,21 +72,27 @@ G10_LOCALEDIR = @G10_LOCALEDIR@ ...@@ -72,21 +72,27 @@ G10_LOCALEDIR = @G10_LOCALEDIR@
GENCAT = @GENCAT@ GENCAT = @GENCAT@
GMOFILES = @GMOFILES@ GMOFILES = @GMOFILES@
GMSGFMT = @GMSGFMT@ GMSGFMT = @GMSGFMT@
GT_NO = @GT_NO@
GT_YES = @GT_YES@
INCLUDE_LOCALE_H = @INCLUDE_LOCALE_H@
INSTOBJEXT = @INSTOBJEXT@ INSTOBJEXT = @INSTOBJEXT@
INTLDEPS = @INTLDEPS@ INTLDEPS = @INTLDEPS@
INTLLIBS = @INTLLIBS@ INTLLIBS = @INTLLIBS@
INTLOBJS = @INTLOBJS@ INTLOBJS = @INTLOBJS@
INTLSUB = @INTLSUB@ MKINSTALLDIRS = @MKINSTALLDIRS@
MPI_EXTRA_ASM_OBJS = @MPI_EXTRA_ASM_OBJS@ MPI_EXTRA_ASM_OBJS = @MPI_EXTRA_ASM_OBJS@
MSGFMT = @MSGFMT@ MSGFMT = @MSGFMT@
PACKAGE = @PACKAGE@ PACKAGE = @PACKAGE@
POFILES = @POFILES@ POFILES = @POFILES@
POSUB = @POSUB@ POSUB = @POSUB@
RANLIB = @RANLIB@ RANLIB = @RANLIB@
USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@
USE_NLS = @USE_NLS@
VERSION = @VERSION@ VERSION = @VERSION@
ZLIBS = @ZLIBS@ ZLIBS = @ZLIBS@
l = @l@
SUBDIRS = intl po zlib util mpi cipher tools g10 checks SUBDIRS = intl po zlib util mpi cipher tools g10 doc checks
EXTRA_DIST = VERSION EXTRA_DIST = VERSION
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
mkinstalldirs = $(SHELL) $(top_srcdir)/scripts/mkinstalldirs mkinstalldirs = $(SHELL) $(top_srcdir)/scripts/mkinstalldirs
...@@ -189,8 +195,12 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) $(LI ...@@ -189,8 +195,12 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) $(LI
list='$(SUBDIRS)'; for subdir in $$list; do \ list='$(SUBDIRS)'; for subdir in $$list; do \
test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \ test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
done; \ done; \
test -z "$(ETAGS_ARGS)config.h.in$(SOURCES)$(HEADERS)$(LISP)$$tags" \ list='$(SOURCES) $(HEADERS)'; \
|| (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags config.h.in $(SOURCES) $(HEADERS) $(LISP) -o $$here/TAGS) unique=`for i in $$list; do echo $$i; done | \
awk ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
test -z "$(ETAGS_ARGS)config.h.in$$unique$(LISP)$$tags" \
|| (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags config.h.in $$unique $(LISP) -o $$here/TAGS)
mostlyclean-tags: mostlyclean-tags:
......
Noteworthy changes in version 0.2.9
-----------------------------------
* Fixed FreeBSD bug.
* Added a simple man page.
* Switched to automake1.2f and a newer gettext.
Noteworthy changes in version 0.2.8 Noteworthy changes in version 0.2.8
----------------------------------- -----------------------------------
...@@ -40,7 +49,7 @@ Noteworthy changes in version 0.2.5 ...@@ -40,7 +49,7 @@ Noteworthy changes in version 0.2.5
----------------------------------- -----------------------------------
* Added zlib for systems which don't have it. * Added zlib for systems which don't have it.
Use "./configure --with-zlib" to link with thi static version Use "./configure --with-zlib" to link with the static version.
* Generalized some more functions and rewrote the encoding of * Generalized some more functions and rewrote the encoding of
message digests into MPIs. message digests into MPIs.
......
...@@ -82,11 +82,10 @@ ...@@ -82,11 +82,10 @@
Key generation shows progress by printing different characters to Key generation shows progress by printing different characters to
stderr: stderr:
"." Miller-Rabin test failed. "." Last 10 Miller-Rabin tests failed.
"+" Miller-Rabin test succeeded. "+" Miller-Rabin test succeeded.
"!" Reloading the pool with fresh prime numbers "!" Reloading the pool with fresh prime numbers
"^" Checking a new value for the generator "^" Checking a new value for the generator
"~" Issued during generator checks
"<" Size of one factor decreased "<" Size of one factor decreased
">" Size of one factor increased ">" Size of one factor increased
...@@ -204,7 +203,7 @@ ...@@ -204,7 +203,7 @@
----------------------- -----------------------
There are several ways to specify a userID, here are some examples: There are several ways to specify a userID, here are some examples:
* Only by the short keyid (prepend a zero if it start with A..F): * Only by the short keyid (prepend a zero if it begins with A..F):
"234567C4" "234567C4"
"0F34E556E" "0F34E556E"
......
* improve iobuf by reading more than one byte at once, * improve iobuf by reading more than one byte at once,
this shoud espceially done for the buffer in the chain. this shoud espceially done for the buffer in the chain.
Change the buffering to a mbuf like scheme? Need it for PSST anyway.
* add a way to difference between errors and eof in the underflow/flush * add a way to difference between errors and eof in the underflow/flush
function of iobuf. function of iobuf.
* add checking of armor trailers * add checking of armor trailers
......
This diff is collapsed.
## Process this file with automake to create Makefile.in ## Process this file with automake to create Makefile.in
TESTS = checkit TESTS = version.test decrypt.test clearsig.test armsigs.test \
sigs.test armencrypt.test armencryptp.test \
encrypt.test encryptp.test signencrypt.test \
armsignencrypt.test armdetach.test detach.test \
armdetachm.test detachm.test genkey1024.test
TEST_FILES = pubring.asc secring.asc gnupg.asc plain-1 plain-2 plain-3o.asc \ TEST_FILES = pubring.asc secring.asc gnupg.asc plain-1 plain-2 plain-3o.asc \
plain-1.asc plain-2.asc plain-3.asc plain-1.asc plain-2.asc plain-3.asc
DATA_FILES = data-500 data-9000 data-32000 data-80000
EXTRA_DIST = $(TESTS) $(TEST_FILES) EXTRA_DIST = $(TESTS) $(TEST_FILES)
CLEANFILES = prepared.stamp x y z out err $(DATA_FILES)
check: prepared.stamp
prepared.stamp: pubring.gpg secring.gpg gnupg.sig plain-3 $(DATA_FILES)
@set -x; \
echo "def" | ../g10/gpg -v --no-operation; \
echo timestamp >./prepared.stamp
pubring.gpg: pubring.asc
../g10/gpgm --yes --dearmor -o pubring.gpg pubring.asc
secring.gpg: secring.asc
../g10/gpgm --yes --dearmor -o secring.gpg secring.asc
gnupg.sig: gnupg.asc
../g10/gpgm --yes --dearmor -o gnupg.sig gnupg.asc
plain-3: plain-3o.asc
../g10/gpgm --yes --dearmor -o plain-3 plain-3o.asc
data-500:
head -c 500 /dev/urandom >data-500
data-9000:
head -c 9000 /dev/urandom >data-9000
data-32000:
head -c 32000 /dev/urandom >data-32000
data-80000:
head -c 80000 /dev/urandom >data-80000
#!/bin/sh
. defs.inc || exit 3
#info Checking armored detached signatures
for i in $plain_files $data_files ; do
echo "$usrpass1" | run_gpg --passphrase-fd 0 -sab -o x --yes $i
run_gpg -o /dev/null --yes x <$i || error "$i: bad signature"
done
#!/bin/sh
. defs.inc || exit 3
#info Checking armored detached signatures of multiple files
i="$plain_files $data_files"
echo "$usrpass1" | run_gpg --passphrase-fd 0 -sab -o x --yes $i
cat $i | run_gpg -o /dev/null --yes x || error "$i: bad signature"
#!/bin/sh
. defs.inc || exit 3
#info Checking armored encryption
for i in $plain_files $data_files ; do
run_gpg -ea -o x --yes -r "$usrname2" $i
run_gpg -o y --yes x
cmp $i y || error "$i: mismatch"
done
#!/bin/sh
. defs.inc || exit 3
#info Checking armored encryption with a pipe
for i in $plain_files $data_files ; do
run_gpg -ea --yes -r "$usrname2" < $i | tee x | run_gpg -o y --yes
cmp $i y || error "$i: mismatch"
run_gpg --yes < x > y
cmp $i y || error "$i: mismatch"
done
#!/bin/sh
. defs.inc || exit 3
#info Checking armored signing and encryption
for i in $plain_files $data_files ; do
echo "$usrpass1" \
| run_gpg --passphrase-fd 0 -sae -o x --yes -r "$usrname2" $i
run_gpg -o y --yes x
cmp $i y || error "$i: mismatch"
done
#!/bin/sh
. defs.inc || exit 3
#info Checking armored signatures
for i in $plain_files $data_files ; do
echo "$usrpass1" | run_gpg --passphrase-fd 0 -sa -o x --yes $i
run_gpg -o y --yes x
cmp $i y || error "$i: mismatch"
done
#!/bin/bash
# Script for G10 testing
#---------------------------------------------------------
#--------------------------------
#------ constants ---------------
#--------------------------------
usrname1="one"
usrpass1="def"
usrname2="two"
usrpass2=""
plain_files="plain-1 plain-2"
data_files=""
exp_files=""
#--------------------------------
#------ 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"
}
cleanup () {
rm $data_files x y z 2>/dev/null
echo "#empty" >./options
}
run_g10 () {
if ! eval ../g10/gpg --homedir . $* ; then
echo "(../g10/gpg --homedir . $*) failed" >&2
exit 1
fi
}
run_g10maint () {
if ! eval ../g10/gpgm --homedir . $* ; then
echo "(../g10/gpgm --homedir . $*) failed" >&2
exit 1
fi
}
#--------------------------------
#-------- main program ----------
#--------------------------------
set -e
pgmname=$(basename $0)
trap cleanup SIGHUP SIGINT SIGQUIT
# some checks
for i in $plain_files plain-3o.asc ; do
[ -f $i ] || fatal "$i: missing"
done
for i in $exp_files; do
[ -f $i ] || fatal "$i: script missing"
done
# create the keyrings
cat <<EOF >./options
no-greeting
no-secmem-warning
batch
EOF
# print the G10 version
run_g10 --version
info Unpacking some material
run_g10maint --yes --dearmor -o pubring.gpg pubring.asc
run_g10maint --yes --dearmor -o secring.gpg secring.asc
run_g10maint --yes --dearmor -o gnupg.sig gnupg.asc
run_g10maint --yes --dearmor -o plain-3 plain-3o.asc
plain_files="$plain_files plain-3"
# make sure all files are created
echo "$usrpass1" | run_g10 --no-operation
info Checking decryption
for i in $plain_files ; do
echo "$usrpass1" | run_g10 --passphrase-fd 0 -o y --yes $i.asc
cmp $i y || error "$i: mismatch"
done
info Checking cleartext signatures
# There is a minor glitch, which appends a lf to the cleartext.
# I do not consider that a bug, but I have to use the head .. mimic.
# It is not clear what should happen to leading LFs, we must
# change the defintion of cleartext, so that only 1 empty line
# must follow the headers, but some specs say: any number of empty lines ..
# clean-sat removes leading LFs
# I know that this does not work for random data files (due to large lines
# or what ever) - I hope we can live with it.
for i in $plain_files; do
echo "$usrpass1" | run_g10 --passphrase-fd 0 -sat -o x --yes $i
run_g10 -o y --yes x
../tools/clean-sat < $i > z
head -c $[ $(cat y | wc -c) - 1 ] y | diff - z || error "$i: mismatch"
done
info Creating some random data files
for i in 500 9000 32000 80000; do
head -c $i /dev/urandom >data-$i
data_files="$data_files data-$i"
done
info Checking armored signatures
for i in $plain_files $data_files ; do
echo "$usrpass1" | run_g10 --passphrase-fd 0 -sa -o x --yes $i
run_g10 -o y --yes x
cmp $i y || error "$i: mismatch"
done
info Checking signatures
for i in $plain_files $data_files; do
echo "$usrpass1" | run_g10 --passphrase-fd 0 -s -o x --yes $i
run_g10 -o y --yes x
cmp $i y || error "$i: mismatch"
done
info Checking armored encryption
for i in $plain_files $data_files ; do
run_g10 -ea -o x --yes -r "$usrname2" $i
run_g10 -o y --yes x
cmp $i y || error "$i: mismatch"
done
info Checking armored encryption with a pipe
for i in $plain_files $data_files ; do
run_g10 -ea --yes -r "$usrname2" < $i | tee x \
| run_g10 -o y --yes
cmp $i y || error "$i: mismatch"
run_g10 --yes < x > y
cmp $i y || error "$i: mismatch"
done
info Checking encryption
for i in $plain_files $data_files ; do
run_g10 -e -o x --yes -r "$usrname2" $i
run_g10 -o y --yes x
cmp $i y || error "$i: mismatch"
done
info Checking encryption with a pipe
for i in $plain_files $data_files ; do
run_g10 -e --yes -r "$usrname2" < $i \
| run_g10 --yes > y
cmp $i y || error "$i: mismatch"
done
info Checking signing and encryption
for i in $plain_files $data_files ; do
echo "$usrpass1" \
| run_g10 --passphrase-fd 0 -se -o x --yes -r "$usrname2" $i
run_g10 -o y --yes x
cmp $i y || error "$i: mismatch"
done
info Checking armored signing and encryption
for i in $plain_files $data_files ; do
echo "$usrpass1" \
| run_g10 --passphrase-fd 0 -sae -o x --yes -r "$usrname2" $i
run_g10 -o y --yes x
cmp $i y || error "$i: mismatch"
done
info Checking armored detached signatures
for i in $plain_files $data_files ; do
echo "$usrpass1" | run_g10 --passphrase-fd 0 -sab -o x --yes $i
run_g10 -o /dev/null --yes x <$i || error "$i: bad signature"
done
info Checking detached signatures
for i in $plain_files $data_files ; do
echo "$usrpass1" | run_g10 --passphrase-fd 0 -sb -o x --yes $i
run_g10 -o /dev/null --yes x <$i || error "$i: bad signature"
done
info Checking detached signatures of multiple files
i="$plain_files $data_files"
echo "$usrpass1" | run_g10 --passphrase-fd 0 -sb -o x --yes $i
cat $i | run_g10 -o /dev/null --yes x || error "$i: bad signature"
info Checking armored detached signatures of multiple files
i="$plain_files $data_files"
echo "$usrpass1" | run_g10 --passphrase-fd 0 -sab -o x --yes $i
cat $i | run_g10 -o /dev/null --yes x || error "$i: bad signature"
info "All tests passed."
exit 0
#!/bin/sh
. defs.inc || exit 3
#info Checking cleartext signatures
# There is a minor glitch, which appends a lf to the cleartext.
# I do not consider that a bug, but I have to use the head .. mimic.
# It is not clear what should happen to leading LFs, we must
# change the defintion of cleartext, so that only 1 empty line
# must follow the headers, but some specs say: any number of empty lines ..
# clean-sat removes leading LFs
# I know that this does not work for random data files (due to large lines
# or what ever) - I hope we can live with it.
for i in $plain_files; do
echo "$usrpass1" | run_gpg --passphrase-fd 0 -sat -o x --yes $i
run_gpg -o y --yes x
../tools/clean-sat < $i > z
head -c $[ $(cat y | wc -c) - 1 ] y | diff - z || error "$i: mismatch"
done
#!/bin/sh
. defs.inc || exit 3
#info Checking decryption of supplied files
for i in $plain_files ; do
echo "$usrpass1" | run_gpg --passphrase-fd 0 -o y --yes $i.asc
cmp $i y || error "$i: mismatch"
done
# definitions for the check scripts
#--------------------------------
#------ constants ---------------
#--------------------------------
# Note that usrpass1 is also used in Makefile.am
usrname1="one"
usrpass1="def"
usrname2="two"
usrpass2=""
plain_files="plain-1 plain-2 plain-3"
data_files="data-500 data-9000 data-32000 data-80000"
exp_files=""
#cleanup_files="x y z"
#--------------------------------
#------ 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"
}
#cleanup () {
# rm $cleanup_files 2>/dev/null || true
# echo "#empty" >./options
#}
#add_cleanup () {
# cleanup_files="$cleanup_files $*"
#}
run_gpg () {
if ! eval ../g10/gpg --homedir . $* 2>err ; then
cat err >&2
echo "(../g10/gpg --homedir . $*) failed" >&2
exit 1
fi
grep -v 'gpg: Good signature from' err || true
}
run_gpgm () {
if ! eval ../g10/gpgm --homedir . $* ; then
echo "(../g10/gpgm --homedir . $*) failed" >&2
exit 1
fi
}
set -e
pgmname=$(basename $0)
#trap cleanup SIGHUP SIGINT SIGQUIT
[ -z $srcdir ] && fatal "not called from make"
cat <<EOF >./options
no-greeting
no-secmem-warning
batch
EOF
#!/bin/sh
. defs.inc || exit 3
#info Checking detached signatures
for i in $plain_files $data_files ; do
echo "$usrpass1" | run_gpg --passphrase-fd 0 -sb -o x --yes $i
run_gpg -o /dev/null --yes x <$i || error "$i: bad signature"
done
#!/bin/sh
. defs.inc || exit 3
#info Checking detached signatures of multiple files
i="$plain_files $data_files"
echo "$usrpass1" | run_gpg --passphrase-fd 0 -sb -o x --yes $i
cat $i | run_gpg -o /dev/null --yes x || error "$i: bad signature"
#!/bin/sh
. defs.inc || exit 3
#info Checking encryption
for i in $plain_files $data_files ; do
run_gpg -e -o x --yes -r "$usrname2" $i
run_gpg -o y --yes x
cmp $i y || error "$i: mismatch"
done
#!/bin/sh
. defs.inc || exit 3
#info Checking encryption with a pipe
for i in $plain_files $data_files ; do
run_gpg -e --yes -r "$usrname2" < $i | run_gpg --yes > y
cmp $i y || error "$i: mismatch"
done
#!/bin/sh
. defs.inc || exit 3
info "This expect script does yet work"
exit 0
expect - <<EOF
set timeout -1
match_max 100000
spawn ../g10/gpg --no-batch --quick-random --homedir . --gen-key
expect -exact "Please select the algorithm to use:\r
(1) ElGamal is the suggested one.\r
(2) DSA can only be used for signatures.\r
Your selection? (1,2) "
send -- "1\r"
expect -exact "1\r
\r \rAbout to generate a new ElGamal keypair.\r
minimum keysize is 768 bits\r