Lync Service不允许来自此来源的跨域请求 [英] Lync Service does not allow a cross domain request from this origin
问题描述
我正在使用ucwa skype api.我已经从ucwa.skype.com下载了示例.在运行示例时,我需要登录到我的Skype商业帐户.它给了我下面的错误.
I am using ucwa skype api. I have downloaded sample from ucwa.skype.com. while running the sample I need to login to my skype for business account. It gives me the below error.
jquery-1.6.2.min.js:17 GET http://lyncdiscoverinternal.ge.com/xframe 净:: ERR_NAME_NOT_RESOLVED(匿名函数)@ jquery-1.6.2.min.js:17domManip @ jquery-1.6.2.min.js:17domManip @ jquery.tmpl.min.js:1追加@ jquery-1.6.2.min.js:17html @ jquery-1.6.2.min.js:17Transport.obj.injectFrame @ Transport.js:516startAutoDiscover @ AutoDiscovery.js:51AutoDiscovery.obj.startDiscovery @ AutoDiscovery.js:141beginDiscovery @ Index.js:91processAuthClick @ Index.js:101(匿名函数)@ Index.js:163handle @ jquery-1.6.2.min.js:17k @ jquery-1.6.2.min.js:16 Transport.js:479 在超时(10000)内找不到帧位置: http://lyncdiscoverinternal.ge.com/xframe XFrame.js:143 GET http://lyncdiscover.ge.com/xframe 403(禁止访问)sendRequest @ XFrame.js:143(匿名函数)@ XFrame.js:207 scriptInjector.js:193 sI:WIDGET_CONTENT_MESSAGE消息内 侦听器:MessageEvent scriptInjector.js:194 MessageEvent scriptInjector.js:193 sI:WIDGET_CONTENT_MESSAGE消息内 侦听器:MessageEvent scriptInjector.js:194 MessageEvent Transport.js:186服务不允许来自的跨域请求 这个起源. AutoDiscovery.js:93的自动发现失败 内部/外部位置contentScript.js:234 CS: onRequestListener(Arguments [3])contentScript.js:234 cs: onRequestListener(Arguments [3])
jquery-1.6.2.min.js:17 GET http://lyncdiscoverinternal.ge.com/xframe net::ERR_NAME_NOT_RESOLVED(anonymous function) @ jquery-1.6.2.min.js:17domManip @ jquery-1.6.2.min.js:17domManip @ jquery.tmpl.min.js:1append @ jquery-1.6.2.min.js:17html @ jquery-1.6.2.min.js:17Transport.obj.injectFrame @ Transport.js:516startAutoDiscover @ AutoDiscovery.js:51AutoDiscovery.obj.startDiscovery @ AutoDiscovery.js:141beginDiscovery @ Index.js:91processAuthClick @ Index.js:101(anonymous function) @ Index.js:163handle @ jquery-1.6.2.min.js:17k @ jquery-1.6.2.min.js:16 Transport.js:479 Frame location not found within timeout (10000): http://lyncdiscoverinternal.ge.com/xframe XFrame.js:143 GET http://lyncdiscover.ge.com/xframe 403 (Forbidden)sendRequest @ XFrame.js:143(anonymous function) @ XFrame.js:207 scriptInjector.js:193 sI: inside WIDGET_CONTENT_MESSAGE message listener: MessageEvent scriptInjector.js:194 MessageEvent scriptInjector.js:193 sI: inside WIDGET_CONTENT_MESSAGE message listener: MessageEvent scriptInjector.js:194 MessageEvent Transport.js:186 Service does not allow a cross domain request from this origin. AutoDiscovery.js:93 Autodiscovery failed on internal/external location contentScript.js:234 cs: onRequestListener(Arguments[3]) contentScript.js:234 cs: onRequestListener(Arguments[3])
推荐答案
此问题(服务不允许来自此来源的跨域请求.)主要是由跨域资源共享(CORS)"引起的,并且请求访问的地址未列入白名单".
This issue (Service does not allow a cross domain request from this origin.) is mostly caused by the "Cross-Origin Resource Sharing (CORS)" and that the address which is requesting the access isn´t "whitelisted".
Skype for Business管理员可以通过(更多信息的此处)进行配置:
An Skype for Business Administrator can configure that via (more info's here):
$x = New-CsWebOrigin -Url "https://apps.contoso.com"
Set-CsWebServiceConfiguration -Identity "{YOUR_IDENTITY}" -CrossDomainAuthorizationList @{Add=$x}
在更改之前,请检查是否已通过以下方式完成
before you change that, check if that is already done via:
Get-CsWebServiceConfiguration | select -ExpandProperty CrossDomainAuthorizationList
这样您就不会覆盖某些东西
So that you will not overwrite something
这篇关于Lync Service不允许来自此来源的跨域请求的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!