Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit e97d111

Browse files
committed
Assign _safeProvHandle when importing public keys.
1 parent baaa017 commit e97d111

File tree

2 files changed

+1
-6
lines changed

2 files changed

+1
-6
lines changed

src/System.Security.Cryptography.RSA/src/System/Security/Cryptography/RSACryptoServiceProvider.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,7 @@ public void ImportCspBlob(byte[] keyBlob)
308308
SafeProvHandle safeProvHandleTemp = SafeProvHandle.InvalidHandle;
309309
AcquireSafeProviderHandle(ref safeProvHandleTemp);
310310
CapiHelper.ImportKeyBlob(safeProvHandleTemp, (CspProviderFlags)0, keyBlob, ref _safeKeyHandle);
311+
_safeProvHandle = safeProvHandleTemp;
311312
}
312313
else
313314
{

src/System.Security.Cryptography.RSA/tests/SignVerify.cs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,6 @@ public static void ExpectSignature_SHA256_1024_Stream()
158158
}
159159

160160
[Fact]
161-
[ActiveIssue(1888, PlatformID.Windows)]
162161
[ActiveIssue(1964, PlatformID.AnyUnix)]
163162
public static void VerifySignature_SHA1_2048()
164163
{
@@ -202,7 +201,6 @@ public static void VerifySignature_SHA1_2048()
202201
}
203202

204203
[Fact]
205-
[ActiveIssue(1888, PlatformID.Windows)]
206204
[ActiveIssue(1964, PlatformID.AnyUnix)]
207205
public static void VerifySignature_SHA256_1024()
208206
{
@@ -230,7 +228,6 @@ public static void VerifySignature_SHA256_1024()
230228
}
231229

232230
[Fact]
233-
[ActiveIssue(1888, PlatformID.Windows)]
234231
[ActiveIssue(1964, PlatformID.AnyUnix)]
235232
public static void VerifySignature_SHA256_2048()
236233
{
@@ -494,7 +491,6 @@ public static void ExpectedHashSignature_SHA256_2048()
494491
}
495492

496493
[Fact]
497-
[ActiveIssue(1888, PlatformID.Windows)]
498494
[ActiveIssue(1964, PlatformID.AnyUnix)]
499495
public static void VerifyHashSignature_SHA1_2048()
500496
{
@@ -545,7 +541,6 @@ public static void VerifyHashSignature_SHA1_2048()
545541
}
546542

547543
[Fact]
548-
[ActiveIssue(1888, PlatformID.Windows)]
549544
[ActiveIssue(1964, PlatformID.AnyUnix)]
550545
public static void VerifyHashSignature_SHA256_1024()
551546
{
@@ -580,7 +575,6 @@ public static void VerifyHashSignature_SHA256_1024()
580575
}
581576

582577
[Fact]
583-
[ActiveIssue(1888, PlatformID.Windows)]
584578
[ActiveIssue(1964, PlatformID.AnyUnix)]
585579
public static void VerifyHashSignature_SHA256_2048()
586580
{

0 commit comments

Comments
 (0)