Skip to content

Mod hash func to exclude SB key - #215

Open
GybiBite wants to merge 1 commit into
corpnewt:masterfrom
GybiBite:master
Open

Mod hash func to exclude SB key#215
GybiBite wants to merge 1 commit into
corpnewt:masterfrom
GybiBite:master

Conversation

@GybiBite

@GybiBite GybiBite commented Sep 5, 2026

Copy link
Copy Markdown

Resolves #214

When OpenCore.efi was signed by the user for secure boot, the MD5 hash of the file would change. This new hash function detects EFI files, checks for a signature, and strips the keys if any were appended before calculating the hash. This retains all old hash values, and shouldn't change any existing functionality. This also excludes the nested finish(f,path) function, as the finally: block is subjectively cleaner. Regardless of how the function exits, the finally: block is called.

Previous version didn't account for potential user-added secure boot key(s), new function strips any keys if present before calculating function. This does not affect hash calculation of other files.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Signed OpenCore.efi fails version auto-detection due to MD5 hash mismatch

1 participant