aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2017-09-15 13:01:23 -0400
committerJack Lloyd <[email protected]>2017-09-15 13:01:23 -0400
commitd111b15cc718eb7af24f928c0449f0c847953f14 (patch)
tree723f0e5f272cd538e2aecacac02804b875fa6b92 /src/tests
parent91765f9fbc3e5af1df654695168ab965a2f1e06c (diff)
parent98413554eec608b4cb67973fd22dfed3093e6a5f (diff)
Merge GH #1210 Support 96...128 bit tags in GCM
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/data/aead/gcm.vec59
1 files changed, 50 insertions, 9 deletions
diff --git a/src/tests/data/aead/gcm.vec b/src/tests/data/aead/gcm.vec
index 5d4e7b10d..6cb0b4506 100644
--- a/src/tests/data/aead/gcm.vec
+++ b/src/tests/data/aead/gcm.vec
@@ -63,7 +63,6 @@ In = 00000000000000000000000000000000000000000000000000000000000000000000000
Out = A833DCC2EC04BEF5ED9E7E7FB08D61244CD795C21FEE194E7AAF7D9BD66B324F39FFC46DB5A7B9E1D6703F95290027DE6AC274CAE11C632F16261B71CE97EEA6CBE8A82B4F55F5A8B5CE1B268A7B35D8
-
[AES-128/GCM(12)]
# Nist | Test Case 5 with 12 byte tag
Key = FEFFE9928665731C6D6A8F9467308308
@@ -80,7 +79,6 @@ AD = FEEDFACEDEADBEEFFEEDFACEDEADBEEFABADDAD2
Out = 8CE24998625615B603A033ACA13FB894BE9112A5C3A211A8BA262A3CCA7E2CA701E4A9A4FBA43C90CCDCB281D48C7C6FD62875D2ACA417034C34AEE5619CC5AEFFFE0BFA462AF43C
-
[AES-192/GCM]
# Nist | Test Case 7
Key = 000000000000000000000000000000000000000000000000
@@ -137,6 +135,7 @@ In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c9
AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
Out = 0f10f599ae14a154ed24b36e25324db8c566632ef2bbb34f8347280fc4507057fddc29df9a471f75c66541d4d4dad1c9e93a19a58e8b473fa0f062f765dcc57fcf623a24094fcca4
+
[AES-256/GCM]
# Nist | Test Case 13
Key = 0000000000000000000000000000000000000000000000000000000000000000
@@ -177,6 +176,7 @@ In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c9
AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
Out = 5a8def2f0c9e53f1f75d7853659e2a20eeb2b22aafde6419a058ab4f6f746bf40fc0c3b780f244452da3ebf1c5d82cdea2418997200ef82e44ae7e3fa44a8266ee1c8eb0c8b5d4cf5ae9f19a
+
[AES-256/GCM(12)]
# Nist | Test Case 16 with 12 byte tag
Key = feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308
@@ -192,23 +192,64 @@ In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c9
AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
Out = c3762df1ca787d32ae47c13bf19844cbaf1ae14d0b976afac52ff7d79bba9de0feb582d33934a4f0954cc2363bc73f7862ac430e64abe499f47c9b1f3a337dbf46a792c45e454913
-[AES-128/GCM(8)]
-Key = 00000000000000000000000000000000
-Nonce = 000000000000000000000000
-In =
-Out = 58E2FCCEFA7E3061
+[AES-256/GCM(13)]
+# Nist | Test Case 16 with 13 byte tag
+Key = feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308
+Nonce = cafebabefacedbaddecaf888
+In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39
+AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
+Out = 522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f66276fc6ece0f4e1768cddf8853bb
+
+# Nist | Test Case 17 with 13 byte tag
+Key = feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308
+Nonce = cafebabefacedbad
+In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39
+AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
+Out = c3762df1ca787d32ae47c13bf19844cbaf1ae14d0b976afac52ff7d79bba9de0feb582d33934a4f0954cc2363bc73f7862ac430e64abe499f47c9b1f3a337dbf46a792c45e454913fe
+
+
+[AES-256/GCM(14)]
+# Nist | Test Case 16 with 14 byte tag
+Key = feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308
+Nonce = cafebabefacedbaddecaf888
+In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39
+AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
+Out = 522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f66276fc6ece0f4e1768cddf8853bb2d
+
+# Nist | Test Case 17 with 14 byte tag
+Key = feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308
+Nonce = cafebabefacedbad
+In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39
+AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
+Out = c3762df1ca787d32ae47c13bf19844cbaf1ae14d0b976afac52ff7d79bba9de0feb582d33934a4f0954cc2363bc73f7862ac430e64abe499f47c9b1f3a337dbf46a792c45e454913fe2e
+
+
+[AES-256/GCM(15)]
+# Nist | Test Case 16 with 15 byte tag
+Key = feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308
+Nonce = cafebabefacedbaddecaf888
+In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39
+AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
+Out = 522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f66276fc6ece0f4e1768cddf8853bb2d55
+
+# Nist | Test Case 17 with 15 byte tag
+Key = feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308
+Nonce = cafebabefacedbad
+In = d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39
+AD = feedfacedeadbeeffeedfacedeadbeefabaddad2
+Out = c3762df1ca787d32ae47c13bf19844cbaf1ae14d0b976afac52ff7d79bba9de0feb582d33934a4f0954cc2363bc73f7862ac430e64abe499f47c9b1f3a337dbf46a792c45e454913fe2ea8
-# Wycheproof GCM tests
[AES-128/GCM(8)]
-# This was a 96 bit tag test, truncated since Botan GCM supports only 64/128
Key = 5b9604fe14eadba931b0ccf34843dab9
Nonce = 921d2507fa8007b7bd067d34
AD = 00112233445566778899aabbccddeeff
In = 001d0c231287c1182784554ca3a21908
Out = 49d8b9783e911913d87094d1f63cc7651e348ba07cca2cf0
+
+# Wycheproof GCM tests
[AES-128/GCM]
In = 001d0c231287c1182784554ca3a21908
Key = 5b9604fe14eadba931b0ccf34843dab9