mirror of
https://github.com/cryb-to/cryb-to.git
synced 2024-11-14 09:45:40 +00:00
2172 lines
47 KiB
C
2172 lines
47 KiB
C
/*-
|
||
* Copyright (c) 2017 Dag-Erling Smørgrav
|
||
* All rights reserved.
|
||
*
|
||
* Redistribution and use in source and binary forms, with or without
|
||
* modification, are permitted provided that the following conditions
|
||
* are met:
|
||
* 1. Redistributions of source code must retain the above copyright
|
||
* notice, this list of conditions and the following disclaimer.
|
||
* 2. Redistributions in binary form must reproduce the above copyright
|
||
* notice, this list of conditions and the following disclaimer in the
|
||
* documentation and/or other materials provided with the distribution.
|
||
* 3. The name of the author may not be used to endorse or promote
|
||
* products derived from this software without specific prior written
|
||
* permission.
|
||
*
|
||
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
|
||
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
|
||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||
* SUCH DAMAGE.
|
||
*/
|
||
|
||
#include "cryb/impl.h"
|
||
|
||
#include <sys/types.h>
|
||
|
||
#include <stdint.h>
|
||
#include <stdio.h>
|
||
|
||
#include <cryb/des.h>
|
||
|
||
#include <cryb/test.h>
|
||
|
||
struct t_case {
|
||
const char *desc;
|
||
const uint8_t key[8];
|
||
const uint8_t ptext[DES_BLOCK_LEN];
|
||
const uint8_t ctext[DES_BLOCK_LEN];
|
||
};
|
||
|
||
/***************************************************************************
|
||
* Test cases
|
||
*/
|
||
|
||
static struct t_case t_cases[] = {
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 0",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x95, 0xf8, 0xa5, 0xe5, 0xdd, 0x31, 0xd9, 0x00,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 1",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xdd, 0x7f, 0x12, 0x1c, 0xa5, 0x01, 0x56, 0x19,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 2",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x2e, 0x86, 0x53, 0x10, 0x4f, 0x38, 0x34, 0xea,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 3",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x4b, 0xd3, 0x88, 0xff, 0x6c, 0xd8, 0x1d, 0x4f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 4",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x20, 0xb9, 0xe7, 0x67, 0xb2, 0xfb, 0x14, 0x56,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 5",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x55, 0x57, 0x93, 0x80, 0xd7, 0x71, 0x38, 0xef,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 6",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x6c, 0xc5, 0xde, 0xfa, 0xaf, 0x04, 0x51, 0x2f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 7",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x0d, 0x9f, 0x27, 0x9b, 0xa5, 0xd8, 0x72, 0x60,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 8",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xd9, 0x03, 0x1b, 0x02, 0x71, 0xbd, 0x5a, 0x0a,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 9",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x42, 0x42, 0x50, 0xb3, 0x7c, 0x3d, 0xd9, 0x51,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 10",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xb8, 0x06, 0x1b, 0x7e, 0xcd, 0x9a, 0x21, 0xe5,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 11",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xf1, 0x5d, 0x0f, 0x28, 0x6b, 0x65, 0xbd, 0x28,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 12",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xad, 0xd0, 0xcc, 0x8d, 0x6e, 0x5d, 0xeb, 0xa1,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 13",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe6, 0xd5, 0xf8, 0x27, 0x52, 0xad, 0x63, 0xd1,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 14",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xec, 0xbf, 0xe3, 0xbd, 0x3f, 0x59, 0x1a, 0x5e,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 15",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xf3, 0x56, 0x83, 0x43, 0x79, 0xd1, 0x65, 0xcd,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 16",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x2b, 0x9f, 0x98, 0x2f, 0x20, 0x03, 0x7f, 0xa9,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 17",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x88, 0x9d, 0xe0, 0x68, 0xa1, 0x6f, 0x0b, 0xe6,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 18",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe1, 0x9e, 0x27, 0x5d, 0x84, 0x6a, 0x12, 0x98,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 19",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x32, 0x9a, 0x8e, 0xd5, 0x23, 0xd7, 0x1a, 0xec,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 20",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe7, 0xfc, 0xe2, 0x25, 0x57, 0xd2, 0x3c, 0x97,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 21",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x12, 0xa9, 0xf5, 0x81, 0x7f, 0xf2, 0xd6, 0x5d,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 22",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xa4, 0x84, 0xc3, 0xad, 0x38, 0xdc, 0x9c, 0x19,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 23",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xfb, 0xe0, 0x0a, 0x8a, 0x1e, 0xf8, 0xad, 0x72,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 24",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x75, 0x0d, 0x07, 0x94, 0x07, 0x52, 0x13, 0x63,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 25",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x64, 0xfe, 0xed, 0x9c, 0x72, 0x4c, 0x2f, 0xaf,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 26",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xf0, 0x2b, 0x26, 0x3b, 0x32, 0x8e, 0x2b, 0x60,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 27",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x9d, 0x64, 0x55, 0x5a, 0x9a, 0x10, 0xb8, 0x52,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 28",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xd1, 0x06, 0xff, 0x0b, 0xed, 0x52, 0x55, 0xd7,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 29",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe1, 0x65, 0x2c, 0x6b, 0x13, 0x8c, 0x64, 0xa5,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 30",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe4, 0x28, 0x58, 0x11, 0x86, 0xec, 0x8f, 0x46,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 31",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xae, 0xb5, 0xf5, 0xed, 0xe2, 0x2d, 0x1a, 0x36,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 32",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe9, 0x43, 0xd7, 0x56, 0x8a, 0xec, 0x0c, 0x5c,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 33",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xdf, 0x98, 0xc8, 0x27, 0x6f, 0x54, 0xb0, 0x4b,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 34",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xb1, 0x60, 0xe4, 0x68, 0x0f, 0x6c, 0x69, 0x6f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 35",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xfa, 0x07, 0x52, 0xb0, 0x7d, 0x9c, 0x4a, 0xb8,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 36",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xca, 0x3a, 0x2b, 0x03, 0x6d, 0xbc, 0x85, 0x02,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 37",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x5e, 0x09, 0x05, 0x51, 0x7b, 0xb5, 0x9b, 0xcf,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 38",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x81, 0x4e, 0xeb, 0x3b, 0x91, 0xd9, 0x07, 0x26,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 39",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x4d, 0x49, 0xdb, 0x15, 0x32, 0x91, 0x9c, 0x9f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 40",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x25, 0xeb, 0x5f, 0xc3, 0xf8, 0xcf, 0x06, 0x21,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 41",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xab, 0x6a, 0x20, 0xc0, 0x62, 0x0d, 0x1c, 0x6f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 42",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x79, 0xe9, 0x0d, 0xbc, 0x98, 0xf9, 0x2c, 0xca,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 43",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x86, 0x6e, 0xce, 0xdd, 0x80, 0x72, 0xbb, 0x0e,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 44",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x8b, 0x54, 0x53, 0x6f, 0x2f, 0x3e, 0x64, 0xa8,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 45",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xea, 0x51, 0xd3, 0x97, 0x55, 0x95, 0xb8, 0x6b,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 46",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xca, 0xff, 0xc6, 0xac, 0x45, 0x42, 0xde, 0x31,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 47",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x8d, 0xd4, 0x5a, 0x2d, 0xdf, 0x90, 0x79, 0x6c,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 48",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x10, 0x29, 0xd5, 0x5e, 0x88, 0x0e, 0xc2, 0xd0,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 49",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x5d, 0x86, 0xcb, 0x23, 0x63, 0x9d, 0xbe, 0xa9,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 50",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x1d, 0x1c, 0xa8, 0x53, 0xae, 0x7c, 0x0c, 0x5f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 51",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xce, 0x33, 0x23, 0x29, 0x24, 0x8f, 0x32, 0x28,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 52",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x84, 0x05, 0xd1, 0xab, 0xe2, 0x4f, 0xb9, 0x42,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 53",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe6, 0x43, 0xd7, 0x80, 0x90, 0xca, 0x42, 0x07,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 54",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x48, 0x22, 0x1b, 0x99, 0x37, 0x74, 0x8a, 0x23,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 55",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xdd, 0x7c, 0x0b, 0xbd, 0x61, 0xfa, 0xfd, 0x54,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 56",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
|
||
},
|
||
.ctext = {
|
||
0x2f, 0xbc, 0x29, 0x1a, 0x57, 0x0d, 0xb5, 0xc4,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 57",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40,
|
||
},
|
||
.ctext = {
|
||
0xe0, 0x7c, 0x30, 0xd7, 0xe4, 0xe2, 0x6e, 0x12,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 58",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20,
|
||
},
|
||
.ctext = {
|
||
0x09, 0x53, 0xe2, 0x25, 0x8e, 0x8e, 0x90, 0xa1,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 59",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10,
|
||
},
|
||
.ctext = {
|
||
0x5b, 0x71, 0x1b, 0xc4, 0xce, 0xeb, 0xf2, 0xee,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 60",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08,
|
||
},
|
||
.ctext = {
|
||
0xcc, 0x08, 0x3f, 0x1e, 0x6d, 0x9e, 0x85, 0xf6,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 61",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04,
|
||
},
|
||
.ctext = {
|
||
0xd2, 0xfd, 0x88, 0x67, 0xd5, 0x0d, 0x2d, 0xfe,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 62",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02,
|
||
},
|
||
.ctext = {
|
||
0x06, 0xe7, 0xea, 0x22, 0xce, 0x92, 0x70, 0x8f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvartext 63",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01,
|
||
},
|
||
.ctext = {
|
||
0x16, 0x6b, 0x40, 0xb4, 0x4a, 0xba, 0x4b, 0xd6,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 0",
|
||
.key = {
|
||
0x80, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x95, 0xa8, 0xd7, 0x28, 0x13, 0xda, 0xa9, 0x4d,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 1",
|
||
.key = {
|
||
0x40, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x0e, 0xec, 0x14, 0x87, 0xdd, 0x8c, 0x26, 0xd5,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 2",
|
||
.key = {
|
||
0x20, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x7a, 0xd1, 0x6f, 0xfb, 0x79, 0xc4, 0x59, 0x26,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 3",
|
||
.key = {
|
||
0x10, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xd3, 0x74, 0x62, 0x94, 0xca, 0x6a, 0x6c, 0xf3,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 4",
|
||
.key = {
|
||
0x08, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x80, 0x9f, 0x5f, 0x87, 0x3c, 0x1f, 0xd7, 0x61,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 5",
|
||
.key = {
|
||
0x04, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xc0, 0x2f, 0xaf, 0xfe, 0xc9, 0x89, 0xd1, 0xfc,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 6",
|
||
.key = {
|
||
0x02, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x46, 0x15, 0xaa, 0x1d, 0x33, 0xe7, 0x2f, 0x10,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 7",
|
||
.key = {
|
||
0x01, 0x80, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x20, 0x55, 0x12, 0x33, 0x50, 0xc0, 0x08, 0x58,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 8",
|
||
.key = {
|
||
0x01, 0x40, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xdf, 0x3b, 0x99, 0xd6, 0x57, 0x73, 0x97, 0xc8,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 9",
|
||
.key = {
|
||
0x01, 0x20, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x31, 0xfe, 0x17, 0x36, 0x9b, 0x52, 0x88, 0xc9,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 10",
|
||
.key = {
|
||
0x01, 0x10, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xdf, 0xdd, 0x3c, 0xc6, 0x4d, 0xae, 0x16, 0x42,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 11",
|
||
.key = {
|
||
0x01, 0x08, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x17, 0x8c, 0x83, 0xce, 0x2b, 0x39, 0x9d, 0x94,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 12",
|
||
.key = {
|
||
0x01, 0x04, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x50, 0xf6, 0x36, 0x32, 0x4a, 0x9b, 0x7f, 0x80,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 13",
|
||
.key = {
|
||
0x01, 0x02, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xa8, 0x46, 0x8e, 0xe3, 0xbc, 0x18, 0xf0, 0x6d,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 14",
|
||
.key = {
|
||
0x01, 0x01, 0x80, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xa2, 0xdc, 0x9e, 0x92, 0xfd, 0x3c, 0xde, 0x92,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 15",
|
||
.key = {
|
||
0x01, 0x01, 0x40, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xca, 0xc0, 0x9f, 0x79, 0x7d, 0x03, 0x12, 0x87,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 16",
|
||
.key = {
|
||
0x01, 0x01, 0x20, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x90, 0xba, 0x68, 0x0b, 0x22, 0xae, 0xb5, 0x25,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 17",
|
||
.key = {
|
||
0x01, 0x01, 0x10, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xce, 0x7a, 0x24, 0xf3, 0x50, 0xe2, 0x80, 0xb6,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 18",
|
||
.key = {
|
||
0x01, 0x01, 0x08, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x88, 0x2b, 0xff, 0x0a, 0xa0, 0x1a, 0x0b, 0x87,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 19",
|
||
.key = {
|
||
0x01, 0x01, 0x04, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x25, 0x61, 0x02, 0x88, 0x92, 0x45, 0x11, 0xc2,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 20",
|
||
.key = {
|
||
0x01, 0x01, 0x02, 0x01, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xc7, 0x15, 0x16, 0xc2, 0x9c, 0x75, 0xd1, 0x70,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 21",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x80, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x51, 0x99, 0xc2, 0x9a, 0x52, 0xc9, 0xf0, 0x59,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 22",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x40, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xc2, 0x2f, 0x0a, 0x29, 0x4a, 0x71, 0xf2, 0x9f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 23",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x20, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xee, 0x37, 0x14, 0x83, 0x71, 0x4c, 0x02, 0xea,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 24",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x10, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xa8, 0x1f, 0xbd, 0x44, 0x8f, 0x9e, 0x52, 0x2f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 25",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x08, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x4f, 0x64, 0x4c, 0x92, 0xe1, 0x92, 0xdf, 0xed,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 26",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x04, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x1a, 0xfa, 0x9a, 0x66, 0xa6, 0xdf, 0x92, 0xae,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 27",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x02, 0x01, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xb3, 0xc1, 0xcc, 0x71, 0x5c, 0xb8, 0x79, 0xd8,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 28",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x80, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x19, 0xd0, 0x32, 0xe6, 0x4a, 0xb0, 0xbd, 0x8b,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 29",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x40, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x3c, 0xfa, 0xa7, 0xa7, 0xdc, 0x87, 0x20, 0xdc,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 30",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x20, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xb7, 0x26, 0x5f, 0x7f, 0x44, 0x7a, 0xc6, 0xf3,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 31",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x10, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x9d, 0xb7, 0x3b, 0x3c, 0x0d, 0x16, 0x3f, 0x54,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 32",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x08, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x81, 0x81, 0xb6, 0x5b, 0xab, 0xf4, 0xa9, 0x75,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 33",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x04, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x93, 0xc9, 0xb6, 0x40, 0x42, 0xea, 0xa2, 0x40,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 34",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x02, 0x01, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x55, 0x70, 0x53, 0x08, 0x29, 0x70, 0x55, 0x92,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 35",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x80, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x86, 0x38, 0x80, 0x9e, 0x87, 0x87, 0x87, 0xa0,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 36",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x40, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x41, 0xb9, 0xa7, 0x9a, 0xf7, 0x9a, 0xc2, 0x08,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 37",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x20, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x7a, 0x9b, 0xe4, 0x2f, 0x20, 0x09, 0xa8, 0x92,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 38",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x10, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x29, 0x03, 0x8d, 0x56, 0xba, 0x6d, 0x27, 0x45,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 39",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x08, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x54, 0x95, 0xc6, 0xab, 0xf1, 0xe5, 0xdf, 0x51,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 40",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x04, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xae, 0x13, 0xdb, 0xd5, 0x61, 0x48, 0x89, 0x33,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 41",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x02, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x02, 0x4d, 0x1f, 0xfa, 0x89, 0x04, 0xe3, 0x89,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 42",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x80, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xd1, 0x39, 0x97, 0x12, 0xf9, 0x9b, 0xf0, 0x2e,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 43",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x40, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x14, 0xc1, 0xd7, 0xc1, 0xcf, 0xfe, 0xc7, 0x9e,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 44",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x20, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x1d, 0xe5, 0x27, 0x9d, 0xae, 0x3b, 0xed, 0x6f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 45",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x10, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe9, 0x41, 0xa3, 0x3f, 0x85, 0x50, 0x13, 0x03,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 46",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x08, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xda, 0x99, 0xdb, 0xbc, 0x9a, 0x03, 0xf3, 0x79,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 47",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x04, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xb7, 0xfc, 0x92, 0xf9, 0x1d, 0x8e, 0x92, 0xe9,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 48",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x02, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xae, 0x8e, 0x5c, 0xaa, 0x3c, 0xa0, 0x4e, 0x85,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 49",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x80,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x9c, 0xc6, 0x2d, 0xf4, 0x3b, 0x6e, 0xed, 0x74,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 50",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x40,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xd8, 0x63, 0xdb, 0xb5, 0xc5, 0x9a, 0x91, 0xa0,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 51",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x20,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xa1, 0xab, 0x21, 0x90, 0x54, 0x5b, 0x91, 0xd7,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 52",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x10,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x08, 0x75, 0x04, 0x1e, 0x64, 0xc5, 0x70, 0xf7,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 53",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x08,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x5a, 0x59, 0x45, 0x28, 0xbe, 0xbe, 0xf1, 0xcc,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 54",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x04,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xfc, 0xdb, 0x32, 0x91, 0xde, 0x21, 0xf0, 0xc0,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBvarkey 55",
|
||
.key = {
|
||
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x02,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x86, 0x9e, 0xfd, 0x7f, 0x9f, 0x26, 0x5a, 0x09,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 0",
|
||
.key = {
|
||
0x10, 0x46, 0x91, 0x34, 0x89, 0x98, 0x01, 0x31,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x88, 0xd5, 0x5e, 0x54, 0xf5, 0x4c, 0x97, 0xb4,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 1",
|
||
.key = {
|
||
0x10, 0x07, 0x10, 0x34, 0x89, 0x98, 0x80, 0x20,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x0c, 0x0c, 0xc0, 0x0c, 0x83, 0xea, 0x48, 0xfd,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 2",
|
||
.key = {
|
||
0x10, 0x07, 0x10, 0x34, 0xc8, 0x98, 0x01, 0x20,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x83, 0xbc, 0x8e, 0xf3, 0xa6, 0x57, 0x01, 0x83,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 3",
|
||
.key = {
|
||
0x10, 0x46, 0x10, 0x34, 0x89, 0x98, 0x80, 0x20,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xdf, 0x72, 0x5d, 0xca, 0xd9, 0x4e, 0xa2, 0xe9,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 4",
|
||
.key = {
|
||
0x10, 0x86, 0x91, 0x15, 0x19, 0x19, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe6, 0x52, 0xb5, 0x3b, 0x55, 0x0b, 0xe8, 0xb0,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 5",
|
||
.key = {
|
||
0x10, 0x86, 0x91, 0x15, 0x19, 0x58, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xaf, 0x52, 0x71, 0x20, 0xc4, 0x85, 0xcb, 0xb0,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 6",
|
||
.key = {
|
||
0x51, 0x07, 0xb0, 0x15, 0x19, 0x58, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x0f, 0x04, 0xce, 0x39, 0x3d, 0xb9, 0x26, 0xd5,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 7",
|
||
.key = {
|
||
0x10, 0x07, 0xb0, 0x15, 0x19, 0x19, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xc9, 0xf0, 0x0f, 0xfc, 0x74, 0x07, 0x90, 0x67,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 8",
|
||
.key = {
|
||
0x31, 0x07, 0x91, 0x54, 0x98, 0x08, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x7c, 0xfd, 0x82, 0xa5, 0x93, 0x25, 0x2b, 0x4e,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 9",
|
||
.key = {
|
||
0x31, 0x07, 0x91, 0x94, 0x98, 0x08, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xcb, 0x49, 0xa2, 0xf9, 0xe9, 0x13, 0x63, 0xe3,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 10",
|
||
.key = {
|
||
0x10, 0x07, 0x91, 0x15, 0xb9, 0x08, 0x01, 0x40,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x00, 0xb5, 0x88, 0xbe, 0x70, 0xd2, 0x3f, 0x56,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 11",
|
||
.key = {
|
||
0x31, 0x07, 0x91, 0x15, 0x98, 0x08, 0x01, 0x40,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x40, 0x6a, 0x9a, 0x6a, 0xb4, 0x33, 0x99, 0xae,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 12",
|
||
.key = {
|
||
0x10, 0x07, 0xd0, 0x15, 0x89, 0x98, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x6c, 0xb7, 0x73, 0x61, 0x1d, 0xca, 0x9a, 0xda,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 13",
|
||
.key = {
|
||
0x91, 0x07, 0x91, 0x15, 0x89, 0x98, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x67, 0xfd, 0x21, 0xc1, 0x7d, 0xbb, 0x5d, 0x70,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 14",
|
||
.key = {
|
||
0x91, 0x07, 0xd0, 0x15, 0x89, 0x19, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x95, 0x92, 0xcb, 0x41, 0x10, 0x43, 0x07, 0x87,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 15",
|
||
.key = {
|
||
0x10, 0x07, 0xd0, 0x15, 0x98, 0x98, 0x01, 0x20,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xa6, 0xb7, 0xff, 0x68, 0xa3, 0x18, 0xdd, 0xd3,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 16",
|
||
.key = {
|
||
0x10, 0x07, 0x94, 0x04, 0x98, 0x19, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x4d, 0x10, 0x21, 0x96, 0xc9, 0x14, 0xca, 0x16,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 17",
|
||
.key = {
|
||
0x01, 0x07, 0x91, 0x04, 0x91, 0x19, 0x04, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x2d, 0xfa, 0x9f, 0x45, 0x73, 0x59, 0x49, 0x65,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 18",
|
||
.key = {
|
||
0x01, 0x07, 0x91, 0x04, 0x91, 0x19, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xb4, 0x66, 0x04, 0x81, 0x6c, 0x0e, 0x07, 0x74,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 19",
|
||
.key = {
|
||
0x01, 0x07, 0x94, 0x04, 0x91, 0x19, 0x04, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x6e, 0x7e, 0x62, 0x21, 0xa4, 0xf3, 0x4e, 0x87,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 20",
|
||
.key = {
|
||
0x19, 0x07, 0x92, 0x10, 0x98, 0x1a, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xaa, 0x85, 0xe7, 0x46, 0x43, 0x23, 0x31, 0x99,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 21",
|
||
.key = {
|
||
0x10, 0x07, 0x91, 0x19, 0x98, 0x19, 0x08, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x2e, 0x5a, 0x19, 0xdb, 0x4d, 0x19, 0x62, 0xd6,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 22",
|
||
.key = {
|
||
0x10, 0x07, 0x91, 0x19, 0x98, 0x1a, 0x08, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x23, 0xa8, 0x66, 0xa8, 0x09, 0xd3, 0x08, 0x94,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 23",
|
||
.key = {
|
||
0x10, 0x07, 0x92, 0x10, 0x98, 0x19, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xd8, 0x12, 0xd9, 0x61, 0xf0, 0x17, 0xd3, 0x20,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 24",
|
||
.key = {
|
||
0x10, 0x07, 0x91, 0x15, 0x98, 0x19, 0x01, 0x0b,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x05, 0x56, 0x05, 0x81, 0x6e, 0x58, 0x60, 0x8f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 25",
|
||
.key = {
|
||
0x10, 0x04, 0x80, 0x15, 0x98, 0x19, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xab, 0xd8, 0x8e, 0x8b, 0x1b, 0x77, 0x16, 0xf1,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 26",
|
||
.key = {
|
||
0x10, 0x04, 0x80, 0x15, 0x98, 0x19, 0x01, 0x02,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x53, 0x7a, 0xc9, 0x5b, 0xe6, 0x9d, 0xa1, 0xe1,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 27",
|
||
.key = {
|
||
0x10, 0x04, 0x80, 0x15, 0x98, 0x19, 0x01, 0x08,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xae, 0xd0, 0xf6, 0xae, 0x3c, 0x25, 0xcd, 0xd8,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 28",
|
||
.key = {
|
||
0x10, 0x02, 0x91, 0x15, 0x98, 0x10, 0x01, 0x04,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xb3, 0xe3, 0x5a, 0x5e, 0xe5, 0x3e, 0x7b, 0x8d,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 29",
|
||
.key = {
|
||
0x10, 0x02, 0x91, 0x15, 0x98, 0x19, 0x01, 0x04,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x61, 0xc7, 0x9c, 0x71, 0x92, 0x1a, 0x2e, 0xf8,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 30",
|
||
.key = {
|
||
0x10, 0x02, 0x91, 0x15, 0x98, 0x10, 0x02, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0xe2, 0xf5, 0x72, 0x8f, 0x09, 0x95, 0x01, 0x3c,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBpermop 31",
|
||
.key = {
|
||
0x10, 0x02, 0x91, 0x16, 0x98, 0x10, 0x01, 0x01,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||
},
|
||
.ctext = {
|
||
0x1a, 0xea, 0xc3, 0x9a, 0x61, 0xf0, 0xa4, 0x64,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 0",
|
||
.key = {
|
||
0x7c, 0xa1, 0x10, 0x45, 0x4a, 0x1a, 0x6e, 0x57,
|
||
},
|
||
.ptext = {
|
||
0x01, 0xa1, 0xd6, 0xd0, 0x39, 0x77, 0x67, 0x42,
|
||
},
|
||
.ctext = {
|
||
0x69, 0x0f, 0x5b, 0x0d, 0x9a, 0x26, 0x93, 0x9b,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 1",
|
||
.key = {
|
||
0x01, 0x31, 0xd9, 0x61, 0x9d, 0xc1, 0x37, 0x6e,
|
||
},
|
||
.ptext = {
|
||
0x5c, 0xd5, 0x4c, 0xa8, 0x3d, 0xef, 0x57, 0xda,
|
||
},
|
||
.ctext = {
|
||
0x7a, 0x38, 0x9d, 0x10, 0x35, 0x4b, 0xd2, 0x71,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 2",
|
||
.key = {
|
||
0x07, 0xa1, 0x13, 0x3e, 0x4a, 0x0b, 0x26, 0x86,
|
||
},
|
||
.ptext = {
|
||
0x02, 0x48, 0xd4, 0x38, 0x06, 0xf6, 0x71, 0x72,
|
||
},
|
||
.ctext = {
|
||
0x86, 0x8e, 0xbb, 0x51, 0xca, 0xb4, 0x59, 0x9a,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 3",
|
||
.key = {
|
||
0x38, 0x49, 0x67, 0x4c, 0x26, 0x02, 0x31, 0x9e,
|
||
},
|
||
.ptext = {
|
||
0x51, 0x45, 0x4b, 0x58, 0x2d, 0xdf, 0x44, 0x0a,
|
||
},
|
||
.ctext = {
|
||
0x71, 0x78, 0x87, 0x6e, 0x01, 0xf1, 0x9b, 0x2a,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 4",
|
||
.key = {
|
||
0x04, 0xb9, 0x15, 0xba, 0x43, 0xfe, 0xb5, 0xb6,
|
||
},
|
||
.ptext = {
|
||
0x42, 0xfd, 0x44, 0x30, 0x59, 0x57, 0x7f, 0xa2,
|
||
},
|
||
.ctext = {
|
||
0xaf, 0x37, 0xfb, 0x42, 0x1f, 0x8c, 0x40, 0x95,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 5",
|
||
.key = {
|
||
0x01, 0x13, 0xb9, 0x70, 0xfd, 0x34, 0xf2, 0xce,
|
||
},
|
||
.ptext = {
|
||
0x05, 0x9b, 0x5e, 0x08, 0x51, 0xcf, 0x14, 0x3a,
|
||
},
|
||
.ctext = {
|
||
0x86, 0xa5, 0x60, 0xf1, 0x0e, 0xc6, 0xd8, 0x5b,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 6",
|
||
.key = {
|
||
0x01, 0x70, 0xf1, 0x75, 0x46, 0x8f, 0xb5, 0xe6,
|
||
},
|
||
.ptext = {
|
||
0x07, 0x56, 0xd8, 0xe0, 0x77, 0x47, 0x61, 0xd2,
|
||
},
|
||
.ctext = {
|
||
0x0c, 0xd3, 0xda, 0x02, 0x00, 0x21, 0xdc, 0x09,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 7",
|
||
.key = {
|
||
0x43, 0x29, 0x7f, 0xad, 0x38, 0xe3, 0x73, 0xfe,
|
||
},
|
||
.ptext = {
|
||
0x76, 0x25, 0x14, 0xb8, 0x29, 0xbf, 0x48, 0x6a,
|
||
},
|
||
.ctext = {
|
||
0xea, 0x67, 0x6b, 0x2c, 0xb7, 0xdb, 0x2b, 0x7a,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 8",
|
||
.key = {
|
||
0x07, 0xa7, 0x13, 0x70, 0x45, 0xda, 0x2a, 0x16,
|
||
},
|
||
.ptext = {
|
||
0x3b, 0xdd, 0x11, 0x90, 0x49, 0x37, 0x28, 0x02,
|
||
},
|
||
.ctext = {
|
||
0xdf, 0xd6, 0x4a, 0x81, 0x5c, 0xaf, 0x1a, 0x0f,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 9",
|
||
.key = {
|
||
0x04, 0x68, 0x91, 0x04, 0xc2, 0xfd, 0x3b, 0x2f,
|
||
},
|
||
.ptext = {
|
||
0x26, 0x95, 0x5f, 0x68, 0x35, 0xaf, 0x60, 0x9a,
|
||
},
|
||
.ctext = {
|
||
0x5c, 0x51, 0x3c, 0x9c, 0x48, 0x86, 0xc0, 0x88,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 10",
|
||
.key = {
|
||
0x37, 0xd0, 0x6b, 0xb5, 0x16, 0xcb, 0x75, 0x46,
|
||
},
|
||
.ptext = {
|
||
0x16, 0x4d, 0x5e, 0x40, 0x4f, 0x27, 0x52, 0x32,
|
||
},
|
||
.ctext = {
|
||
0x0a, 0x2a, 0xee, 0xae, 0x3f, 0xf4, 0xab, 0x77,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 11",
|
||
.key = {
|
||
0x1f, 0x08, 0x26, 0x0d, 0x1a, 0xc2, 0x46, 0x5e,
|
||
},
|
||
.ptext = {
|
||
0x6b, 0x05, 0x6e, 0x18, 0x75, 0x9f, 0x5c, 0xca,
|
||
},
|
||
.ctext = {
|
||
0xef, 0x1b, 0xf0, 0x3e, 0x5d, 0xfa, 0x57, 0x5a,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 12",
|
||
.key = {
|
||
0x58, 0x40, 0x23, 0x64, 0x1a, 0xba, 0x61, 0x76,
|
||
},
|
||
.ptext = {
|
||
0x00, 0x4b, 0xd6, 0xef, 0x09, 0x17, 0x60, 0x62,
|
||
},
|
||
.ctext = {
|
||
0x88, 0xbf, 0x0d, 0xb6, 0xd7, 0x0d, 0xee, 0x56,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 13",
|
||
.key = {
|
||
0x02, 0x58, 0x16, 0x16, 0x46, 0x29, 0xb0, 0x07,
|
||
},
|
||
.ptext = {
|
||
0x48, 0x0d, 0x39, 0x00, 0x6e, 0xe7, 0x62, 0xf2,
|
||
},
|
||
.ctext = {
|
||
0xa1, 0xf9, 0x91, 0x55, 0x41, 0x02, 0x0b, 0x56,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 14",
|
||
.key = {
|
||
0x49, 0x79, 0x3e, 0xbc, 0x79, 0xb3, 0x25, 0x8f,
|
||
},
|
||
.ptext = {
|
||
0x43, 0x75, 0x40, 0xc8, 0x69, 0x8f, 0x3c, 0xfa,
|
||
},
|
||
.ctext = {
|
||
0x6f, 0xbf, 0x1c, 0xaf, 0xcf, 0xfd, 0x05, 0x56,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 15",
|
||
.key = {
|
||
0x4f, 0xb0, 0x5e, 0x15, 0x15, 0xab, 0x73, 0xa7,
|
||
},
|
||
.ptext = {
|
||
0x07, 0x2d, 0x43, 0xa0, 0x77, 0x07, 0x52, 0x92,
|
||
},
|
||
.ctext = {
|
||
0x2f, 0x22, 0xe4, 0x9b, 0xab, 0x7c, 0xa1, 0xac,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 16",
|
||
.key = {
|
||
0x49, 0xe9, 0x5d, 0x6d, 0x4c, 0xa2, 0x29, 0xbf,
|
||
},
|
||
.ptext = {
|
||
0x02, 0xfe, 0x55, 0x77, 0x81, 0x17, 0xf1, 0x2a,
|
||
},
|
||
.ctext = {
|
||
0x5a, 0x6b, 0x61, 0x2c, 0xc2, 0x6c, 0xce, 0x4a,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 17",
|
||
.key = {
|
||
0x01, 0x83, 0x10, 0xdc, 0x40, 0x9b, 0x26, 0xd6,
|
||
},
|
||
.ptext = {
|
||
0x1d, 0x9d, 0x5c, 0x50, 0x18, 0xf7, 0x28, 0xc2,
|
||
},
|
||
.ctext = {
|
||
0x5f, 0x4c, 0x03, 0x8e, 0xd1, 0x2b, 0x2e, 0x41,
|
||
},
|
||
},
|
||
{
|
||
.desc = "NIST CAVS 11.1 TECBsubtab 18",
|
||
.key = {
|
||
0x1c, 0x58, 0x7f, 0x1c, 0x13, 0x92, 0x4f, 0xef,
|
||
},
|
||
.ptext = {
|
||
0x30, 0x55, 0x32, 0x28, 0x6d, 0x6f, 0x29, 0x5a,
|
||
},
|
||
.ctext = {
|
||
0x63, 0xfa, 0xc0, 0xd0, 0x34, 0xd9, 0xf7, 0x93,
|
||
},
|
||
},
|
||
};
|
||
|
||
/***************************************************************************
|
||
* Test functions
|
||
*/
|
||
|
||
static int
|
||
t_des_enc(char **desc, void *arg)
|
||
{
|
||
struct t_case *t = arg;
|
||
uint8_t out[DES_BLOCK_LEN];
|
||
des_ctx ctx;
|
||
size_t len;
|
||
int ret;
|
||
|
||
(void)asprintf(desc, "%s (encrypt)", t->desc);
|
||
des_init(&ctx, CIPHER_MODE_ENCRYPT, t->key, sizeof t->key);
|
||
len = des_encrypt(&ctx, t->ptext, out, DES_BLOCK_LEN);
|
||
des_finish(&ctx);
|
||
ret = t_compare_sz(DES_BLOCK_LEN, len) &
|
||
t_compare_mem(t->ctext, out, DES_BLOCK_LEN);
|
||
return (ret);
|
||
}
|
||
|
||
static int
|
||
t_des_dec(char **desc, void *arg)
|
||
{
|
||
struct t_case *t = arg;
|
||
uint8_t out[DES_BLOCK_LEN];
|
||
des_ctx ctx;
|
||
size_t len;
|
||
int ret;
|
||
|
||
(void)asprintf(desc, "%s (decrypt)", t->desc);
|
||
des_init(&ctx, CIPHER_MODE_DECRYPT, t->key, sizeof t->key);
|
||
len = des_decrypt(&ctx, t->ctext, out, DES_BLOCK_LEN);
|
||
des_finish(&ctx);
|
||
ret = t_compare_sz(DES_BLOCK_LEN, len) &
|
||
t_compare_mem(t->ptext, out, DES_BLOCK_LEN);
|
||
return (ret);
|
||
}
|
||
|
||
|
||
/***************************************************************************
|
||
* Boilerplate
|
||
*/
|
||
|
||
static int
|
||
t_prepare(int argc, char *argv[])
|
||
{
|
||
unsigned int i, n;
|
||
|
||
(void)argc;
|
||
(void)argv;
|
||
n = sizeof t_cases / sizeof t_cases[0];
|
||
for (i = 0; i < n; ++i) {
|
||
t_add_test(t_des_enc, &t_cases[i], "%s", t_cases[i].desc);
|
||
t_add_test(t_des_dec, &t_cases[i], "%s", t_cases[i].desc);
|
||
}
|
||
return (0);
|
||
}
|
||
|
||
int
|
||
main(int argc, char *argv[])
|
||
{
|
||
|
||
t_main(t_prepare, NULL, argc, argv);
|
||
}
|