Skip to content

Commit 65be92a

Browse files
RTSDK-10607. C# Provider fails to run with RRG package RTSDK 2.4.0.L1 using .NET 8.0
1 parent 8c51960 commit 65be92a

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

CSharp/Eta/Src/Core/Core.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@
3434

3535
<ItemGroup>
3636
<PackageReference Include="K4os.Compression.LZ4" Version="1.3.8" />
37-
<PackageReference Include="Microsoft.Bcl.Cryptography" Version="10.0.3" />
3837
</ItemGroup>
3938

4039
<ItemGroup>

CSharp/Eta/Src/Core/Transport/transport/ServerImpl.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,11 @@ public TransportReturnCode Bind(BindOptions options, out Error error)
327327
options.BindEncryptionOpts.ServerPrivateKey);
328328

329329
/* This is workaround for SChannel on Windows as persisted store is required */
330+
#if NET10_0_OR_GREATER
330331
ServerCertificate = X509CertificateLoader.LoadPkcs12(serverCertificate.Export(X509ContentType.Pkcs12), null);
332+
#else
333+
ServerCertificate = new X509Certificate2(serverCertificate.Export(X509ContentType.Pkcs12));
334+
#endif
331335
}
332336
catch (Exception ex)
333337
{

0 commit comments

Comments
 (0)