Files
ipxe/src/config/defaults/efi.h

66 lines
1.3 KiB
C
Raw Normal View History

#ifndef CONFIG_DEFAULTS_EFI_H
#define CONFIG_DEFAULTS_EFI_H
/** @file
*
* Configuration defaults for EFI
*
*/
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
FILE_SECBOOT ( PERMITTED );
#define UACCESS_FLAT
#define IOMAP_VIRT
#define PCIAPI_EFI
#define DMAAPI_OP
#define CONSOLE_EFI
#define TIMER_EFI
#define UMALLOC_EFI
#define MEMMAP_NULL
#define SMBIOS_EFI
#define SANBOOT_EFI
#define BOFM_EFI
#define ENTROPY_EFITICK
#define ENTROPY_EFIRNG
#define TIME_EFI
#define REBOOT_EFI
#define ACPI_EFI
#define MPAPI_EFI
#define NAP_EFI
#define SERIAL_SPCR
#define USB_HCD_XHCI /* xHCI USB host controller */
#define USB_HCD_EHCI /* EHCI USB host controller */
#define USB_HCD_UHCI /* UHCI USB host controller */
#define USB_EFI /* Provide EFI_USB_IO_PROTOCOL interface */
#define USB_BLOCK /* USB block devices */
#define EFI_SETTINGS /* EFI variable settings */
[efi] Accept and trust CA certificates in the TlsCaCertificates variable UEFI's built-in HTTPS boot mechanism requires the trusted CA certificates to be provided via the TlsCaCertificates variable. (There is no equivalent of the iPXE cross-signing mechanism, so it is not possible for UEFI to automatically use public CA certificates.) Users who have configured UEFI HTTPS boot to use a custom root of trust (e.g. a private CA certificate) may find it useful to have iPXE automatically pick up and use this same root of trust, so that iPXE can seamlessly fetch files via HTTPS from the same servers that were trusted by UEFI HTTPS boot, in addition to servers that iPXE can validate through other means such as cross-signed certificates. Parse the TlsCaCertificates variable at startup, add any certificates to the certificate store, and mark these certificates as trusted. There are no access restrictions on modifying the TlsCaCertificates variable: anybody with access to write UEFI variables is permitted to change the root of trust. The UEFI security model assumes that anyone with access to run code prior to ExitBootServices() or with access to modify UEFI variables from within a loaded operating system is supposed to be able to change the system's root of trust for TLS. Any certificates parsed from TlsCaCertificates will show up in the output of "certstat", and may be discarded using "certfree" if unwanted. Support for parsing TlsCaCertificates is enabled by default in EFI builds, but may be disabled in config/general.h if needed. As with the ${trust} setting, the contents of the TlsCaCertificates variable will be ignored if iPXE has been compiled with an explicit root of trust by specifying TRUST=... on the build command line. Signed-off-by: Michael Brown <mcb30@ipxe.org>
2025-03-13 14:04:26 +00:00
#define CERTS_EFI /* EFI certificate sources */
#if defined ( __i386__ ) || defined ( __x86_64__ )
#define IOAPI_X86
#define ENTROPY_RDRAND
#define UNSAFE_STD /* Avoid setting direction flag */
#define FDT_NULL
#endif
#if defined ( __arm__ ) || defined ( __aarch64__ )
#define IOAPI_ARM
#define FDT_EFI
#endif
#if defined ( __loongarch__ )
#define IOAPI_LOONG64
#define FDT_EFI
#endif
#if defined ( __riscv )
#define IOAPI_RISCV
#define FDT_EFI
#endif
#endif /* CONFIG_DEFAULTS_EFI_H */