Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Conversation

carlossanlop
Copy link

@carlossanlop carlossanlop commented Oct 30, 2019

Approved API Proposal: https://github.com/dotnet/corefx/issues/41662

Description

We don't currently have a way to create an EventWaitHandle with a given ACL in .NET Core. We can modify the ACL, but it would be more secure to have the proper ACL on the object from the start.

Customer impact

Before this change, customers had to create an EventWaitHandle, then set its ACLs. This presents a few problems:

  • Potential security hole as event wait handles can be accessed between creation and modification.
  • Porting difficulties as there isn't a 1-1 API replacement

This change addresses those problems by adding a new extension method that allows creating an EventWaitHandle and ensuring the provided ACLs are set during creation.

This change is expected to be backported to 3.1.

@carlossanlop carlossanlop added this to the 3.1 milestone Oct 30, 2019
@carlossanlop carlossanlop self-assigned this Oct 30, 2019
@maryamariyan maryamariyan requested a review from kouvel November 1, 2019 16:38
@carlossanlop carlossanlop marked this pull request as ready for review November 1, 2019 18:56
@danmoseley
Copy link
Member

BTW, unlike System.IO.FileSystem.AccessControl, System.Threading.AccessControl package is not in netcoreapp. Therefore if this was backported to servicing (which I was assuming would not happen anyway, since today's the last day), it would presumably need package authoring as well .cc @ericstj

Copy link
Member

@stephentoub stephentoub left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other than my test comments, LGTM.

Copy link
Member

@JeremyKuhne JeremyKuhne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing to add beyond Stephen's nits. Looks good.

carlossanlop and others added 23 commits November 7, 2019 16:30
…all Windows platforms, ensure same exceptions are thrown in both netcore and netfx.
…ly, merge methods, remove an unnecessary Debug.Assert
@carlossanlop carlossanlop merged commit 14b0893 into dotnet:master Nov 8, 2019
@carlossanlop carlossanlop deleted the EventWaitHandleAcl branch November 8, 2019 22:39
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.

6 participants