【问题标题】:ColdFusion giving "template denied access" error using cfajaxproxyColdFusion 使用 cfajaxproxy 给出“模板拒绝访问”错误
【发布时间】:2013-02-22 18:05:53
【问题描述】:

我的服务器需要一个 cfajaxproxy 接口(无需在页面上提交即可传递数据)。希望 cfajaxproxy 是正确的方法吗?

为了了解这一点,我首先修改了http://tutorial13.learncf.com/ 显示的示例教程,但在收到“模板拒绝访问”错误后,我决定直接按原样使用该教程,它只有两个小文件(可以直接从他的教程中剪切和粘贴)。不幸的是,我在他的教程中遇到了同样的错误(即使他在他的网站上作为演示运行)。所以??

我将 proxy.cfc 文件放在我正在访问的(主)wwwroot 目录中(第一次使用 cfc)。我是否需要请求托管公司允许服务器上的某些内容(运行 ColdFusion 8)?

谢谢。错误详情如下:

处理请求时发生错误 安全性:请求的模板已被拒绝访问 C:/Coldfusion8/wwwroot/WEB-INF/cfclasses/cfproxy2ecfc771136334.class。

下面是内部异常信息:access denied (java.io.FilePermission C:/Coldfusion8/wwwroot/WEB-INF/cfclasses/cfproxy2ecfc771136334.class read)

ColdFusion cannot determine the line of the template that caused this error. This is often    caused by an error in the exception handling subsystem.
Resources:
Check the ColdFusion documentation to verify that you are using the correct syntax.
Search the Knowledge Base to find a solution to your problem.
Browser     Mozilla/5.0 (Windows NT 6.0) AppleWebKit/537.17 (KHTML, like Gecko)    Chrome/24.0.1312.57 Safari/537.17
Remote Address      72.201.113.149
Referrer    
Date/Time   22-Feb-13 12:42 AM
Stack Trace
java.security.AccessControlException: access denied (java.io.FilePermission    C:/Coldfusion8/wwwroot/WEB-INF/cfclasses/cfproxy2ecfc771136334.class read) at  cfdemo2ecfm1260454926.runPage(C:/Websites/202350mu7/wwwroot/sf/demo.cfm:1) 

java.security.AccessControlException: access denied (java.io.FilePermission C:\Coldfusion8\wwwroot\WEB-INF\cfclasses\cfproxy2ecfc771136334.class read)
at java.security.AccessControlContext.checkPermission(AccessControlContext.java:374)
at java.security.AccessController.checkPermission(AccessController.java:546)
at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
at java.lang.SecurityManager.checkRead(SecurityManager.java:871)
             ...

【问题讨论】:

    标签: coldfusion coldfusion-8


    【解决方案1】:

    这是一个安全沙盒问题,您需要联系您的主机并确保您有一个可以访问此文件夹的沙盒。

    【讨论】:

    • 谢谢。你能告诉我是否应该把这个cfc放在一个子文件夹中,如果是的话,如果这会影响任何CF标签来访问它。 (服务器是否搜索整个目录树的组件和子目录对标签没有影响)?
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2023-03-16
    • 1970-01-01
    • 2012-01-22
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多