mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-22 10:19:57 +01:00
support more hash algorithms to support the v2 card
This commit is contained in:
parent
5474061365
commit
b8d2740923
@ -1,3 +1,9 @@
|
||||
2010-07-24 Werner Koch <wk@g10code.com>
|
||||
|
||||
* cardglue.c (agent_scd_pksign): Allow more hash algorithms when
|
||||
using with scdaemon.
|
||||
* cardglue.h (GCRY_MD_MD5): New.
|
||||
|
||||
2010-06-18 Werner Koch <wk@g10code.com>
|
||||
|
||||
* parse-packet.c (skip_packet, parse_gpg_control): Take care of
|
||||
|
@ -1323,7 +1323,13 @@ agent_scd_pksign (const char *serialno, int hashalgo,
|
||||
{
|
||||
init_membuf (&data, 1024);
|
||||
snprintf (line, DIM(line)-1, "SCD PKSIGN %s%s",
|
||||
hashalgo == GCRY_MD_RMD160? "--hash=rmd160 ": "",
|
||||
hashalgo == GCRY_MD_SHA1? "--hash=sha1 ":
|
||||
hashalgo == GCRY_MD_SHA224? "--hash=sha224 ":
|
||||
hashalgo == GCRY_MD_SHA256? "--hash=sha256 ":
|
||||
hashalgo == GCRY_MD_SHA384? "--hash=sha384 ":
|
||||
hashalgo == GCRY_MD_SHA512? "--hash=sha512 ":
|
||||
hashalgo == GCRY_MD_RMD160? "--hash=rmd160 ":
|
||||
hashalgo == GCRY_MD_MD5? "--hash=md5 " : "",
|
||||
serialno);
|
||||
line[DIM(line)-1] = 0;
|
||||
rc = test_transact (assuan_transact (app->assuan_ctx, line,
|
||||
|
@ -181,6 +181,7 @@ void log_printhex (const char *text, const void *buffer, size_t length);
|
||||
#define GCRY_MD_SHA384 DIGEST_ALGO_SHA384
|
||||
#define GCRY_MD_SHA512 DIGEST_ALGO_SHA512
|
||||
#define GCRY_MD_SHA224 DIGEST_ALGO_SHA224
|
||||
#define GCRY_MD_MD5 DIGEST_ALGO_MD5
|
||||
|
||||
void gcry_mpi_release (MPI a);
|
||||
MPI gcry_mpi_set_opaque (MPI a, void *p, unsigned int len);
|
||||
|
Loading…
x
Reference in New Issue
Block a user