Repository navigation
Fix SignCheck MSI/MSP/CAB/MSU signature verification on .NET Core - #5834
Merged
mmitche merged 3 commits intoApr 1, 2026
Merged
Conversation
ViktorHofer
force-pushed
the
port-signcheck-msi-cab-verification
branch
from
April 1, 2026 12:35
5c366ba to
3d7ac01
Compare
The default AuthentiCodeSecurityInfoProvider uses PEReader to extract Authenticode signatures, which only works for PE files (EXE/DLL). - MSI/MSP: Add OleStorageSecurityInfoProvider that reads the digital signature from the OLE structured storage \x05DigitalSignature stream. - CAB/MSU: Add CabSecurityInfoProvider that reads the PKCS#7 signature from the cabinet header's per-cabinet reserved area. This fixes 'Invalid number of sections declared in PE header' errors when SignCheck validates signed MSI/MSP/CAB/MSU files. Co-authored-by: Copilot <[email protected]>
ViktorHofer
force-pushed
the
port-signcheck-msi-cab-verification
branch
from
April 1, 2026 12:36
3d7ac01 to
e81a2b7
Compare
ViktorHofer
enabled auto-merge (squash)
April 1, 2026 13:10
akoeplinger
approved these changes
Apr 1, 2026
mmitche
approved these changes
Apr 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix SignCheck MSI/MSP/CAB/MSU signature verification on .NET Core
Problem
The default
AuthentiCodeSecurityInfoProviderusesPEReaderto extract Authenticode signatures, which only works for PE files (EXE/DLL). When SignCheck validates signed MSI, MSP, CAB, or MSU files, it fails with:Root Cause
\x05DigitalSignature), not in a PE header.Fix
Added format-specific
ISecurityInfoProviderimplementations:OleStorageSecurityInfoProvider- Reads the digital signature from the OLE structured storage\x05DigitalSignaturestream (for MSI/MSP).CabSecurityInfoProvider- Reads the PKCS#7 signature from the cabinet header's per-cabinet reserved area (for CAB/MSU).Each verifier now passes the appropriate provider to the
AuthentiCodeVerifierbase class.Upstream PR
Port of dotnet/arcade#16658