在Azure函数中配置访问控制允许标题 [英] Configuring Access-Control-Allow-Headers in Azure Functions

查看:60
本文介绍了在Azure函数中配置访问控制允许标题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个通过Azure函数构建的API,当在除Safari之外的所有浏览器中通过JavaScript调用时,该API都可以正常工作.在另一个问题中,看来我需要允许标有来源"的标头在CORS配置中.我在Azure门户中看到的唯一配置是允许来源.如何配置允许的标头?

I have an API built through Azure Functions that works when called through JavaScript in all browsers except for Safari. From another question, it appears I need to allow a header of "Origin" in the CORS configuration. The only configuration I see in the Azure portal is allowing origins. How do I configure allowed headers?

如果有关系,可以通过VS2017 Azure功能工具进行开发和发布.

If it matters, this is developed and published through VS2017 Azure function tools.

推荐答案

在Azure Functions中不允许配置标头,因为它允许所有标头.

Allowed headers are not configurable within Azure Functions as it allows all.

这篇关于在Azure函数中配置访问控制允许标题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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