1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-07-07 03:29:21 +02:00
Commit Graph

101 Commits

Author SHA1 Message Date
David Shaw
7cf79c128a Add Camellia. Do not enable this if you are not doing interop
testing.  It is not (yet) legal OpenPGP, is not interop tested yet
(obviously), and it's a great way to lose your data.  Just don't do
it.
2007-06-13 15:28:11 +00:00
David Shaw
20af3fea15 Move some ascii_foo functions to libcompat 2007-04-16 22:32:28 +00:00
Werner Koch
9f433cccca Removed the use of g10defs.h.
This required some code cleanups and the introduction of
a few accessor ducntions in mpi.
2006-12-11 19:54:53 +00:00
Werner Koch
d8ff6704c8 Preparing a release 2006-12-06 09:52:40 +00:00
David Shaw
6f32b4e4d1 Move strsep() and ascii_isspace() to libcompat. 2006-09-28 19:53:17 +00:00
David Shaw
b17fcc5d51 Put in the basic wiring (just hextobyte for now) for a libcompat.a that
can contain replacement files that can be linked to keyserver helpers
without bringing in the whole libutil.a.  libutil.a contains a complete 
copy of libcompat.a so we only need to link to one of them.
2006-09-28 19:36:55 +00:00
David Shaw
2f94329422 The plumbing necessary to create DSA keys with variable sized q.
Not yet used (q==160).
2006-04-20 18:40:37 +00:00
David Shaw
f0902a6aef Add SHA-224 support 2006-04-20 02:05:32 +00:00
David Shaw
e0ad2bda52 * cert.c (get_cert): Handle the fixed IPGP type with fingerprint. 2006-03-16 22:40:04 +00:00
Werner Koch
966cd80d88 Fixed a wrong return code with gpg --verify 2006-02-14 10:17:57 +00:00
David Shaw
7f13d486b0 New code to do DNS CERT queries. 2005-12-23 18:15:24 +00:00
Werner Koch
a1cdf3c75f Converted all m_free to xfree etc. 2005-07-27 18:10:56 +00:00
David Shaw
b7a7551085 * http.h: Fix prototypes for http_open_document and http_open again,
to handle the new different auth for regular files and proxies.
2005-06-23 04:24:28 +00:00
David Shaw
1684bda54e * http.h: Fix prototypes for http_open_document and http_open to pass
in auth and proxyauth.
2005-06-22 04:13:41 +00:00
Werner Koch
be2aa37dbf * cardglue.c (send_status_info): Make CTRL optional.
(agent_scd_writekey, inq_writekey_parms): New.
(agent_openpgp_storekey): Removed.
* cardglue.h: Add a few more error code mappings.
* keygen.c (copy_mpi): Removed.
(save_unprotected_key_to_card): Changed to use agent_scd_writekey.
* app-common.h, app-openpgp.c, tlv.c, tlv.h: Updated from newer
version in gnupg 1.9 CVS.
2005-05-21 14:04:32 +00:00
David Shaw
ef92ff6e08 Remove add_days_to_timestamp (unused) 2005-05-05 22:21:34 +00:00
David Shaw
b4b228b4f9 * distfiles: Add assuan.h. 2005-04-22 23:52:58 +00:00
Werner Koch
80f4424658 Changes to make use of code taken from libassuan. This replaces the
old ad-hoc connection code to gpg-agent.  We do need this for the
forthcoming diversion of card code to an already running gpg-agent
with card-support.
2005-04-05 17:09:13 +00:00
David Shaw
9c3484924b * ttyio.c (tty_enable_completion, tty_disable_completion): Enable and
disable readline completion. (init_ttyfp): Completion is disabled by
default.
2005-03-18 20:17:38 +00:00
David Shaw
a3ea962679 Disable the "quick check" bytes for PK decryptions. This is in
regards to the Mister and Zuccherato attack on OpenPGP CFB mode.
2005-02-10 04:06:30 +00:00
David Shaw
e79f2db8e4 * g10.c (main): Add --require-secmem/--no-require-secmem to cause gpg to
exit if it cannot lock memory.  Also remove --nrsign-key and --nrlsign-key
since this can better be done via --edit-key.

* secmem.c (secmem_init): Return a flag to indicate whether we got the
lock.

* memory.h: Return a flag to indicate whether we got the lock.
2004-12-16 05:16:09 +00:00
David Shaw
0f8db18dc1 * cipher.h: Add PUBKEY_USAGE_UNKNOWN. 2004-11-29 21:14:18 +00:00
Timo Schulz
37ecd725e5 2004-11-03 Timo Schulz <twoaday@g10code.com>
* strgutil.c (w32_strerror): New.
        * ttyio.c (init_ttyfp, tty_printf, do_get): Use it here.
        * iobuf.c (fd_cache_open, file_filter): Likewise.
        (iobuf_seek, translate_file_handle): Likewise.
2004-11-03 20:03:46 +00:00
Werner Koch
e216c20f40 * dynload.h: Always use it for _WIN32.
* LINGUAS: Better don't have comments in this file.

* mk-w32-dist: Use utf-8 encoding for all MO files.

* simple-gettext.c: Removed windows.h.
(get_string): On the fly translation from utf-8 to active
character set.

* strgutil.c (load_libiconv) [_WIN32]: new.
(set_native_charset) [_WIN32]: Call it here and autodetect the
used code page.
(native_to_utf8, utf8_to_native): Reverted arguments for
iconv_open.
(handle_iconv_error): Made this function match iconv_open argumnet
ordering.
(utf8_to_native): Disable all quoting for DELIM == -1.
2004-10-27 16:32:51 +00:00
Werner Koch
0ebf79c824 * configure.ac: Remove the check for asprintf
* app-common.h (app_openpgp_storekey: Add prototype.

* app-openpgp.c (do_sign): Replace asprintf by direct allocation.
This avoids problems with missing vasprintf implementations.

* card-util.c (generate_card_keys): Add a #warning for gnupg 1.9
and use the same string there.

* util.h [!HAVE_VASPRINTF]: Removed prototype.

* vasprintf.c: Removed. It was used only at one place and I don't
want to get into build problems in 1.4.
2004-10-21 16:56:22 +00:00
Werner Koch
5cbeda8164 Add asprintf prototype. 2004-10-15 09:39:31 +00:00
David Shaw
ac51d6dbd4 * keyserver.h: Add KEYSERVER_TIMEOUT. 2004-10-13 18:32:17 +00:00
David Shaw
07288476ac * util.h: Prototype destroy_dotlock(). From Werner on stable branch. 2004-09-30 14:27:34 +00:00
David Shaw
f9a057a941 * http.h: Add auth field for a parsed_uri to allow for basic auth. 2004-09-10 21:17:32 +00:00
Werner Koch
06853bbc4d * README: Doc --disable-card-support and --without-readline.
* configure.ac: Check for readline.  Make enable-card-support the
default.  New option --without-readline.  Allow the use of either
the development or the stable libusb.

* cardglue.h: Add members for CA fingerprints.
* cardglue.c (agent_release_card_info): Invalid them.
(learn_status_cb): Store them.

* app-common.h, app-openpgp.c, iso7816.c, iso7816.h
* apdu.c, apdu.h, ccid-driver.c, ccid-driver.h
* card-util.c: Updated from current gnupg-1.9.

* ccid-driver.h (CCID_DRIVER_ERR_ABORTED): New.
* ccid-driver.c (ccid_open_reader): Support the stable 0.1 version
of libusb.
(ccid_get_atr): Handle short messages.
* apdu.c (my_rapdu_get_status): Implemented.
* apdu.c: Include <signal.h>.
* apdu.c (reader_table_s):  Add function pointers for the backends.
(apdu_close_reader, apdu_get_status, apdu_activate)
(send_apdu): Make use of them.
(new_reader_slot): Intialize them to NULL.
(dump_ccid_reader_status, ct_dump_reader_status): New.
(dump_pcsc_reader_status): New.
(open_ct_reader, open_pcsc_reader, open_ccid_reader)
(open_osc_reader, open_rapdu_reader): Intialize function pointers.
(ct_activate_card, ct_send_apdu, pcsc_send_apdu, osc_send_apdu)
(error_string): Removed.  Replaced by apdu_strerror.
(get_ccid_error_string): Removed.
(ct_activate_card): Remove the unused loop.
(reset_ct_reader): Implemented.
(ct_send_apdu): Activate the card if not yet done.
(pcsc_send_apdu): Ditto.
* ccid-driver.h: Add error codes.
* ccid-driver.c: Implement more or less proper error codes all
over the place.
* apdu.c (apdu_send_direct): New.
(get_ccid_error_string): Add some error code mappings.
(send_apdu): Pass error codes along for drivers already supporting
them.
(host_sw_string): New.
(get_ccid_error_string): Use above.
(send_apdu_ccid): Reset the reader if it has not yet been done.
(open_ccid_reader): Don't care if the ATR can't be read.
(apdu_activate_card): New.
(apdu_strerror): New.
(dump_reader_status): Only enable it with opt.VERBOSE.
* iso7816.c (map_sw): Add mappings for the new error codes.
* apdu.c (open_ct_reader, open_pcsc_reader, open_ccid_reader)
(reset_ccid_reader, open_osc_reader): Call dump_reader_status only
in verbose mode.
* app-openpgp.c (do_getattr): Fix for sending CA-FPR.
* app-openpgp.c (app_openpgp_readkey): Fixed check for valid
exponent.
* app-openpgp.c (do_setattr): Sync FORCE_CHV1.
* card-util.c (change_login): Kludge to allow reading data from a
file.
(card_edit): Pass ARG_STRING to change_login.
(card_status): Print CA fingerprints.
(change_cafpr): New.
(card_edit): New command CAFPR.

* errors.h (G10ERR_NO_CARD, G10ERR_CANCELED): New error codes.

* errors.c (g10_errstr): New error codes G10ERR_NO_CARD,
G10ERR_CANCELED.
2004-09-09 18:18:36 +00:00
Werner Koch
6b3a008e46 Renamed prototype parameter name to avoid gcc warnings. 2004-04-27 08:24:37 +00:00
David Shaw
f29639dae5 * iobuf.h: Remove iobuf_set_block_mode() and iobuf_in_block_mode(). 2004-03-04 20:46:56 +00:00
David Shaw
9afea90825 * util.h: Prototype for hextobyte(). 2004-02-21 22:13:39 +00:00
David Shaw
57c585bc0f * cipher.h: Remove the old CIPHER_ALGO_RINJDAEL values. is_ELGAMAL() now
only matches type 16 and not type 20.
2004-01-17 03:10:09 +00:00
David Shaw
7bd05d176b * util.h: Add prototype for print_string2(). 2004-01-16 05:14:50 +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
Stefan Bellon
02ae08d6ef cleaned up RISC OS code and removed lots of unnecessary stuff 2003-12-28 14:12:16 +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
64dd0c4226 * cipher.h (pubkey_verify): Remove old unused code. 2003-12-17 19:01:22 +00:00
David Shaw
32c198391e * cipher.h: Make cipher list match 2440bis-09. 2003-12-04 05:24:32 +00:00
David Shaw
e81943f748 * util.h: Add prototype for match_multistr(). 2003-11-21 01:03:51 +00:00
David Shaw
8d82e1af00 * cipher.h: Add COMPRESS_ALGO_BZIP2. 2003-10-31 05:07:40 +00:00
Timo Schulz
25bf32a078 2003-10-04 Timo Schulz <twoaday@freakmail.de>
* dynload [WIN32] (dlclose): Do not use CloseHandle but FreeLibrary.
2003-10-04 12:55:47 +00:00
Werner Koch
8062cb418a * keygen.c (do_add_key_flags, parse_parameter_usage): Add support
the proposed AUTH key flag.
* getkey.c (fixup_uidnode, merge_selfsigs_main)
(merge_selfsigs_subkey, premerge_public_with_secret): Ditto.
* keylist.c (print_capabilities): Ditto.

* parse-packet.c (parse_key): Allow to parse the divert-to-card
S2K mode.
* build-packet.c (do_secret_key): Handle divert-to-card S2K
* seckey-cert.c (is_secret_key_protected): Ditto.
(check_secret_key): Ditto.

* keygen.c (do_ask_passphrase): Renamed from ask_passphrase.
* passphrase.c (ask_passphrase): New.
2003-09-30 08:00:08 +00:00
Timo Schulz
4b929ff36d 2003-09-28 Timo Schulz <twoaday@freakmail.de>
* util.h [WIN32]: Prototype for asprintf.
        * dynload.h [WIN32]: Define RTLD_LAZY.
2003-09-28 17:16:03 +00:00
Werner Koch
edb5762c5f * util.h: Add the atoi_* and xtoi_* suite of macros from 1.9.
* dynload.h: New.  Taken from 1.9.
2003-09-28 13:42:18 +00:00
Werner Koch
20ed53942a First bits of a card support backport from 1.9. It is not enabled by
default and tehre is not yet much more than a new configure option.

* configure.ac (LIBUSB_LIBS,HAVE_LIBUSB): Check for Libusb.
(--enable-card-support): New.

* sign.c (do_sign) [ENABLE_CARD_SUPPORT]: Divert to card.
* cardglue.c, cardglue.h: New.
* Makefile.am (gpg_LDADD): Added.
(card_support_sources): New.

* memory.h (xmalloc): Define xmalloc macros in terms of m_alloc.
2003-09-27 19:37:53 +00:00
David Shaw
1d76c4a824 * cipher.h: Drop TIGER/192 support. 2003-09-04 12:30:01 +00:00
David Shaw
1814e2dbf3 * util.h: s/__MINGW32__/_WIN32/ to help building on native Windows
compilers.  Requested by Brian Gladman.  From Werner on stable branch.
2003-08-28 23:41:41 +00:00
David Shaw
d8a6bd3b84 * types.h: Prefer using uint64_t when creating a 64-bit unsigned type.
This avoids a warning on compilers that support but complain about
unsigned long long.

* util.h (ascii_isspace): New variation on isspace() that is immune from
locale changes.

* util.h: Make sure that only ascii is passed to isfoo functions. (From
Werner on stable branch).
2003-07-10 12:13:53 +00:00