-
Notifications
You must be signed in to change notification settings - Fork 859
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove embedded bouncy castle from core. Separate CloudFrontSigners and EC2 DecryptPassword to extension packages. #3435
Remove embedded bouncy castle from core. Separate CloudFrontSigners and EC2 DecryptPassword to extension packages. #3435
Conversation
75141c6
to
60d5ee5
Compare
...WSSDK.Extensions.CloudFront.Signers/AWSSDK.Extensions.CloudFront.Signers.NetFramework.csproj
Outdated
Show resolved
Hide resolved
extensions/src/AWSSDK.Extensions.CrtIntegration/AWSSDK.Extensions.CrtIntegration.nuspec
Outdated
Show resolved
Hide resolved
...AWSSDK.Extensions.CloudFront.Signers/AWSSDK.Extensions.CloudFront.Signers.NetStandard.csproj
Outdated
Show resolved
Hide resolved
extensions/src/AWSSDK.Extensions.EC2.DecryptPassword/AWSSDK.Extensions.EC2.DecryptPassword.sln
Outdated
Show resolved
Hide resolved
extensions/src/AWSSDK.Extensions.EC2.DecryptPassword/GetPasswordDataResponseExtensions.cs
Outdated
Show resolved
Hide resolved
extensions/src/AWSSDK.Extensions.CloudFront.Signers/AWSSDK.Extensions.CloudFront.Signers.nuspec
Outdated
Show resolved
Hide resolved
If we're removing the embedded source, should we also update the notice files? |
57b42f5
to
237e7a6
Compare
], | ||
"type": "patch", | ||
"type": "minor", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think type
here is ignored by our build system (since there's an overrideVersion
as well).
Also, is the -preview
suffix required? For example, see the config we use for the first preview: https://github.com/aws/aws-sdk-net/blob/15a866102abf3763fa4c180c936a248d3b40c45b/generator/.DevConfigs/525da348-b9e8-4f4d-9dc7-47b2ee7f4716.json
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The preview actually failed the E2E test I ran last night, so I will remove it
extensions/test/EC2.DecryptPasswordTests/EC2.DecryptPassword.NetStandard.csproj
Outdated
Show resolved
Hide resolved
<GenerateAssemblyFileVersionAttribute>false</GenerateAssemblyFileVersionAttribute> | ||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors> | ||
</PropertyGroup> | ||
<ItemGroup> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Project file should be marked as trimmable for the .NET 8 target.
<PropertyGroup Condition="'$(TargetFramework)' == 'net8.0'">
<IsTrimmable>true</IsTrimmable>
</PropertyGroup>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good call, added.
<GenerateAssemblyFileVersionAttribute>false</GenerateAssemblyFileVersionAttribute> | ||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors> | ||
</PropertyGroup> | ||
<ItemGroup> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Project file should be marked as trimmable for the .NET 8 target.
<PropertyGroup Condition="'$(TargetFramework)' == 'net8.0'">
<IsTrimmable>true</IsTrimmable>
</PropertyGroup>
<dependency id="AWSSDK.CloudFront" version="4.0.1.0-preview" /> | ||
<dependency id="BouncyCastle.Cryptography" version="2.4.0" /> | ||
</group> | ||
</dependencies> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are missing the dependency groups for .NET Core 3.1 and .NET 8.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm I tested the nuget package locally and it worked (for net 8), and given that the CrtIntegration
nuspec file doesn't have a target for netcore31 and net 8, I don't think I need one here, unless the CrtIntegration
nuspec is doing something different.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wasn't sure, and looks like the service nuspec's do this as well so I added them in the latest revision
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assumed it worked by resolving to use the .NET Standard 2.0 version of the assembly.
<file src=".\bin\Release\net472\AWSSDK.Extensions.CloudFront.Signers.pdb" target="lib\net472" /> | ||
|
||
<file src=".\bin\Release\netstandard2.0\AWSSDK.Extensions.CloudFront.Signers.dll" target="lib\netstandard2.0"/> | ||
<file src=".\bin\Release\netstandard2.0\AWSSDK.Extensions.CloudFront.Signers.pdb" target="lib\netstandard2.0"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to add the .NET Core 3.1 and .NET 8 files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will add these
<tags>AWS Amazon aws-sdk-v4</tags> | ||
<icon>images\AWSLogo.png</icon> | ||
<dependencies> | ||
<group targetFramework="net472"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing .NET Core 3.1 and .NET 8 group dependencies.
<file src=".\bin\Release\net472\AWSSDK.Extensions.EC2.DecryptPassword.dll" target="lib\net472" /> | ||
<file src=".\bin\Release\net472\AWSSDK.Extensions.EC2.DecryptPassword.pdb" target="lib\net472" /> | ||
|
||
<file src=".\bin\Release\netstandard2.0\AWSSDK.Extensions.EC2.DecryptPassword.dll" target="lib\netstandard2.0"/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add the .NET Core 3.1 and .NET 8 files.
@@ -10,29 +10,6 @@ purpose, commercial or non-commercial, and by any means. | |||
|
|||
---------------- | |||
|
|||
** Parsing PEM files from Bouncy Castle |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need add a new entry for BouncyCastle NuGet package. Like we recently did for the new System.* NuGet packages we added for V4. https://github.com/aws/aws-sdk-net/blob/v4-development/Notice.txt#L127
@@ -10,34 +10,6 @@ purpose, commercial or non-commercial, and by any means. | |||
|
|||
---------------- | |||
|
|||
** Parsing PEM files from Bouncy Castle |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need add a new entry for BouncyCastle NuGet package. Like we recently did for the new System.* NuGet packages we added for V4. https://github.com/aws/aws-sdk-net/blob/v4-development/Notice.txt#L127
</dependencies> | ||
|
||
</metadata> | ||
<files> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add the documentation xml files so VS intellisense can use them.
</dependencies> | ||
|
||
</metadata> | ||
<files> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add the documentation xml files so VS intellisense can use them.
…ont signers and ec2 decrypt password to extension packages to take a dependency on BouncyCastle.Cryptography
906f8c6
to
65d9228
Compare
65d9228
to
362858a
Compare
Description
This PR removes the embedded bouncy castle source copy in the third party namespace. It refactors CloudFrontSigners to separate extension packages and EC2 DecryptPassword as well. There was one other occurrence where Third Party bouncy castle was used in SNS and that has been refactored as well.
Revision 2
Added the test mentioned in #3221 and verified it worked. Made some logic change to accommodate for this test. Addressed PR feedback.
Motivation and Context
Allows us to take a dependency on Portable.Bouncy castle in the extension packages and receive updates. Removes tech debt of having a source copy in core.
Testing
E2E tests pass
Screenshots (if appropriate)
Types of changes
Checklist
License