summaryrefslogtreecommitdiff
path: root/libcli
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2019-03-14 09:26:04 +0100
committerAndreas Schneider <asn@cryptomilk.org>2019-08-21 09:57:31 +0000
commit37dc63e8afab8e1f88dc8a4b77c6ef3337933eb1 (patch)
tree958dbab409dc6dc9e52377164bdadb30b9bfb93b /libcli
parent1b384f378c95f550718ac697271327442e3d09dd (diff)
downloadsamba-37dc63e8afab8e1f88dc8a4b77c6ef3337933eb1.tar.gz
libcli:smb: Add gnutls_aead_cipher_hd_t to smb2_signing_key structure
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Adapted to remove Samba AES support Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'libcli')
-rw-r--r--libcli/smb/smb2_signing.c5
-rw-r--r--libcli/smb/smb2_signing.h3
2 files changed, 8 insertions, 0 deletions
diff --git a/libcli/smb/smb2_signing.c b/libcli/smb/smb2_signing.c
index 2f9bae4ba8e..01027d55fbe 100644
--- a/libcli/smb/smb2_signing.c
+++ b/libcli/smb/smb2_signing.c
@@ -35,6 +35,11 @@ int smb2_signing_key_destructor(struct smb2_signing_key *key)
key->hmac_hnd = NULL;
}
+ if (key->cipher_hnd != NULL) {
+ gnutls_aead_cipher_deinit(key->cipher_hnd);
+ key->cipher_hnd = NULL;
+ }
+
return 0;
}
diff --git a/libcli/smb/smb2_signing.h b/libcli/smb/smb2_signing.h
index 96a002f4a0c..13fb54e4e4e 100644
--- a/libcli/smb/smb2_signing.h
+++ b/libcli/smb/smb2_signing.h
@@ -25,9 +25,12 @@ struct iovec;
/* Forward declaration of GnuTLS typedefs */
struct hmac_hd_st;
typedef struct hmac_hd_st* gnutls_hmac_hd_t;
+struct api_aead_cipher_hd_st;
+typedef struct api_aead_cipher_hd_st *gnutls_aead_cipher_hd_t;
struct smb2_signing_key {
gnutls_hmac_hd_t hmac_hnd;
+ gnutls_aead_cipher_hd_t cipher_hnd;
DATA_BLOB blob;
};