Skip to content

Commit 19ccadd

Browse files
committed
fix(Update): Make the signature checker less restrictive
1 parent 44ba705 commit 19ccadd

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

SoundSwitch/Framework/Updater/SignatureChecker.cs

+1-12
Original file line numberDiff line numberDiff line change
@@ -12,32 +12,21 @@
1212
* GNU General Public License for more details.
1313
********************************************************************/
1414

15-
using System;
16-
using System.Linq;
17-
using System.Security.Cryptography.X509Certificates;
1815
using AuthenticodeExaminer;
1916

2017
namespace SoundSwitch.Framework.Updater
2118
{
2219
public static class SignatureChecker
2320
{
24-
private static readonly string _certumSubject = "[email protected], CN=\"Open Source Developer, Antoine Aflalo\", O=Open Source Developer, S=Quebec, C=CA";
25-
2621
/// <summary>
2722
/// Does the given file have the right signature
2823
/// </summary>
2924
/// <param name="filename"></param>
3025
/// <returns></returns>
3126
public static bool IsValid(string filename)
32-
{
33-
return IsCertumSigned(filename);
34-
}
35-
36-
private static bool IsCertumSigned(string filename)
3727
{
3828
var inspector = new FileInspector(filename);
39-
return inspector.Validate() == SignatureCheckResult.Valid
40-
&& inspector.GetSignatures().FirstOrDefault(signature => signature.SigningCertificate.Subject == _certumSubject) != null;
29+
return inspector.Validate() == SignatureCheckResult.Valid;
4130
}
4231
}
4332
}

0 commit comments

Comments
 (0)