Skip to content

Conversation

@ChadNedzlek
Copy link
Contributor

@ChadNedzlek ChadNedzlek commented Nov 5, 2024

ProtectedData only has allocating byte[] overloads, but in .NET 5+, Span overloads can avoid allocations.

Resolves #108734

ProtectedData only has allocating byte[] overloads,
but in .NET 5+, Span<byte> overloads can avoid allocations.
@ghost
Copy link

ghost commented Nov 5, 2024

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

@ghost
Copy link

ghost commented Nov 5, 2024

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

@danzuep
Copy link

danzuep commented Nov 5, 2024

ProtectedData only has allocating byte[] overloads, but in .NET 5+, Span overloads can avoid allocations.

Issue #109480 108734

Wrong issue link 🙂

ChadNedzlek and others added 9 commits November 5, 2024 13:08
…ystem/Security/Cryptography/ProtectedData.cs

Co-authored-by: Jeremy Barton <[email protected]>
…ystem/Security/Cryptography/ProtectedData.cs

Co-authored-by: Jeremy Barton <[email protected]>
…ystem/Security/Cryptography/ProtectedData.cs

Co-authored-by: Jeremy Barton <[email protected]>
…ystem/Security/Cryptography/ProtectedData.cs

Co-authored-by: Jeremy Barton <[email protected]>
…/SpanProtectedDataTests.cs

Co-authored-by: Jeremy Barton <[email protected]>
…ystem/Security/Cryptography/ProtectedData.cs

Co-authored-by: Jeremy Barton <[email protected]>
…ystem/Security/Cryptography/ProtectedData.cs

Co-authored-by: Jeremy Barton <[email protected]>
…ystem/Security/Cryptography/ProtectedData.cs

Co-authored-by: Jeremy Barton <[email protected]>
@bartonjs bartonjs merged commit 2f24ac9 into dotnet:main Nov 8, 2024
80 of 83 checks passed
@bartonjs bartonjs added this to the 10.0.0 milestone Nov 8, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Dec 8, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[API Proposal]: Add Span<byte> support to System.Security.Cryptography.ProtectedData

4 participants