mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
gpg: Add stub function for encrypting AEAD.
* g10/cipher.c (cipher_filter): Rename to cipher_filter_cfb. * g10/cipher-aead.c: New. Right now only with a stub function. * g10/Makefile.am (gpg_sources): Add file. * g10/encrypt.c (encrypt_simple): Push either cipher_filter_cfb or cipher_filter_aead. (encrypt_crypt): Ditto. (encrypt_filter): Ditto. * g10/sign.c (sign_symencrypt_file): Ditto. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
4e2ba546cd
commit
81d71818d0
7 changed files with 95 additions and 10 deletions
|
@ -1,4 +1,4 @@
|
|||
/* cipher.c - En-/De-ciphering filter
|
||||
/* cipher.c - Enciphering filter for the old CFB mode.
|
||||
* Copyright (C) 1998-2003, 2006, 2009 Free Software Foundation, Inc.
|
||||
* Copyright (C) 1998-2003, 2006, 2009, 2017 Werner koch
|
||||
*
|
||||
|
@ -117,7 +117,8 @@ write_header (cipher_filter_context_t *cfx, iobuf_t a)
|
|||
* This filter is used to en/de-cipher data with a symmetric algorithm
|
||||
*/
|
||||
int
|
||||
cipher_filter (void *opaque, int control, iobuf_t a, byte *buf, size_t *ret_len)
|
||||
cipher_filter_cfb (void *opaque, int control,
|
||||
iobuf_t a, byte *buf, size_t *ret_len)
|
||||
{
|
||||
cipher_filter_context_t *cfx = opaque;
|
||||
size_t size = *ret_len;
|
||||
|
@ -177,7 +178,7 @@ cipher_filter (void *opaque, int control, iobuf_t a, byte *buf, size_t *ret_len)
|
|||
}
|
||||
else if (control == IOBUFCTRL_DESC)
|
||||
{
|
||||
mem2str (buf, "cipher_filter", *ret_len);
|
||||
mem2str (buf, "cipher_filter_cfb", *ret_len);
|
||||
}
|
||||
|
||||
return rc;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue