security_policy: fix a problem with the UEFI confusion over security failure
security_policy: fix a problem with the UEFI confusion over security failure

The UEFI spec is confused (and has changed with later revisions) over whether
EFI_ACCESS_DENIED or EFI_SECURITY_VIOLATION should be returned for a signature
verification failure and subsequent refusal to execute.  Originally
security_policy returned EFI_SECURITY_VIOLATION as required by the latest
Errata C.  However this isn't correct on some platforms, so cache the security
failure return and return the cached value in the event that the MOK checks
fail.

Signed-off-by: James Bottomley <1acebbdca565c7b6b638bdc23b58b5610d1a56b8@Parallels.com>

marineam/efitools,marineam/efitools,mjg59/efitools,mjg59/efitools,mjg59/efitools,msekletar/efitools,msekletar/efitools,marineam/efitools,msekletar/efitools,mjg59/efitools,msekletar/efitools,marineam/efitools