MicrosoftEdge / MicrosoftEdge/WebView2Feedback

Initialization Exception when switching user context

Open
#3,831 4 comments 1 reaction 2 assignees View on GitHub

@srwei is already working on this.

Since Nov 8, 2023.

bug tracked
Dominant language
PowerShell
Stars
526
Forks
67
PR merge metrics
No merged PRs in 30d

Description

Description
When running our application as a non-admin user and then switching to an admin user (via process start, runas), WebView2 throws COMException (0x80010108): The object invoked has disconnected from its clients (RPC_E_DISCONNECTED) while initializing on the new process.
When doing the same from the admin user it works fine.

Version
SDK: 1.0.1418.22 / 1.0.2045.28
Runtime: 117.0.2045.43
Framework: WPF
OS: Win10

Regression
Not sure, we just noticed it.

Repro Steps

  1. Create a local windows user without admin permissions
  2. Create "C:\test\test.html" and put anything in there for webview to display, or change the path in MainWindow.xaml
  3. Build and run the WebVeiw2Test.exe from the attached project with the non-admin user
  4. Press the button (this starts another instance of the .exe but with runas to have admin rights)
    SHOULD: webview2 loads and displays normally
    IS: webview2 throws an exception

Test Project:
WebView2Test.zip

AB#46946334

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.