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

Duplicate the access token passed to WindowsIdentity.RunImpersonated (#30346)#30372

Closed
kouvel wants to merge 1 commit intodotnet:release/2.1from
kouvel:ImpersonateFixRel
Closed

Duplicate the access token passed to WindowsIdentity.RunImpersonated (#30346)#30372
kouvel wants to merge 1 commit intodotnet:release/2.1from
kouvel:ImpersonateFixRel

Conversation

@kouvel
Copy link

@kouvel kouvel commented Jun 13, 2018

So that callbacks for async work initiated while impersonated may continue to impersonate even after the original access token had been disposed.

Port of #30346 to release/2.1
Fixes https://github.com/dotnet/corefx/issues/30275

…30346)

So that callbacks for async work initiated while impersonated may continue to impersonate even after the original access token had been disposed.

Port of #30346 to release/2.1
Fixes https://github.com/dotnet/corefx/issues/30275

* Small fix

* Address feedback

* Change to use ref counting, remove assert (no null check on access token parameter)

* Manual add/release
@kouvel kouvel added this to the 2.1.x milestone Jun 13, 2018
@kouvel kouvel self-assigned this Jun 13, 2018
@kouvel kouvel requested a review from stephentoub June 13, 2018 22:12
@kouvel
Copy link
Author

kouvel commented Jun 13, 2018

I'd like to make another change first

@kouvel kouvel closed this Jun 13, 2018
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.

1 participant