Skip to content

Commit c5b8c19

Browse files
authored
Remove Win11 version check (#238)
2 parents 91290a9 + 2f0dc5c commit c5b8c19

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/AzureSign.Core/AuthenticodeKeyVaultSigner.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ public class AuthenticodeKeyVaultSigner : IDisposable
2020
private readonly MemoryCertificateStore _certificateStore;
2121
private readonly X509Chain _chain;
2222
private readonly SignCallback _signCallback;
23-
private static readonly Version _win11Version = new(10, 0, 22000);
2423

2524

2625
/// <summary>
@@ -101,16 +100,12 @@ static char[] NullTerminate(ReadOnlySpan<char> str)
101100

102101
if (appendSignature)
103102
{
104-
if (Environment.OSVersion.Version < _win11Version)
105-
{
106-
// SignerSignEx3 silently succeeds with append on Windows 10 but does not actually append, so throw an error if we are not on Windows 11 or later.
107-
throw new PlatformNotSupportedException("Appending signatures requires Windows 11 or later.");
108-
}
109103
if (_timeStampConfiguration.Type == TimeStampType.Authenticode)
110104
{
111105
// E_INVALIDARG is expected from SignerSignEx3, no need to override this error, log warning for troubleshooting
112106
logger?.LogWarning("If you set the dwTimestampFlags parameter to SIGNER_TIMESTAMP_AUTHENTICODE, you cannot set the dwFlags parameter to SIG_APPEND.");
113107
}
108+
114109
flags |= SignerSignEx3Flags.SIG_APPEND;
115110
}
116111

0 commit comments

Comments
 (0)