- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我想知道浏览器如何处理包括 在内的 CORS 预检响应变化:起源 和 Access-Control-Max-Age 标题。
本声明来自 https://www.w3.org/TR/cors/
Resources that wish to enable themselves to be shared with multiple Origins but do not respond uniformly with "*" must in practice generate the Access-Control-Allow-Origin header dynamically in response to every request they wish to allow. As a consequence, authors of such resources should send a Vary: Origin HTTP header or provide other appropriate control directives to prevent caching of such responses, which may be inaccurate if re-used across-origins
最佳答案
根据规范要求 Vary: Origin
不会影响 CORS-preflight cache 的行为.
Is it valid if both of the headers exist in a preflight response?
Vary
header 存在,它对 CORS 预检缓存没有影响。
How browsers handle Preflight response if the response includes both that headers
Vary
header 并且只使用
Access-Control-Max-Age
的值标题。
my understand is Vary: Origin will tell browsers won't cache preflight result
Vary
影响的要求,甚至是间接要求。响应头。
Let max-age be the result of extracting header list values given
Access-Control-Max-Age
and response’s header list.
Vary
设置 max-age 之前的 header 值。
Vary
在决定是否填充 CORS 预检缓存时,浏览器不得使用
Vary
做的时候。
Vary
在处理 CORS 预检缓存时,该浏览器将不符合 CORS 预检缓存的规范要求。
关于CORS 预检响应包括变化 :Origin and Access-Control-Max-Age?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42848208/
我在 swagger.mydomain.com 上运行了 swagger (docker: swaggerapi/swagger-ui),并为在 a.mydomain.com 和 b.mydomain
在我的应用程序中,进行以下两步调用时,我在第二个 AJAX 调用中收到预检错误: $.ajax({ type:'POST', url:'https://podio.com/oauth/
我们在 Istio 中使用 Kubernetes 并配置了一个虚拟服务: http: - match: - uri: prefix: /api rewrite:
我有一个 Firebase Callable Cloud Function我在浏览器的 javascript 应用程序中调用它。 因为请求主机是 ...cloudfunctions.net 而不是我的
这个问题在这里已经有了答案: XMLHttpRequest cannot load XXX No 'Access-Control-Allow-Origin' header (11 个答案) 关闭 3
我目前对如何“选择”或选择在请求之前执行 Angular 的(jquery)预检 OPTIONS 调用感到困惑。 我有一个正常的 RESTful api 调用 (api.domain.co) 我已在主
我用 C# 创建了一个 WebService。所有 GET 方法都可以正常工作。 现在我需要提供一些 POST 方法。通过 C# 调用它时,它可以正常工作。然后我尝试用 JavaScript 编写一个
我正在尝试向我的 REST API 发出 POST 请求。这是代码片段(使用 AngularJS): $http({ method: 'POST',
我正在使用 rack-cors 中间件从站点向我的 Rails 应用程序发出跨域请求(尽管我不认为这个问题特定于 rack-cors)。当我用 Firebug 检查控制台输出时,我注意到只有一个请求发
我正在使用 rack-cors 中间件从站点向我的 Rails 应用程序发出跨域请求(尽管我不认为这个问题特定于 rack-cors)。当我用 Firebug 检查控制台输出时,我注意到只有一个请求发
您好,我正在尝试在 Debian 8 Jessie 中设置 DC/OS,我使用 ssh key 建立了 ssh 连接,我能够在没有密码的情况下登录到所有主机和代理(他们正在运行 CentOS 7)。奇
我正在制作一个简单的网络应用程序,它与我无法控制的服务器进行通信。 起初我配置了一个自定义的 $resource GET 请求并且工作正常。现在我需要做一个 POST 请求来从同一台服务器请求一些信息
我正在构建一个带有 Spring Boot 后端的 Angular 2 应用程序。几天来,我一直在尝试解决 CORS 预检的问题。根据这个topic ,它应该像这样与 CORS 过滤器一起工作: @C
我需要将 CORS 过滤器添加到我的 Spring Boot Web 应用程序中。 我添加了如下文档中所述的 CORS 映射 http://docs.spring.io/spring/docs/cur
我正在尝试对我部署的用于检索 JSON 数据的 Azure 函数进行 POST。我收到 CORS 错误。 有权从来源“http://localhost:3000”在“{API URL}”获取数据' 已
我有一个 Angular 应用程序和 Node 后端,所有请求都正常工作,但是当我尝试使用 get 请求并且在其中重定向请求时,会发生“CORS 预检 channel 未成功”此错误。 .当我在 po
我正在尝试获取名为 X-Total-Pages 的自定义 header 当我做GET时 Ajax 调用。调用从客户端发送到 API。API 允许使用以下 header : Access-Control
我正在尝试在 OS X 10.11.3 上运行 Plone 统一安装程序(适用于 4.3.9)不 使用 --without-ssl 选项,并且我收到以下错误: Unable to find libss
我的架构中有三个应用程序。 它们在同一台服务器上,但具有不同的端口号。 A - Token Application (port 4444) - Asp.net WebApi B - API Appli
所以我有一个不寻常的问题,我不确定如何进行调试。我有一个 angular 4 应用程序,它在服务器端使用 cakephp。 在我的应用程序中,我可以访问许多不同的屏幕,除了一个并且它只是 Firefo
我是一名优秀的程序员,十分优秀!