Use DUPLICATE_SAME_ACCESS to duplicate privileges
When launching a process with admin rights we can't duplicate the process handle with dwDesiredAccess == PROCESS_QUERY_INFORMATION. But we don't need to - we just need the same rights we have to the original handle. So we should instead set dwOptions to DUPLICATE_SAME_ACCESS. This is an update to correct the flaw added in crrev.com/c/1155498 Bug: 871522 Change-Id: Ib5e526c1a1dfef07e6bb5e6d4d64e12c2d4c3eed Reviewed-on: https://chromium-review.googlesource.com/1173499Reviewed-by:Nick Carter <nick@chromium.org> Reviewed-by:
Robert Liao <robliao@chromium.org> Commit-Queue: Bruce Dawson <brucedawson@chromium.org> Cr-Commit-Position: refs/heads/master@{#583000}
Showing
Please register or sign in to comment