Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Nettle
nettle
Commits
537bfdc0
Commit
537bfdc0
authored
May 30, 2011
by
Simon Josefsson
Committed by
Niels Möller
May 30, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(test_main): Add test vectors from libgcrypt.
Rev: nettle/testsuite/serpent-test.c:1.4
parent
037d694b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
0 deletions
+20
-0
testsuite/serpent-test.c
testsuite/serpent-test.c
+20
-0
No files found.
testsuite/serpent-test.c
View file @
537bfdc0
...
...
@@ -25,6 +25,26 @@ decode_hex_reverse (const char *hex)
int
test_main
(
void
)
{
/* From libgcrypt */
test_cipher
(
&
nettle_serpent128
,
HL
(
"0000000000000000 0000000000000000"
),
HL
(
"D29D576FCEA3A3A7 ED9099F29273D78E"
),
H
(
"B2288B968AE8B086 48D1CE9606FD992D"
));
test_cipher
(
&
nettle_serpent192
,
HL
(
"0000000000000000 0000000000000000 0000000000000000"
),
HL
(
"D29D576FCEABA3A7 ED9899F2927BD78E"
),
H
(
"130E353E1037C224 05E8FAEFB2C3C3E9"
));
test_cipher
(
&
nettle_serpent256
,
HL
(
"0000000000000000 0000000000000000"
"0000000000000000 0000000000000000"
),
HL
(
"D095576FCEA3E3A7 ED98D9F29073D78E"
),
H
(
"B90EE5862DE69168 F2BDD5125B45472B"
));
test_cipher
(
&
nettle_serpent256
,
HL
(
"0000000000000000 0000000000000000"
"0000000000000000 0000000000000000"
),
HL
(
"0000000001000000 0200000003000000"
),
H
(
"2061A42782BD52EC 691EC383B03BA77C"
));
/* The first test for each key size from the ecb_vk.txt and ecb_vt.txt
* files in the serpent package. */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment