2016-12-25 33 views
0

測試我的應用程序時,我發現了錯誤,當本地工作,因爲我切換到https:有沒有辦法讓HTTPS請求從本地主機要求測試

Warning: Domain www.example.com does not specify a meta-policy.

Applying default meta-policy 'master-only'. This configuration is deprecated. See http://www.adobe.com/go/strict_policy_files to fix this problem.

Error: Request for resource at https://www.example.com/?json=user/get_logged_in_user by requestor from http://localhost:8888/Test-debug/Test.swf is denied due to lack of policy file permissions.

我試圖改變我的localhost https但得到了以下錯誤:

Secure Connection Failed

An error occurred during a connection to localhost:8888. SSL received a record that exceeded the maximum permissible length. Error code: SSL_ERROR_RX_RECORD_TOO_LONG

The page you are trying to view cannot be shown because the authenticity of the received data could not be verified. Please contact the website owners to inform them of this problem.

從我讀過,我可以上傳並添加策略文件和不斷變化的安全爲true什麼,但我不希望允許從任何地方的電話。一旦瑞士法郎在我的服務器上一切正常。

有沒有辦法讓本地測試工作?有什麼在測試一樣,我可以啓用:

Security.allowDomain("localhost"); 

當我做測試或做我必須上傳跨域策略,然後刪除該策略?

由於我的本地站點在瀏覽器本地運行,它不應該能夠連接到https連接嗎?

回答

1

使用https(順便說一句,根據你發佈的消息沒有正確配置(你使用FireFox測試?))沒有幫助。問題是www.example.com沒有crossdomain.xml政策文件,因此Flash播放器不允許從您的localhots這也是一個域訪問該域。

如果您有權訪問www.example.com在此處添加帶有通配符訪問的策略文件,如果沒有 - 通過http測試僅適用於使用某些http代理模擬響應。

0

我更改爲使用file://(無服務器)進行測試,它的作用是使https調用。

相關問題