简体   繁体   English

如何像提要一样保护XML

[英]How to protect XML like a feed

I have a xml file used by a swf to read and display information, but I would like to protect it from viewing the raw file, but keep swf access to view info. 我有一个swf使用的xml文件来读取和显示信息,但是我想保护它免于查看原始文件,但保持swf访问权限来查看信息。

Is there a way to do this, maybe php, javascript?... 有没有办法做到这一点,也许是php,javascript?...

In my opinion any thing that goes to a browser can be hijacked. 我认为浏览器中的所有内容都可以被劫持。 What your strategy should be is to make it harder to do. 您的策略应该是使其变得更难。 Here are possible cases: 这是可能的情况:

  • To protect your data from being sniffed on the wire use SSL ("https://") for you web service 为了防止您的数据被网络窃听,请为您的Web服务使用SSL(“ https://”)
  • Implement application authentication like 2-legged OAuth. 实现两腿式OAuth之类的应用程序身份验证。 This will give you a more granular control over what apps accessing your service. 这将使您可以更精细地控制哪些应用程序访问了您的服务。

您可以使用.htaccess规则(如果使用apache服务器)并阻止直接访问...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM