# This class contains the part of coreos-efi-secureboot.bbclass that shouldn't
# be included globally, but only on the recipes that need to sign binary

# Normaly, coreos-efi-secureboot should be ihnerited globally, but we 
# ihnerit it again here to be sure that it's included
inherit coreos-efi-secureboot

coreos_efi_secureboot_sign_app() {
    # Helper function to sign an UEFI binary in place
    sbsign --key "${COREOS_EFI_SECUREBOOT_KEYDIR}/db.key" --cert "${COREOS_EFI_SECUREBOOT_KEYDIR}/db.crt" "$1" --output "$1"
}

