dotnet / runtime

.NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps.
https://docs.microsoft.com/dotnet/core/
MIT License
14.58k stars 4.55k forks source link

Unify SECURITY_ATTRIBUTES code from FileSystemAclExtensions and SafeFileHandle #64017

Open carlossanlop opened 2 years ago

carlossanlop commented 2 years ago

Follow up of the PR comment where this was suggested: https://github.com/dotnet/runtime/pull/61297#discussion_r744893438 (but wait for that PR to be merged).

Unify these two methods:

https://github.com/dotnet/runtime/blob/57bfe474518ab5b7cfe6bf7424a79ce3af9d6657/src/libraries/System.IO.FileSystem.AccessControl/src/System/IO/FileSystemAclExtensions.cs#L294-L308

https://github.com/dotnet/runtime/blob/39ece73bd08b1bcea0b9447cf34690bb1b41ba0a/src/libraries/System.Private.CoreLib/src/Microsoft/Win32/SafeHandles/SafeFileHandle.Windows.cs#L52-L102

Since they are both very similar.

cc @adamsitnik @Jozkee

ghost commented 2 years ago

Tagging subscribers to this area: @dotnet/area-system-io See info in area-owners.md if you want to be subscribed.

Issue Details
Follow up of the PR comment where this was suggested: https://github.com/dotnet/runtime/pull/61297#discussion_r744893438 Unify these two methods: https://github.com/dotnet/runtime/blob/57bfe474518ab5b7cfe6bf7424a79ce3af9d6657/src/libraries/System.IO.FileSystem.AccessControl/src/System/IO/FileSystemAclExtensions.cs#L294-L308 https://github.com/dotnet/runtime/blob/39ece73bd08b1bcea0b9447cf34690bb1b41ba0a/src/libraries/System.Private.CoreLib/src/Microsoft/Win32/SafeHandles/SafeFileHandle.Windows.cs#L52-L102 Since they are both very similar. cc @adamsitnik @Jozkee
Author: carlossanlop
Assignees: -
Labels: `area-System.IO`
Milestone: Future
deeprobin commented 9 months ago

@carlossanlop I could have a look at it. Gladly assign me.

carlossanlop commented 9 months ago

Thank you for offering your help, @deeprobin ! I assigned this issue to you.