forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
crypto: rfc4106 - Extending the RC4106 AES-GCM test vectors
Updated RFC4106 AES-GCM testing. Some test vectors were taken from http://csrc.nist.gov/groups/ST/toolkit/BCM/documents/proposedmodes/ gcm/gcm-test-vectors.tar.gz Signed-off-by: Adrian Hoban <[email protected]> Signed-off-by: Tadeusz Struk <[email protected]> Signed-off-by: Gabriele Paoloni <[email protected]> Signed-off-by: Aidan O'Mahony <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
- Loading branch information
1 parent
0bd82f5
commit 69435b9
Showing
3 changed files
with
396 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,6 +8,13 @@ | |
* Copyright (c) 2002 Jean-Francois Dive <[email protected]> | ||
* Copyright (c) 2007 Nokia Siemens Networks | ||
* | ||
* Updated RFC4106 AES-GCM testing. | ||
* Authors: Aidan O'Mahony ([email protected]) | ||
* Adrian Hoban <[email protected]> | ||
* Gabriele Paoloni <[email protected]> | ||
* Tadeusz Struk ([email protected]) | ||
* Copyright (c) 2010, Intel Corporation. | ||
* | ||
* This program is free software; you can redistribute it and/or modify it | ||
* under the terms of the GNU General Public License as published by the Free | ||
* Software Foundation; either version 2 of the License, or (at your option) | ||
|
@@ -980,6 +987,10 @@ static int do_test(int m) | |
ret += tcrypt_test("ansi_cprng"); | ||
break; | ||
|
||
case 151: | ||
ret += tcrypt_test("rfc4106(gcm(aes))"); | ||
break; | ||
|
||
case 200: | ||
test_cipher_speed("ecb(aes)", ENCRYPT, sec, NULL, 0, | ||
speed_template_16_24_32); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,13 @@ | |
* Copyright (c) 2007 Nokia Siemens Networks | ||
* Copyright (c) 2008 Herbert Xu <[email protected]> | ||
* | ||
* Updated RFC4106 AES-GCM testing. | ||
* Authors: Aidan O'Mahony ([email protected]) | ||
* Adrian Hoban <[email protected]> | ||
* Gabriele Paoloni <[email protected]> | ||
* Tadeusz Struk ([email protected]) | ||
* Copyright (c) 2010, Intel Corporation. | ||
* | ||
* This program is free software; you can redistribute it and/or modify it | ||
* under the terms of the GNU General Public License as published by the Free | ||
* Software Foundation; either version 2 of the License, or (at your option) | ||
|
@@ -2242,6 +2249,23 @@ static const struct alg_test_desc alg_test_descs[] = { | |
} | ||
} | ||
}, { | ||
.alg = "rfc4106(gcm(aes))", | ||
.test = alg_test_aead, | ||
.suite = { | ||
.aead = { | ||
.enc = { | ||
.vecs = aes_gcm_rfc4106_enc_tv_template, | ||
.count = AES_GCM_4106_ENC_TEST_VECTORS | ||
}, | ||
.dec = { | ||
.vecs = aes_gcm_rfc4106_dec_tv_template, | ||
.count = AES_GCM_4106_DEC_TEST_VECTORS | ||
} | ||
} | ||
} | ||
}, { | ||
|
||
|
||
.alg = "rfc4309(ccm(aes))", | ||
.test = alg_test_aead, | ||
.fips_allowed = 1, | ||
|
Oops, something went wrong.