aboutsummaryrefslogtreecommitdiffstats
path: root/epan/crypt/dot11decrypt_int.h
diff options
context:
space:
mode:
authorMikael Kanstrup <mikael.kanstrup@sony.com>2020-03-08 12:40:20 +0100
committerPeter Wu <peter@lekensteyn.nl>2020-03-14 17:53:36 +0000
commitcf4c0552e7424966fff573194bc5412d060da701 (patch)
tree9caf642e3db26cebfa78a146257b967521d8b92b /epan/crypt/dot11decrypt_int.h
parentf3a9d9abedc8d7ae9aae3d0facfbe56555b52cf2 (diff)
ieee80211: GCMP decryption support
Add support for decrypting GCMP/GCMP-256 encrypted IEEE 802.11 traffic Bug: 16197 Change-Id: I907d772665141c8be10a9f4a187bd76594c8d2e4 Reviewed-on: https://code.wireshark.org/review/36346 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Diffstat (limited to 'epan/crypt/dot11decrypt_int.h')
-rw-r--r--epan/crypt/dot11decrypt_int.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/epan/crypt/dot11decrypt_int.h b/epan/crypt/dot11decrypt_int.h
index 366a86aa2e..e582179a8a 100644
--- a/epan/crypt/dot11decrypt_int.h
+++ b/epan/crypt/dot11decrypt_int.h
@@ -15,6 +15,9 @@
#include "dot11decrypt_interop.h"
#include "dot11decrypt_system.h"
+#include "ws_attributes.h"
+#include <wsutil/wsgcrypt.h>
+
/****************************************************************************/
/****************************************************************************/
@@ -166,4 +169,38 @@ typedef struct _DOT11DECRYPT_MAC_FRAME_ADDR4_QOS {
/******************************************************************************/
+int Dot11DecryptCcmpDecrypt(
+ guint8 *m,
+ int mac_header_len,
+ int len,
+ guint8 *TK1,
+ int tk_len,
+ int mic_len);
+
+#if GCRYPT_VERSION_NUMBER >= 0x010600 /* 1.6.0 */
+int Dot11DecryptGcmpDecrypt(
+ guint8 *m,
+ int mac_header_len,
+ int len,
+ guint8 *TK1,
+ int tk_len);
+#else
+static inline int Dot11DecryptGcmpDecrypt(
+ guint8 *m _U_,
+ int mac_header_len _U_,
+ int len _U_,
+ guint8 *TK1 _U_,
+ int tk_len _U_)
+{
+ return 1;
+}
+#endif
+
+INT Dot11DecryptTkipDecrypt(
+ UCHAR *tkip_mpdu,
+ size_t mpdu_len,
+ UCHAR TA[DOT11DECRYPT_MAC_LEN],
+ UCHAR TK[DOT11DECRYPT_TK_LEN])
+ ;
+
#endif