Skip to content

Commit a893a72

Browse files
committed
Merge remote-tracking branch 'upstream/develop' into mstest4
2 parents 9d7a0b3 + bf976d5 commit a893a72

File tree

5 files changed

+15
-10
lines changed

5 files changed

+15
-10
lines changed

.github/workflows/build.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848
test/Renci.SshNet.IntegrationTests/
4949
5050
- name: Archive Coverlet Results
51-
uses: actions/upload-artifact@v4
51+
uses: actions/upload-artifact@v5
5252
with:
5353
name: Coverlet Results Linux
5454
path: coverlet
@@ -74,7 +74,7 @@ jobs:
7474
run: dotnet pack
7575

7676
- name: Archive NuGet Package
77-
uses: actions/upload-artifact@v4
77+
uses: actions/upload-artifact@v5
7878
with:
7979
name: NuGet Package
8080
path: src/Renci.SshNet/bin/Release/*.*nupkg
@@ -140,7 +140,7 @@ jobs:
140140
test\Renci.SshNet.IntegrationTests\
141141

142142
- name: Archive Coverlet Results
143-
uses: actions/upload-artifact@v4
143+
uses: actions/upload-artifact@v5
144144
with:
145145
name: Coverlet Results Windows .NET Framework
146146
path: coverlet
@@ -182,7 +182,7 @@ jobs:
182182
test\Renci.SshNet.IntegrationTests\
183183

184184
- name: Archive Coverlet Results
185-
uses: actions/upload-artifact@v4
185+
uses: actions/upload-artifact@v5
186186
with:
187187
name: Coverlet Results Windows .NET
188188
path: coverlet
@@ -200,7 +200,7 @@ jobs:
200200
- Windows-Integration-Tests-Net
201201
steps:
202202
- name: Download NuGet Package
203-
uses: actions/download-artifact@v5
203+
uses: actions/download-artifact@v6
204204
with:
205205
name: NuGet Package
206206

@@ -229,7 +229,7 @@ jobs:
229229
- Windows-Integration-Tests-Net
230230
steps:
231231
- name: Download NuGet Package
232-
uses: actions/download-artifact@v5
232+
uses: actions/download-artifact@v6
233233
with:
234234
name: NuGet Package
235235

Directory.Packages.props

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
<PackageVersion Include="GitHubActionsTestLogger" Version="2.4.1" />
1212
<PackageVersion Include="Meziantou.Analyzer" Version="2.0.220" />
1313
<!-- Should stay on LTS .NET releases. -->
14+
<PackageVersion Include="Microsoft.Bcl.Cryptography" Version="10.0.0" />
1415
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="8.0.3" />
1516
<PackageVersion Include="Microsoft.Extensions.Logging.Console" Version="9.0.9" />
1617
<PackageVersion Include="MSTest" Version="4.0.2" />

src/Renci.SshNet/Renci.SshNet.csproj

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,11 @@
4949
</PackageReference>
5050
</ItemGroup>
5151

52-
<ItemGroup Condition=" !$([MSBuild]::IsTargetFrameworkCompatible('$(TargetFramework)', 'net8.0')) ">
52+
<ItemGroup Condition=" '$(TargetFramework)' == 'net462' ">
53+
<PackageReference Include="Microsoft.Bcl.Cryptography" />
54+
</ItemGroup>
55+
56+
<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' ">
5357
<PackageReference Include="System.Formats.Asn1" />
5458
</ItemGroup>
5559

src/Renci.SshNet/Security/Cryptography/Ciphers/AesGcmCipher.BclImpl.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#if NET
1+
#if !NETSTANDARD
22
using System;
33
using System.Security.Cryptography;
44

src/Renci.SshNet/Security/Cryptography/Ciphers/AesGcmCipher.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ internal sealed partial class AesGcmCipher : SymmetricCipher, IDisposable
1515
private const int TagSizeInBytes = 16;
1616
private readonly byte[] _iv;
1717
private readonly int _aadLength;
18-
#if NET
18+
#if !NETSTANDARD
1919
private readonly Impl _impl;
2020
#else
2121
private readonly BouncyCastleImpl _impl;
@@ -62,7 +62,7 @@ public AesGcmCipher(byte[] key, byte[] iv, int aadLength)
6262
// SSH AES-GCM requires a 12-octet Initial IV
6363
_iv = iv.Take(12);
6464
_aadLength = aadLength;
65-
#if NET
65+
#if !NETSTANDARD
6666
if (System.Security.Cryptography.AesGcm.IsSupported)
6767
{
6868
_impl = new BclImpl(key, _iv);

0 commit comments

Comments
 (0)