diff options
author | Werner Koch <wk@gnupg.org> | 2013-07-17 15:54:32 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2013-07-17 15:54:32 +0200 |
commit | 5940e66cbefea3de5924f494f18aed69bb694bff (patch) | |
tree | 054fe254b2bd012281e57d594455754c5309c91c /cipher/pubkey.c | |
parent | 6e1adb05d290aeeb1c230c763970695f4a538526 (diff) | |
download | libgcrypt-5940e66cbefea3de5924f494f18aed69bb694bff.tar.gz |
cipher: Prepare to pass extra info to the sign functions.
* src/gcrypt-module.h (gcry_pk_sign_t): Add parms flags and hashalgo.
* cipher/rsa.c (rsa_sign): Add parms and mark them as unused.
* cipher/dsa.c (dsa_sign): Ditto.
* cipher/elgamal.c (elg_sign): Ditto.
* cipher/pubkey.c (dummy_sign): Ditto.
(pubkey_sign): Pass 0 for the new args.
Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'cipher/pubkey.c')
-rw-r--r-- | cipher/pubkey.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/cipher/pubkey.c b/cipher/pubkey.c index 378e0724..23a43589 100644 --- a/cipher/pubkey.c +++ b/cipher/pubkey.c @@ -161,12 +161,16 @@ dummy_decrypt (int algorithm, gcry_mpi_t *result, gcry_mpi_t *data, static gcry_err_code_t dummy_sign (int algorithm, gcry_mpi_t *resarr, gcry_mpi_t data, - gcry_mpi_t *skey) + gcry_mpi_t *skey, + int flags, int hashalgo) + { (void)algorithm; (void)resarr; (void)data; (void)skey; + (void)flags; + (void)hashalgo; fips_signal_error ("using dummy public key function"); return GPG_ERR_NOT_IMPLEMENTED; } @@ -728,7 +732,7 @@ pubkey_sign (int algorithm, gcry_mpi_t *resarr, gcry_mpi_t data, if (module) { pubkey = (gcry_pk_spec_t *) module->spec; - rc = pubkey->sign (algorithm, resarr, data, skey); + rc = pubkey->sign (algorithm, resarr, data, skey, 0, 0); _gcry_module_release (module); goto ready; } |