2 # Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
4 # Licensed under the Apache License 2.0 (the "License"). You may not use
5 # this file except in compliance with the License. You can obtain a copy
6 # in the file LICENSE in the source distribution or at
7 # https://www.openssl.org/source/license.html
9 # Tests start with one of these keywords
10 # Cipher Decrypt Derive Digest Encoding KDF MAC PBE
11 # PrivPubKeyPair Sign Verify VerifyRecover
12 # and continue until a blank line. Lines starting with a pound sign are ignored.
14 # SIPHASH tests - default values: 2,4 rounds, 16-byte mac
15 # There are no official test vectors, they are simple vectors 1, 2, 3, etc
20 Key = 000102030405060708090A0B0C0D0E0F
22 Output = a3817f04ba25a8e66df67214c7550293
25 Key = 000102030405060708090A0B0C0D0E0F
27 Output = da87c1d86b99af44347659119b22fc45
30 Key = 000102030405060708090A0B0C0D0E0F
32 Output = 8177228da4a45dc7fca38bdef60affe4
35 Key = 000102030405060708090A0B0C0D0E0F
37 Output = 9c70b60c5267a94e5f33b6b02985ed51
40 Key = 000102030405060708090A0B0C0D0E0F
42 Output = f88164c12d9c8faf7d0f6e7c7bcd5579
45 Key = 000102030405060708090A0B0C0D0E0F
47 Output = 1368875980776f8854527a07690e9627
50 Key = 000102030405060708090A0B0C0D0E0F
52 Output = 14eeca338b208613485ea0308fd7a15e
55 Key = 000102030405060708090A0B0C0D0E0F
56 Input = 00010203040506
57 Output = a1f1ebbed8dbc153c0b84aa61ff08239
60 Key = 000102030405060708090A0B0C0D0E0F
61 Input = 0001020304050607
62 Output = 3b62a9ba6258f5610f83e264f31497b4
65 Key = 000102030405060708090A0B0C0D0E0F
66 Input = 000102030405060708
67 Output = 264499060ad9baabc47f8b02bb6d71ed
70 Key = 000102030405060708090A0B0C0D0E0F
71 Input = 000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E
72 Output = 5150d1772f50834a503e069a973fbd7c
75 Key = 000102030405060708090A0B0C0D0E0F
77 Output = a3817f04ba25a8e66df67214c7550293
80 Key = 000102030405060708090A0B0C0D0E0F
82 Output = da87c1d86b99af44347659119b22fc45
85 Key = 000102030405060708090A0B0C0D0E0F
87 Output = 8177228da4a45dc7fca38bdef60affe4
90 Key = 000102030405060708090A0B0C0D0E0F
92 Output = 9c70b60c5267a94e5f33b6b02985ed51
95 Key = 000102030405060708090A0B0C0D0E0F
97 Output = f88164c12d9c8faf7d0f6e7c7bcd5579
100 Key = 000102030405060708090A0B0C0D0E0F
102 Output = 1368875980776f8854527a07690e9627
105 Key = 000102030405060708090A0B0C0D0E0F
107 Output = 14eeca338b208613485ea0308fd7a15e
110 Key = 000102030405060708090A0B0C0D0E0F
111 Input = 00010203040506
112 Output = a1f1ebbed8dbc153c0b84aa61ff08239
115 Key = 000102030405060708090A0B0C0D0E0F
116 Input = 0001020304050607
117 Output = 3b62a9ba6258f5610f83e264f31497b4
119 MAC = SipHash by EVP_PKEY
120 Key = 000102030405060708090A0B0C0D0E0F
121 Input = 000102030405060708
122 Output = 264499060ad9baabc47f8b02bb6d71ed
125 Key = 000102030405060708090A0B0C0D0E0F
126 Input = 000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E
127 Output = 5150d1772f50834a503e069a973fbd7c
129 # SIPHASH - default values: 2,4 rounds, explicit 8-byte mac
133 Key = 000102030405060708090A0B0C0D0E0F
134 Input = 000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E
135 Output = 724506EB4C328A95
137 # SIPHASH - default values: 2,4 rounds, explicit 16-byte mac
141 Key = 000102030405060708090A0B0C0D0E0F
142 Input = 000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E
143 Output = 5150d1772f50834a503e069a973fbd7c
145 # SIPHASH - default values: 2,4 rounds, explicit 16-byte mac (set as 0)
149 Key = 000102030405060708090A0B0C0D0E0F
150 Input = 000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E
151 Output = 5150d1772f50834a503e069a973fbd7c
153 # SIPHASH - default values: 2,4 rounds, explicit 13-byte mac (invalid size)
157 Key = 000102030405060708090A0B0C0D0E0F
158 Result = MAC_BAD_PARAMS
160 # SIPHASH - default values: 2,4 rounds, explicit 13-byte mac (invalid size)
161 # by EVP_PKEY this time
163 MAC = SipHash by EVP_PKEY
165 Key = 000102030405060708090A0B0C0D0E0F
166 Result = EVPPKEYCTXCTRL_ERROR