51 lines
1.8 KiB
C
51 lines
1.8 KiB
C
/*
|
|
* VAS_EBOOT -- GRand Unified Bootloader
|
|
* Copyright (C) 2020 IBM Corporation
|
|
* Copyright (C) 2024 Free Software Foundation, Inc.
|
|
*
|
|
* VAS_EBOOT 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 3 of the License, or
|
|
* (at your option) any later version.
|
|
*
|
|
* VAS_EBOOT 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 VAS_EBOOT. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
#include <VasEBoot/test.h>
|
|
#include <VasEBoot/dl.h>
|
|
#include "asn1_test.h"
|
|
|
|
/*
|
|
* libtasn1 tests - from which this is derived - are provided under GPL3+.
|
|
*/
|
|
VAS_EBOOT_MOD_LICENSE ("GPLv3+");
|
|
|
|
static void
|
|
asn1_test (void)
|
|
{
|
|
VasEBoot_test_assert (test_CVE_2018_1000654 () == 0, "CVE-2018-1000654 test failed");
|
|
|
|
VasEBoot_test_assert (test_object_id_encoding () == 0, "ASN.1 object ID encoding test failed");
|
|
|
|
VasEBoot_test_assert (test_object_id_decoding () == 0, "ASN.1 object ID decoding test failed");
|
|
|
|
VasEBoot_test_assert (test_octet_string () == 0, "ASN.1 octet string test failed");
|
|
|
|
VasEBoot_test_assert (test_overflow () == 0, "ASN.1 overflow test failed");
|
|
|
|
VasEBoot_test_assert (test_reproducers () == 0, "ASN.1 reproducers test failed");
|
|
|
|
VasEBoot_test_assert (test_simple () == 0, "ASN.1 simple test failed");
|
|
|
|
VasEBoot_test_assert (test_strings () == 0, "ASN.1 strings test fail" );
|
|
}
|
|
|
|
/* Register asn1_test method as a functional test. */
|
|
VAS_EBOOT_FUNCTIONAL_TEST (asn1_test, asn1_test);
|