边缘扩展HTTP请求中的错误0x2efd [英] Error 0x2efd in Edge Extension HTTP Request

查看:139
本文介绍了边缘扩展HTTP请求中的错误0x2efd的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将Chrome扩展程序移植到Edge。 Chrome扩展程序运行正常,所有HTTP请求都按预期工作。当这些相同的请求在端口中触发时,我收到此错误:

I'm attempting to port a Chrome extension to Edge. The Chrome extension works fine, and all HTTP requests are working as expected. When these same requests fire in the port, I get this error:


XMLHttpRequest:网络错误0x2efd,由于错误无法完成操作00002efd。

XMLHttpRequest: Network Error 0x2efd, Could not complete the operation due to error 00002efd.

这个问题似乎出现在很多微软的东西上,包括Windows Phone 。也许这个扩展的问题有一个类似的答案,但我允许我的清单中的所有网址...

This issue seems to pop up for a lot of Microsoft stuff, including Windows Phone. Maybe there is a similar answer to my issue for this extension, but I'm permitting ALL URLs in my manifest...

这是请求:

$http.get(url)
    .then(function () {

    })
    .catch(function () {
        var args = arguments;
    });

我也尝试过jQuery方式:

I've also tried the jQuery way:

$.ajax({
    url: url,
    success: function () {

    },
    error: function () {
        var args = arguments;
    }
});

我无法分享确切的网址,因为它是我们业务架构的一部分,但Chrome扩展程序消耗它就好了。如果我直接在浏览器(Edge或Chrome)中打开URL,它会显示结果......我很茫然。我知道错误意味着请求无法连接,但为什么?我该如何解决?

I can't share the exact URL because it is part of our business architecture, but the Chrome extension consumes it just fine. If I open the URL directly in a browser (Edge or Chrome) it shows the result just fine... I'm at a loss. I know the error means the request can't connect, but why? And how do I fix it?

推荐答案

似乎是已知错误,截至2016-10-07尚未完全分类。

Seems to be a known bug that hasn't been fully triaged as of 2016-10-07.

另一个错误报告微软神秘地说这是设计为扩展不支持环回,并将其关闭。这肯定与Chrome模型不兼容。

In another bug report Microsoft mysteriously says "This is by design as extensions don’t support loopback" and closed it as such. That would certainly be an incompatibility with the Chrome model.

症状似乎是被Windows网络堆栈视为本地Intranet一部分的网站的连接被拒绝为侵略性XSS预防政策的一部分。

The symptom seems to be that connections to sites that are considered part of the Local Intranet by Windows network stack are denied as part of an aggressive XSS prevention policy.

在MS解决此问题之前,您无法在扩展方面做任何事情。如果有的话,扩展代码需要具有足够的特权来执行此操作,即使这会破坏其分区模型。

There is definitely nothing you can do on the extension side until this is resolved by MS. If anything, extension code needs to be privileged enough to do this, even if that breaks their compartmentalization model.

您可以进行一些环境更改。我将尝试本地Intranet区域的Internet选项,例如设置保护模式,禁用Internet区域,或者更可能以某种方式确保站点被视为Intranet。域名而不是IP地址也可能有助于欺骗Edge,它不是内联网。

It's possible that you can do some environment changes though. I would experiment with Internet Options for "Local intranet" zone, for example setting Protected Mode on, disabling that for Internet zone, or more likely somehow making sure the site isn't considered intranet. A domain name instead of an IP address may also help "fooling" Edge that it's not intranet.

这篇关于边缘扩展HTTP请求中的错误0x2efd的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆