1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-06-09 23:39:51 +02:00
Commit Graph

1512 Commits

Author SHA1 Message Date
David Shaw
2f3c2f4870 * argparse.c (default_strusage): Update copyright date. (initialize):
Avoid a number of -Wformat-nonliteral warnings. These aren't actual
problems, but the warnings bothered me.

* miscutil.c (print_string2): New variation on print_string that allows
two delimiters. (print_string): Call print_string2 to do work.
2004-01-16 05:16:42 +00:00
David Shaw
7bd05d176b * util.h: Add prototype for print_string2(). 2004-01-16 05:14:50 +00:00
Werner Koch
ef3f2d81a1 (send_key): Add a content type. 2004-01-13 11:07:25 +00:00
Werner Koch
2d14620b2e * configure.ac: Use -Wformat-nonliteral in maintainer-mode. 2004-01-13 10:57:46 +00:00
David Shaw
580faa8675 * gpgkeys_hkp.c (search_key): Catch a mangled input file (useful if
something other than GnuPG is calling the program). (main): Avoid possible
pre-string write.  Noted by Christian Biere.

* gpgkeys_ldap.c (main): Avoid possible pre-string write.
2004-01-12 04:09:37 +00:00
David Shaw
f7bcce823f * configure.ac: Include stdio.h when checking for bzlib.h. Solaris 9 has a
very old bzip2 library and we can at least guarantee that it won't fail
because of the lack of stdio.h.

* THANKS: Added Phong Nguyen, who found the Elgamal signing key problem.
2004-01-12 03:59:29 +00:00
David Shaw
967a61cdb8 * convert-from-106, lspgpot: Check for gpg binary before proceeding.
Don't hardcode the path to gpg.

* gpgsplit.c (handle_bzip2): Remove two cut and paste typecast errors.
Noted by Stefan Bellon.
2004-01-12 02:48:42 +00:00
David Shaw
666c582e36 * config.links: OpenBSD 3.4 is now ELF, so use the proper assembler code
for that.  Use the portable C MPI code for OpenBSD before 3.4, and remove
the special i386-openbsd assembly directory.

* Makefile.am: Add the portable C links to DISTCLEANFILES.  Noted by
Nelson H. F. Beebe.

* mpi-mpow.c (build_index): s/index/idx/ to avoid gcc warning. From Werner
on stable branch.

* longlong.h: Added PowerPC 64 bit code from GPM-4.1.2 but didn't enable
it yet.  From Werner on stable branch.
2004-01-12 00:51:39 +00:00
David Shaw
5a57e36003 Use the portable C MPI code for OpenBSD before 3.4, and remove the special
i386-openbsd assembly directory.
2004-01-12 00:48:28 +00:00
David Shaw
d38c4b20a5 * gpg.sgml: Fix a few minor typos. Clarify what --textmode is useful for.
* gpg.sgml: List proper documentation URL.  Note that addrevoker takes an
optional "sensitive" argument.  Remind that $GNUPGHOME can be used instead
of --homedir.  Clarify --no-default-keyring, and note why it may not take
effect if there are no other keyrings present.  Remove --pgp2 from the
list of --pgpXes that are just for bad preference lists.  Explain more why
locking memory pages is good.

* gpg.sgml: Add an example of what an exclamation mark is, as people seem
to miss it often.
2004-01-08 05:49:39 +00:00
Stefan Bellon
ed3f4dad7a Only use ZLib module on RISC OS when configured 2004-01-03 17:13:59 +00:00
David Shaw
e7abe7e909 * clearsig.test, conventional-mdc.test, conventional.test, defs.inc,
encrypt-dsa.test, encrypt.test, genkey1024.test, plain-1.asc,
plain-1-pgp.asc, plain-2.asc, plain-3.asc, pubring.asc, secring.asc,
sigs.test: Rework tests to work properly with a gpg binary that doesn't
have all ciphers and all pk algos. Basically, we test for the ciphers we
have, only test signing with non-160-bit hashes with RSA (we test all
hashes as hashes).  Test all key lengths of AES.
2003-12-31 19:00:35 +00:00
David Shaw
2a785147be * options.h, g10.c (main), import.c (parse_import_options, import_one,
import_secret_one), keyserver.c (keyserver_refresh): Change --merge-only
to --import-option merge-only.  Deprecate --merge-only.
2003-12-31 04:58:52 +00:00
David Shaw
1228a48ab9 * g10m.c: Dead code. Remove.
* Makefile.am: Don't compile g10m.c.
2003-12-30 04:29:07 +00:00
David Shaw
8f7b94789c * idea-stub.c (load_module, idea_get_info): Return the proper type for
idea_get_info from inside load_module.  From Stefan Bellon.
2003-12-30 01:37:52 +00:00
David Shaw
d7a28c72a8 * rijndael.c, rndunix.c, twofish.c: Remove dead IS_MODULE code.
* g10c.c: Dead code.  Remove.

* Makefile.am: Don't compile g10c.c.
2003-12-30 00:57:05 +00:00
David Shaw
330f042fa4 * g10u.c: Dead code. Remove.
* Makefile.am: Don't compile g10u.c.

* iobuf.c (block_filter): Properly handle a partial body stream that ends
with a 5-byte length.
2003-12-30 00:50:32 +00:00
David Shaw
d537d547ce * misc.c (pull_in_libs): Dead code. Removed.
* sig-check.c (check_revocation_keys): Comments.

* getkey.c (merge_selfsigs_main): Don't bother to check designated revoker
sigs if the key is already revoked.

* packet.h, getkey.c (merge_selfsigs_main): New "maybe_revoked" flag on
PKs.  It is set when there is a revocation signature from a valid
revocation key, but the revocation key is not present to verify the
signature.

* pkclist.c (check_signatures_trust): Use it here to give a warning when
showing key trust.

* compress-bz2.c: Include stdio.h.  Solaris 9 has a very old bzip2 library
and we can at least guarantee that it won't fail because of the lack of
stdio.h.

* tdbio.c: Fixed format string bugs related to the use of DB_NAME.
Reported by Florian Weimer.
2003-12-30 00:46:42 +00:00
David Shaw
f13f772a29 * gpgkeys_hkp.c (send_key, get_key, main): Work with new HTTP code that
passes the proxy in from the outside.  If the command file sends a proxy,
use it.  If it sends "http-proxy" with no arguments, use $http_proxy from
the environment.
2003-12-28 16:21:46 +00:00
David Shaw
48238805b9 * options.h, g10.c (main), keyserver.c (keyserver_opts,
parse_keyserver_uri): honor-http-proxy is no longer an option since we can
do the same thing with http-proxy with no arguments. Also remove
broken-http-proxy since it can be better handled in the HTTP helper.
2003-12-28 16:08:04 +00:00
David Shaw
a847d49133 * http.h: Pass the http proxy from outside rather than pulling it from the
evironment.
2003-12-28 15:57:06 +00:00
David Shaw
eea75c0234 * http.c (send_request, http_open_document, http_open): Pass the http
proxy from outside rather than pulling it from the evironment.
2003-12-28 15:55:53 +00:00
David Shaw
4cf0123a68 * keyserver.c (argsep): New variation on strsep that knows about optional
arguments. (parse_keyserver_options): Use it here for optional arguments.
2003-12-28 15:46:49 +00:00
Stefan Bellon
02ae08d6ef cleaned up RISC OS code and removed lots of unnecessary stuff 2003-12-28 14:12:16 +00:00
David Shaw
0f346cf8c1 * keyserver.c (strip_leading_space, get_arg): New.
(parse_keyserver_options): Use them here to allow arguments to
keyserver-options.  Since none of our options need arguments yet, just
pass them through whole to the keyserver helper.
2003-12-28 04:38:00 +00:00
David Shaw
392e6da660 * main.h, misc.c (parse_options): Add a "noisy" flag to enable and disable
the messages about which option didn't match or matched ambiguously.
Change all callers (g10.c, keyserver.c).

* main.h, import.c (import_options), export.c (export_options): Pass the
noisy flag through.
2003-12-28 03:46:43 +00:00
David Shaw
7847eae02c * build-packet.c (write_fake_data, do_secret_key), seckey-cert.c
(do_check): Use an unsigned length for mpi_get_opaque.

* options.h: It's impolite to assign -1 to an unsigned
opt.force_ownertrust.
2003-12-17 23:04:53 +00:00
David Shaw
e49672d5a3 * mpiutil.c (mpi_set_opaque, mpi_get_opaque): Make the length of an opaque
MPI unsigned.
2003-12-17 22:30:57 +00:00
David Shaw
5c09a56385 * mpi.h (gcry_mpi, mpi_get_opaque, mpi_set_opaque): Make nbits and the
length of an opaque MPI unsigned.
2003-12-17 22:28:49 +00:00
David Shaw
84401d1523 * sig-check.c (cmp_help, do_check), sign.c (do_sign): Remove old unused
code.

* keyid.c (keyid_from_sk): Make sure lowbits is initialized.
2003-12-17 19:21:41 +00:00
David Shaw
68b3e412f4 * dsa.h, dsa.c (dsa_verify), elgamal.h, elgamal.c (elg_verify), rsa.h,
rsa.c (rsa_verify), pubkey.c (dummy_verify, pubkey_verify): Remove old
unused code.
2003-12-17 19:05:23 +00:00
David Shaw
64dd0c4226 * cipher.h (pubkey_verify): Remove old unused code. 2003-12-17 19:01:22 +00:00
David Shaw
f5d4b8dc06 * sig-check.c (do_check): Move the signing algo and hash checks from
here... (signature_check2): ... to here. (check_key_signature2): ... and
here.  This is a minor optimization to avoid fetching a key (which can be
expensive, especially if it is not self-signed, and there are many key
signatures on it which need to be checked for ultimate trust) if the
signature would have failed anyway because of algorithm or hash problems.
2003-12-13 03:53:27 +00:00
David Shaw
db5ab5e730 * packet.h, build-packet.c (hash_public_key): Remove function ...
* keydb.h, keyid.c (hash_public_key, do_fingerprint_md): ... and make a
new one here that shares code with the fingerprint calculations.  This
removes some duplicated functionality, and is also around 14% faster.
(Every bit helps).

* import.c (import_one): No longer need the Elgamal import warning.

* getkey.c (get_pubkey_fast): This one is sort of obscure. get_pubkey_fast
returns the primary key when requesting a subkey, so if a user has a key
signed by a subkey (we don't do this, but used to), AND that key is not
self-signed, AND the algorithm of the subkey in question is not present in
GnuPG, AND the algorithm of the primary key that owns the subkey in
question is present in GnuPG, then we will try and verify the subkey
signature using the primary key algorithm and hit a BUG().  The fix is to
not return a hit if the keyid is not the primary.  All other users of
get_pubkey_fast already expect a primary only.
2003-12-11 01:07:42 +00:00
David Shaw
888a6c2980 * keyid.c (do_fingerprint_md): Remove the rules to hash the old v3 Elgamal
keys.  They are no longer needed.
2003-12-10 01:59:45 +00:00
David Shaw
08967eb985 * keyid.c (keyid_from_sk, keyid_from_pk, fingerprint_from_pk,
fingerprint_from_sk): Enforce the v3-is-only-RSA rule.  Anything that
isn't RSA gets a zero keyid and fingerprint.
2003-12-10 01:52:33 +00:00
David Shaw
4830eb7cae * keyid.c (do_fingerprint_md): Properly handle hashing of keys that we
don't know the structure of by using the opaque MPI.
(do_fingerprint_md_sk): We cannot calculate the fingerprint from a secret
key unless we know the structure (since we can't leave off the secret key
parts), so fail early..... (keyid_from_sk, fingerprint_from_sk): .... and
return all zeroes.
2003-12-10 01:27:55 +00:00
Werner Koch
5f8ec65801 Removed accidential added file 2003-12-09 09:19:36 +00:00
Werner Koch
4c2e0e62fc * configure.ac: Add a min_automake_version.
* README.CVS: New.
* autogen.sh: Revamped except for the --build-w32 hack.
* Makefile.am: Add README.CVS
2003-12-09 09:12:43 +00:00
David Shaw
d143a9ecc2 * gpg.sgml: Fix a few missing semicolons in & entities. Noted by
Christian Biere.  Some minor grammar fixes.  Remove the "host -l pgp.net |
grep wwwkeys" advice since the nameserver no longer all allow zone
transfers.  Replace it with a mention of hkp://subkeys.pgp.net.  Note that
BZIP2 defaults to compression level 6.
2003-12-09 05:09:37 +00:00
David Shaw
c4ecc7bce8 * gpgsplit.c (write_part): Split off decompression code. (handle_zlib):
Move it here. (handle_bzip2): Add this to handle BZIP2 compressed
messages.
2003-12-06 20:02:59 +00:00
David Shaw
acdcbd6550 * http.c (send_request): Add a Host: header for virtual hosts. 2003-12-06 18:35:32 +00:00
David Shaw
d1b08dafe3 * Makefile.am: Reenable tests now that the Elgamal signature keys are
gone.

* defs.inc, pubring.asc, secring.asc, plain-1.asc, plain-2.asc,
plain-3.asc: Remove the old v3 Elgamal keys and replace with RSA+Elgamal
and RSA s+e.
2003-12-05 13:32:48 +00:00
David Shaw
7c01f15494 * miscutil.c (answer_is_yes_no_default, answer_is_yes_no_quit): Don't use
alternate strings when not needed so we don't have to re-translate them.
Hopefully the comment will be enough to indicate multiple match strings.
2003-12-05 04:20:47 +00:00
David Shaw
10e596d6c3 * config.links: Show target in asm-syntax.h file and include targets for
K*BSD (GNU userland with BSD kernel).
2003-12-05 04:15:31 +00:00
David Shaw
32c198391e * cipher.h: Make cipher list match 2440bis-09. 2003-12-04 05:24:32 +00:00
David Shaw
b5fe8d3dd7 * pubkey.c (setup_pubkey_table): Don't allow signatures to and from
encrypt-only Elgamal keys. (pubkey_get_npkey, pubkey_get_nskey,
pubkey_get_nsig, pubkey_get_nenc, pubkey_nbits): Wrap the RSA cheats in
!USE_RSA. Add cheats for sign+encrypt Elgamal.
2003-12-04 05:17:56 +00:00
David Shaw
189dea77ea * g10.c (strusage, main): Show development version warning in --version
output. (main): Set --bzip2-compress-level to the default value at
startup.  Remove --emulate-checksum-bug noop.
2003-12-04 04:58:12 +00:00
David Shaw
ad71703ebc * options: Remove emulate-md-encode-bug. 2003-12-04 04:38:56 +00:00
David Shaw
3c40fd65d6 * options.h, g10.c (main), main.h, seskey.c (do_encode_md,
encode_md_value), sig-check.c (do_check), sign.c (do_sign): Remove
--emulate-md-encode-bug as it only applied to Elgamal signatures, which
are going away.
2003-12-04 04:34:08 +00:00