是crossdomain.xml中最严格的策略,相当于完全没有?

时间:2012-01-13 13:20:54

标签: flash adobe crossdomain.xml html5boilerplate

我可以在我的服务器的日志上看到几个http 404 对于[mydomain] /crossdomain.xml

我想知道是否要添加此文件并将其配置为具有最严格的策略。那就是:(取自html 5样板)

<?xml version="1.0"?>

<!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd">
-<cross-domain-policy> 
<!-- Read this: www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html -->

<!-- Most restrictive policy: -->
 <site-control permitted-cross-domain-policies="none"/> 
<!-- Least restrictive policy: -->

<!-- <site-control permitted-cross-domain-policies="all"/> <allow-access-from domain="*" to-ports="*" secure="false"/> <allow-http-request-headers-from domain="*" headers="*" secure="false"/> -->

<!-- If you host a crossdomain.xml file with allow-access-from domain="*" and don’t understand all of the points described here, you probably have a nasty security vulnerability. ~ simon willison -->
 </cross-domain-policy>

是否等同于完全没有?

我发现与跨域误导相关的http 404错误,因此我想摆脱它们,以便我能更有效地识别真实的错误。

1 个答案:

答案 0 :(得分:0)

不完全。规范说明:

  

换句话说,根跨域策略不包含   allow-access-from指令或HTTP头。一个元政策   “none”阻止使用可能存在的任何其他策略   即使开发者包括他们。它是无效的   根跨域中的allow-access-from或头策略   策略文件,元策略为“none”。在无效的情况下   策略既有“无”设置,也有其他指令,“无”需要   网站上允许使用优先权和无权限。

所以,我认为最严格的技术是使用“无”。