summaryrefslogtreecommitdiff
path: root/lib/includes
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2018-06-02 21:25:10 +0200
committerNikos Mavrogiannopoulos <nmav@redhat.com>2018-06-14 16:30:45 +0200
commit9a714f6047e18a30d0c2de771933e0f297f4b58f (patch)
tree908faf326e5551cf44fc27c514f565e51407d3f1 /lib/includes
parentaa54b849c102e9cc433201f849f1e8ad029a9a80 (diff)
downloadgnutls-9a714f6047e18a30d0c2de771933e0f297f4b58f.tar.gz
gnutls_aead_cipher_encryptv: introduced
This API allows encryption using a scatter input, by also taking advantage of ciphers which are optimized for such input. That is particularly useful under TLS1.3 since its encryption is based on encryption of scattered data (data+pad). Resolves #458 Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
Diffstat (limited to 'lib/includes')
-rw-r--r--lib/includes/gnutls/crypto.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/includes/gnutls/crypto.h b/lib/includes/gnutls/crypto.h
index 43dd37163b..947e25caf9 100644
--- a/lib/includes/gnutls/crypto.h
+++ b/lib/includes/gnutls/crypto.h
@@ -84,6 +84,14 @@ gnutls_aead_cipher_encrypt(gnutls_aead_cipher_hd_t handle,
const void *ptext, size_t ptext_len,
void *ctext, size_t *ctext_len);
+int
+gnutls_aead_cipher_encryptv(gnutls_aead_cipher_hd_t handle,
+ const void *nonce, size_t nonce_len,
+ const giovec_t *auth_iov, int auth_iovcnt,
+ size_t tag_size,
+ const giovec_t *iov, int iovcnt,
+ void *ctext, size_t *ctext_len);
+
void gnutls_aead_cipher_deinit(gnutls_aead_cipher_hd_t handle);
/* Hash - MAC API */