1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-10-31 20:08:43 +01:00
Commit Graph

9113 Commits

Author SHA1 Message Date
Werner Koch
c0c2c58054 Finished the bulk of changes for gnupg 1.9. This included switching
to libgcrypt functions, using shared error codes from libgpg-error,
replacing the old functions we used to have in ../util by those in
../jnlib and ../common, renaming the malloc functions and a couple of
types.  Note, that not all changes are listed below becuause they are
too similar and done at far too many places.  As of today the code
builds using the current libgcrypt from CVS but it is very unlikely
that it actually works.
2003-06-18 19:56:13 +00:00
Werner Koch
66a7843c94 * parse-packet.c (parse): Disallow old style partial length for
all key material packets to avoid possible corruption of keyrings.
2003-06-10 09:05:38 +00:00
Werner Koch
1c24b139e7 * import.c (import_keys_internal): Invalidate the cache so that
the file descriptor gets closed.  Fixes bug reported by Juan
F. Codagnone.
2003-06-08 21:35:25 +00:00
Werner Koch
5880657f5e * import.c (import_keys_internal): Invalidate the cache so that
the file descriptor gets closed.  Fixes bug reported by Juan
F. Codagnone.
2003-06-08 21:23:48 +00:00
Werner Koch
b7b07d36e8 A small step for GnuPG but a huge leap for error codes.
(Sorry, it does not build currently - I need to check it in to avoid
duplicate work.)
2003-06-05 07:14:21 +00:00
Werner Koch
bd820bad4f A small step for GnuPG but a huge leap for error codes.
(Sorry, it does not build currently - I need to check it in to avoid
duplicate work.)
2003-06-05 07:14:21 +00:00
Repo Admin
7250331472 This commit was manufactured by cvs2svn to create branch
'GNUPG-1-9-BRANCH'.
2003-06-05 07:14:21 +00:00
David Shaw
4d3fecee56 * options.skel: Use new hkp://subkeys.pgp.net as sample keyserver since
they at least handle subkeys correctly.

* options.h, g10.c (main), main.h, keylist.c (show_keyserver_url),
mainproc.c (check_sig_and_print), parse-packet.c (dump_sig_subpkt,
parse_one_sig_subpkt, can_handle_critical): Add read-only support for
preferred keyserver subpackets.  They're basically policy URLs with a
different name.  Add a verify-option "show-preferred-keyserver" to turn
them on and off (on by default, as per stable branch).

* g10.c (main): Add "--set-notation" as alias to "--notation-data" this is
to make things consistent with --set-policy-url meaning both sigs and
certs.
2003-06-05 02:06:12 +00:00
Marcus Brinkmann
a58ce94d8e Update error handling to match gpg-error in CVS. 2003-06-04 21:37:56 +00:00
David Shaw
39e6e163d4 Inadvertently left out of the 2003-06-01 checkin 2003-06-04 21:21:23 +00:00
Marcus Brinkmann
d79ea5df2b Fix small typo in comment. 2003-06-03 22:51:14 +00:00
Werner Koch
fa0832884d * scdaemon.h: Include gpg-error.h and errno.h
* card.c (map_sc_err): Use unknown for the error source.
* Makefile.am: Link with libgpg-error
2003-06-03 20:08:03 +00:00
Werner Koch
a3d4ac6f3e Make use of libgpg-error 2003-06-03 19:55:50 +00:00
Werner Koch
c3cdaeeff7 Make use of libgpg-error 2003-06-03 19:55:50 +00:00
David Shaw
7c9855aaa2 * options.h, g10.c (main), keylist.c (list_keyblock_print): Add
"show-validity" and "show-long-keyid" list-options.

* gpgv.c (get_validity, trust_value_to_string): Stubs.

* g10.c (main): Use SAFE_VERSION instead of VERSION in the
version-specific gpg.conf file so it can be overridden on RISCOS.
2003-06-03 17:47:58 +00:00
David Shaw
0afffb063f * configure.ac: Define SAFE_VERSION so that RISCOS can override it and
remove invalid chars.
2003-06-03 17:42:22 +00:00
David Shaw
27ec3d9201 * g10.c (main), keylist.c (show_policy_url, show_notation), mainproc.c
(check_sig_and_print): Emulate the old policy and notation behavior
(display by default).  Send to status-fd whether it is displayed on the
screen or not.

* g10.c (main): Since we now have some options in devel that won't work in
a stable branch gpg.conf file, try for a version-specific gpg.conf-VERSION
file before falling back to gpg.conf.

* main.h, options.h: Move various option flags to options.h.
2003-06-01 15:36:13 +00:00
David Shaw
b17358948d * mainproc.c (check_sig_and_print), main.h, keylist.c (show_policy,
show_notation): Collapse the old print_notation_data into show_policy()
and show_notation() so there is only one function to print notations and
policy URLs.

* options.h, main.h, g10.c (main), keyedit.c (print_and_check_one_sig),
keylist.c (list_one, list_keyblock_print), pkclist.c (do_edit_ownertrust),
sign.c (mk_notation_and_policy): New "list-options" and "verify-options"
commands.  These replace the existing --show-photos/--no-show-photos,
--show-notation/--no-show-notation,
--show-policy-url/--no-show-policy-url, and --show-keyring options.  The
new method is more flexible since a user can specify (for example) showing
photos during sig verification, but not in key listings.  The old options
are emulated.
2003-05-31 23:23:19 +00:00
David Shaw
ff43d07819 * main.h, misc.c (parse_options): New general option line parser. Fix the
bug in the old version that did not handle report syntax errors after a
valid entry.

* import.c (parse_import_options), export.c (parse_export_options): Call
it here instead of duplicating the code.
2003-05-31 21:52:16 +00:00
David Shaw
9390fe676b * keylist.c (list_one): Don't show the keyring filename when in
--with-colons mode.  Actually translate "Keyring" string.

* mainproc.c (proc_tree): We can't currently handle multiple signatures of
different classes or digests (we'd pretty much have to run a different
hash context for each), but if they are all the same, make an exception.
This is Debian bug #194292.

* sig-check.c (check_key_signature2): Make string translatable.

* packet.h, getkey.c (fixup_uidnode): Mark real primary uids differently
than assumed primaries.

* keyedit.c (no_primary_warning): Use the differently marked primaries
here in a new function to warn when an --edit-key command might rearrange
the self-sig dates enough to change which uid is primary. (menu_expire,
menu_set_preferences): Use no_primary_warning() here.

* Makefile.am: Use @DLLIBS@ for -ldl.
2003-05-31 04:06:06 +00:00
David Shaw
0a86b45b9d * gpgkeys_hkp.c, gpgkeys_ldap.c: #include <getopt.h> if it is available.
Also include extern references for optarg and optind since there is no
guarantee that any header file will include them.  Standards?  We don't
need no stinkin' standards

* Makefile.am: Use @GETOPT@ to pull in libiberty on those platforms that
need it.
2003-05-31 03:52:02 +00:00
David Shaw
5d3b948c8a * Makefile.am: Some cleanup, and use DLLIBS for -ldl. 2003-05-31 03:41:42 +00:00
David Shaw
4d297a7ff1 * srv.h, srv.c: Include windows.h with MINGW32. 2003-05-31 03:15:50 +00:00
David Shaw
630ed74997 * configure.ac: Put wsock32 in NETLIBS. Put zlib in ZLIBS. Put dl in
DLLIBS.  Check for getopt.h if available.  Look for getopt() in libiberty
if libc doesn't have it.  Enable GPGKEYS_HKP after AC_PROG_CC so that any
needed extension (i.e. ".exe") is defined.
2003-05-31 02:14:31 +00:00
Werner Koch
638938692c Bumbed version number after release 2003-05-27 09:32:51 +00:00
Werner Koch
41bfaa5e51 About to release 1.3.2 2003-05-27 08:38:58 +00:00
David Shaw
8388bc064b * NEWS: Document --gnupg and the deprecation of --no-openpgp and
--no-pgpX.
2003-05-26 19:56:32 +00:00
David Shaw
d61c869d75 * defs.inc (pgmname): Make sure there is a valid options file. (From wk on
stable branch)

* mds.test: Note that missing algorithms are not errors.
2003-05-26 14:14:03 +00:00
David Shaw
aca5806d4e * mk-w32-dist: Don't iconv {hu,sk,zh_TW}.po. (From wk on stable branch) 2003-05-26 13:39:38 +00:00
David Shaw
f536ccc4ac * gpg.sgml, gpgv.sgml: Small SGML fixes. (From wk on stable branch)
* gnupg-w32.reg: Use HLM for the program and make sure the entries are
created.  Suggested by danielc@analysisandsolutions.com. (From wk on
stable branch)CVS: ----------------------------------------------------------------------
2003-05-26 13:34:42 +00:00
David Shaw
ad9f6ae4b5 * getkey.c (premerge_public_with_secret): Made "no secret subkey for"
warning a verbose item and translatable. (From wk on stable branch)

* sig-check.c (check_key_signature2): Made "no subkey for subkey binding
packet" a verbose item instead of a !quiet one.  There are too many
garbled keys out in the wild. (From wk on stable branch)

* filter.h: Remove const from WHAT. (From wk on stable branch)

* progress.c (handle_progress): Store a copy of NAME. (progress_filter):
Release WHAT, make sure not to print a NULL WHAT. (From wk on stable
branch)

* openfile.c (open_sigfile): Adjust free for new progress semantics. (From
wk on stable branch)

* plaintext.c (ask_for_detached_datafile): Don't dealloc pfx->WHAT. (From
wk on stable branch)

* seckey-cert.c (do_check): Issue the RSA_OR_IDEA status when the cipher
algo is IDEA to make it easier to track down the problem. (From twoaday on
stable branch)
2003-05-26 13:21:12 +00:00
David Shaw
951f7d9eca * Makefile.am: Make use of AM_CFLAGS. (From wk on stable branch) 2003-05-26 13:15:24 +00:00
David Shaw
dd9d2ca535 * POTFILES.in: Added a couple of missing source files. Noted by Pascal
Hartig and Walter Koch. (From wk on stable branch)
2003-05-26 13:13:11 +00:00
David Shaw
3a23c4230b * armor.c, g10.c, kbnode.c, misc.c, pkclist.c, sign.c, build-packet.c,
getkey.c, keydb.c, openfile.c, plaintext.c, status.c, gpgv.c, keygen.c,
options.h, sig-check.c, tdbio.h, encode.c, mainproc.c, parse-packet.c,
signal.c, textfilter.c: Edit all preprocessor instructions to remove
whitespace before the '#'. This is not required by C89, but there are some
compilers out there that don't like it.
2003-05-24 21:50:33 +00:00
David Shaw
ea35e3b65f * bftest.c, crlf.c, mk-tdata.c, mpicalc.c, shmtest.c: Edit all
preprocessor instructions to remove whitespace before the '#'. This is not
required by C89, but there are some compilers out there that don't like
it.
2003-05-24 18:38:35 +00:00
David Shaw
29e6411a7b * bithelp.h, des.c, random.c, rndlinux.c, sha1.c, blowfish.c, elgamal.c,
rijndael.c, rndunix.c, sha256.c, cast5.c, idea-stub.c, rmd160.c, rndw32.c,
sha512.c, md5.c, rmd160test.c, rsa.c, tiger.c: Edit all preprocessor
instructions to remove whitespace before the '#'.  This is not required by
C89, but there are some compilers out there that don't like it.
2003-05-24 18:31:33 +00:00
David Shaw
e152598106 * mpicoder.c, mpi-inline.h, mpi-inv.c, mpiutil.c, mpih-div.c,
mpi-internal.h, mpi-scan.c: Edit all preprocessor instructions to remove
whitespace before the '#'.  This is not required by C89, but there are
some compilers out there that don't like it.
2003-05-24 17:54:56 +00:00
David Shaw
c84fdfbe62 * argparse.c, dotlock.c, fileutil.c, iobuf.c, miscutil.c,
simple-gettext.c, errors.c, http.c, memory.c, secmem.c, ttyio.c: Edit all
preprocessor instructions to remove whitespace before the '#'.  This is
not required by C89, but there are some compilers out there that don't
like it.
2003-05-24 16:53:14 +00:00
David Shaw
702dfdff27 * cipher.h, i18n.h, iobuf.h, memory.h, mpi.h, types.h, util.h: Edit all
preprocessor instructions to remove whitespace before the '#'.  This is
not required by C89, but there are some compilers out there that don't
like it.
2003-05-24 16:40:46 +00:00
David Shaw
e1517d95e4 * configure.ac: Edit preprocessor instructions in g10defs.h to remove
whitespace before the '#'.  This is not required by C89, but there are
some compilers out there that don't like it.
2003-05-24 14:50:02 +00:00
David Shaw
96c8bae878 * gpg.sgml: Document --trustdb-name. Document --gnupg in a new compliance
section, and remove the various --no-PGPX options. Deprecate --no-comment
in favor of --no-sk-comments.
2003-05-24 14:38:58 +00:00
David Shaw
2e821d77f7 * trustdb.h, trustdb.c (is_disabled), gpgv.c (is_disabled): Rename
is_disabled to cache_disabled_value, which now takes a pk and not just the
keyid. This is for speed since there is no need to re-fetch a key when we
already have that key handy.  Cache the result of the check so we don't
need to hit the trustdb more than once.

* getkey.c (skip_disabled): New function to get a pk and call is_disabled
on it. (key_byname): Use it here.

* packet.h, getkey.c (skip_disabled), keylist.c (print_capabilities): New
"pk_is_disabled" macro to retrieve the cached disabled value if available,
and fill it in via cache_disabled_value if not available.

* trustdb.c (get_validity): Cache the disabled value since we have it
handy and it might be useful later.

* parse-packet.c (parse_key): Clear disabled flag when parsing a new key.
Just in case someone forgets to clear the whole key.

* getkey.c (merge_selfsigs_main): Add an "if all else fails" path for
setting a single user ID primary when there are multiple set primaries all
at the same second, or no primaries set and the most recent user IDs are
at the same second, or no signed user IDs at all. This is arbitrary, but
deterministic.

* exec.h, photoid.h: Add copyright message.

* keylist.c (list_keyblock_print): Don't dump attribs for
revoked/expired/etc uids for non-colon key listings.  This is for
consistency with --show-photos.

* main.h, keylist.c (dump_attribs), mainproc.c (check_sig_and_print): Dump
attribs if --attrib-fd is set when verifying signatures.

* g10.c (main): New --gnupg option to disable the various --openpgp,
--pgpX, etc. options.  This is the same as --no-XXXX for those options.

* revoke.c (ask_revocation_reason): Clear old reason if user elects to
repeat question.  This is bug 153.

* keyedit.c (sign_uids): Show keyid of the key making the signature.
2003-05-21 16:42:22 +00:00
Werner Koch
67a6cd7168 * fileutil.c (is_file_compressed): Fixed checking for "-" filename. 2003-05-21 08:49:03 +00:00
Werner Koch
d0573d3db6 * progress.c (handle_progress)
* sign.c (write_plaintext_packet)
* encode.c (encode_simple,encode_crypt): Make sure that a filename
of "-" is considered to be stdin so that iobuf_get_filelength
won't get called.  This fixes bug 156 reported by Gregery Barton.
2003-05-21 08:48:26 +00:00
David Shaw
0048ebcbae * cipher.c (setup_cipher_table): #ifdef IDEA.
* random.c (fast_random_poll): Only use times() if we HAVE_TIMES.

* sha512.c, tiger.c: Use the U64_C() macro to specify 64-bit constants.
U64_C is defined in include/types.h and uses the correct suffix depending
on the underlying type of u64.

* idea-stub.c (load_module): Catch an error if the idea module file is
unloadable for some reason (unreadable, bad permissions, etc.)

* md.c (string_to_digest_algo): Give a warning about TIGER192 not being
part of OpenPGP.
2003-05-15 05:29:05 +00:00
David Shaw
1e6592941b * types.h: Add initializer macros for 64-bit unsigned type. 2003-05-14 04:32:32 +00:00
David Shaw
59c5b524d6 * configure.ac: Remove some stuff no longer needed with newer autoconf.
Use AC_GNU_SOURCE instead of defining _GNU_SOURCE manually.  Add check for
strchr() for gettext.  Add "ngettext" check for gettext, since that check
supposedly implies a check for bind_textdomain_codeset.  Add check for
times() for random.c.  Fix URL for EGD.  Make --enable-old-tiger match the
stable branch as a separate item.

* NEWS: "OpenPGP" trust model is now "PGP".  Add note about TIGER being
dropped from OpenPGP.  Note trust bug fix.

* README: Fix all URLs to point to the right place in the reorganized
gnupg.org web pages.  Some minor language fixes.
2003-05-11 22:00:31 +00:00
David Shaw
4b256be065 * gpg.sgml: Some general language tweaks. Note default algo for
--symmetric.  --export-ownertrust takes no args.  Document
--no-escape-from-lines.  Fix escaped "<From" to be ">From".  Make
"openpgp" trust model into "pgp".
2003-05-04 17:05:04 +00:00
David Shaw
3afe991bb8 * packet.h, build-packet.c (build_sig_subpkt), export.c
(do_export_stream), import.c (remove_bad_stuff, import), parse-packet.c
(dump_sig_subpkt, parse_one_sig_subpkt): Remove vestigal code for the old
sig cache subpacket.  This wasn't completely harmless as it caused
subpacket 101 to disappear on import and export.

* options.h, armor.c, cipher.c, g10.c, keyedit.c, pkclist.c, sign.c,
encode.c, getkey.c, revoke.c: The current flags for different levels of
PGP-ness are massively complex.  This is step one in simplifying them. No
functional change yet, just use a macro to check for compliance level.

* sign.c (sign_file): Fix bug that causes spurious compression preference
warning.

* sign.c (clearsign_file): Fix bug that prevents proper warning message
from appearing when clearsigning in --pgp2 mode with a non-v3 RSA key.

* main.h, misc.c (compliance_option_string, compliance_string,
compliance_failure), pkclist.c (build_pk_list), sign.c (sign_file,
clearsign_file), encode.c (encode_crypt, write_pubkey_enc_from_list): New
functions to put the "this message may not be usable...." warning in one
place.

* options.h, g10.c (main): Part two of the simplification.  Use a single
enum to indicate what we are compliant to (1991, 2440, PGPx, etc.)

* g10.c (main): Show errors for failure in export, send-keys, recv-keys,
and refresh-keys.

* options.h, g10.c (main): Give algorithm warnings for algorithms chosen
against the --pgpX and --openpgp rules.

* keydb.h, pkclist.c (algo_available): Make TIGER192 invalid in --openpgp
mode.

* sign.c (sign_file), pkclist.c (algo_available): Allow passing a hint of
0.
2003-05-03 04:07:45 +00:00
David Shaw
7c3aa4aea3 * cipher.h: Add constants for compression algorithms. 2003-05-03 03:21:29 +00:00