mirror of
https://github.com/ipxe/ipxe
synced 2026-01-23 04:29:01 +03:00
The DES block cipher dates back to the 1970s. It is no longer relevant for use in TLS cipher suites, but it is still used by the MS-CHAPv2 authentication protocol which remains unfortunately common for 802.1x port authentication. Add an implementation of the DES block cipher, complete with the extremely comprehensive test vectors published by NBS (the precursor to NIST) in the form of an utterly adorable typewritten and hand-drawn paper document. Signed-off-by: Michael Brown <mcb30@ipxe.org>
86 lines
2.7 KiB
C
86 lines
2.7 KiB
C
/*
|
|
* Copyright (C) 2012 Michael Brown <mbrown@fensystems.co.uk>.
|
|
*
|
|
* 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 any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful, but
|
|
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
* General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program; if not, write to the Free Software
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
|
* 02110-1301, USA.
|
|
*
|
|
* You can also choose to distribute this program under the terms of
|
|
* the Unmodified Binary Distribution Licence (as given in the file
|
|
* COPYING.UBDL), provided that you have satisfied its requirements.
|
|
*/
|
|
|
|
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
|
|
|
/** @file
|
|
*
|
|
* Self-test collection
|
|
*
|
|
*/
|
|
|
|
/* Drag in all applicable self-tests */
|
|
PROVIDE_REQUIRING_SYMBOL();
|
|
REQUIRE_OBJECT ( memset_test );
|
|
REQUIRE_OBJECT ( memcpy_test );
|
|
REQUIRE_OBJECT ( string_test );
|
|
REQUIRE_OBJECT ( math_test );
|
|
REQUIRE_OBJECT ( vsprintf_test );
|
|
REQUIRE_OBJECT ( list_test );
|
|
REQUIRE_OBJECT ( byteswap_test );
|
|
REQUIRE_OBJECT ( base64_test );
|
|
REQUIRE_OBJECT ( base16_test );
|
|
REQUIRE_OBJECT ( settings_test );
|
|
REQUIRE_OBJECT ( time_test );
|
|
REQUIRE_OBJECT ( tcpip_test );
|
|
REQUIRE_OBJECT ( ipv4_test );
|
|
REQUIRE_OBJECT ( ipv6_test );
|
|
REQUIRE_OBJECT ( crc32_test );
|
|
REQUIRE_OBJECT ( md4_test );
|
|
REQUIRE_OBJECT ( md5_test );
|
|
REQUIRE_OBJECT ( sha1_test );
|
|
REQUIRE_OBJECT ( sha256_test );
|
|
REQUIRE_OBJECT ( sha512_test );
|
|
REQUIRE_OBJECT ( aes_test );
|
|
REQUIRE_OBJECT ( hmac_drbg_test );
|
|
REQUIRE_OBJECT ( hash_df_test );
|
|
REQUIRE_OBJECT ( bigint_test );
|
|
REQUIRE_OBJECT ( rsa_test );
|
|
REQUIRE_OBJECT ( x509_test );
|
|
REQUIRE_OBJECT ( ocsp_test );
|
|
REQUIRE_OBJECT ( cms_test );
|
|
REQUIRE_OBJECT ( pnm_test );
|
|
REQUIRE_OBJECT ( deflate_test );
|
|
REQUIRE_OBJECT ( png_test );
|
|
REQUIRE_OBJECT ( dns_test );
|
|
REQUIRE_OBJECT ( uri_test );
|
|
REQUIRE_OBJECT ( profile_test );
|
|
REQUIRE_OBJECT ( setjmp_test );
|
|
REQUIRE_OBJECT ( pccrc_test );
|
|
REQUIRE_OBJECT ( linebuf_test );
|
|
REQUIRE_OBJECT ( iobuf_test );
|
|
REQUIRE_OBJECT ( bitops_test );
|
|
REQUIRE_OBJECT ( der_test );
|
|
REQUIRE_OBJECT ( pem_test );
|
|
REQUIRE_OBJECT ( ntlm_test );
|
|
REQUIRE_OBJECT ( zlib_test );
|
|
REQUIRE_OBJECT ( gzip_test );
|
|
REQUIRE_OBJECT ( utf8_test );
|
|
REQUIRE_OBJECT ( acpi_test );
|
|
REQUIRE_OBJECT ( hmac_test );
|
|
REQUIRE_OBJECT ( dhe_test );
|
|
REQUIRE_OBJECT ( gcm_test );
|
|
REQUIRE_OBJECT ( nap_test );
|
|
REQUIRE_OBJECT ( x25519_test );
|
|
REQUIRE_OBJECT ( des_test );
|