MicrosoftEdge / MicrosoftEdge/WebView2Feedback

How to disable download protection

Open
#1,902 9 comments 2 reactions 1 assignee View on GitHub

@champnic is already working on this.

Since Nov 5, 2021.

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

Description

Hi there,

I'm using WPF Webview2 to render webpages. I would like to disable download protection feature in order to not show warning dialog when I download a harmful file (.eml file in my case).
I tried to add some additional browser arguments as bellow but it didn't work, the warning dialog is still displayed:
--disable-features=msSmartScreenProtection
--safebrowsing-disable-download-protection
--safebrowsing-disable-extension-blacklist

var coreViewOptions = new CoreWebView2EnvironmentOptions(
                "--disable-features=msSmartScreenProtection --safebrowsing-disable-download-protection --safebrowsing-disable-extension-blacklist", "de");

var webView2Environment = await CoreWebView2Environment.CreateAsync(null, null, coreViewOptions);

await webView.EnsureCoreWebView2Async(webView2Environment);

image

Are there any missing arguments? Or
Are there any other ways to disable download protection?

Thanks,
Huy

AB#36984714

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.