没有登录的Pentaho BI服务器报告

问题描述 投票:5回答:2

我需要将我的Pentaho社区仪表板报告集成到DotNet应用程序中。现在我遇到了一个问题。我想在没有Pentaho服务器要求身份验证或登录的情况下单击打开报告。我试图找到解决方案并发现如果我在URL中使用用户ID和密码,它将起作用。所以我这样做了

http://192.168.2.122:8085/pentaho/api/repos/:home:Time%20Sheet%20Reports:Project%20Effort%20Analysis%20Dashboard.wcdf/generatedContent&userid=admin&password=password

但这对我不起作用,浏览器仍然要求登录凭据。我不明白出了什么问题。任何有关相同的帮助将非常感激。

提前致谢。此致,Ritesh。

authentication login pentaho pentaho-cde
2个回答
12
投票

您需要在Manage Users&Roles Perspective下创建以下用户:

anonymousUser (notice the uppercase U)

您可以为此用户提供任何密码;这只是为了确保此用户映射pentaho-solutions / system中配置文件中使用的用户

确保匿名角色至少具有读取权限。

匿名角色应该已经存在于BA服务器中(默认情况下,这是管理用户和角色透视图中的系统角色)

在Public下创建一个文件夹:在我的例子中“OpenReports”

选择“OpenReports”文件夹单击属性>单击“共享”>“取消选中”>“继承文件夹权限”

确保匿名添加匿名用户和角色,并且至少是读取权限

单击确定

将Analyzer报告复制到新的OpenReports文件夹

验证是否继承了anonymousUser和Anonymous角色的权限;如果不相应添加它们。

停止BA服务器

找到以下文件:

\pentaho\server\biserver-ee\pentaho-solutions\system\applicationContext-spring-security.xml

添加以下行:

\A/i18n.*\Z=Anonymous,Authenticated

\A/js/utils.js\Z=Anonymous,Authenticated

\A/api/.*require-js-cfg.js\Z=Anonymous,Authenticated

\A/api/.*\Z=Anonymous,Authenticated

\A/api/repos.*\Z=Anonymous,Authenticated

\A/api/common-ui/resources/.*\Z=Anonymous,Authenticated

\A/api/common-ui/util/.*\Z=Anonymous,Authenticated

以下行打开对OpenReports文件夹及其内容的匿名访问

\A/api/repos.*public.*openreports.*\Z=Anonymous,Authenticated

\A/api/repos.*public.*openreports.*/viewer/.*\Z=Anonymous,Authenticated

\A/api/repos.*public.*openreports.*/common-ui/.*\Z=Anonymous,Authenticated

\A/api/repos.*public.*openreports.*/common-ui/util/.*\Z=Anonymous,Authenticated



after:

\A/js/require-cfg.js\Z=Anonymous,Authenticated

and before:

\A/content/data-access/resources/gwt/.*css\Z=Anonymous,Authenticated

添加以下行:(这些打开对Analyzer插件的URL访问)

\A/content/pentaho-cdf/.*\Z=Anonymous,Authenticated

\A/content/common-ui/.*\Z=Anonymous,Authenticated

\A/content/analyzer/.*\Z=Anonymous,Authenticated

\A/content/analyzer/scripts/.*\Z=Anonymous,Authenticated 

确保添加以下行:

After:

\A/content/data-access/resources/gwt/.*css\Z=Anonymous,Authenticated

and before:

\A/webcontext.js.*\Z=Anonymous,Authenticated

找到以下内容

Change the following lines from:

\A/api/.*\Z=Authenticated

\A/plugin/.*\Z=Authenticated

to:

\A/api/.*\Z=Anonymous,Authenticated

\A/plugin/.*\Z=Anonymous,Authenticated

保存文件

重新启动BA服务器

您应该能够通过URL成功调用报告,而无需通过登录页面进行身份验证;这是一个示例网址:

http://192.168.2.122:8085/pentaho/api/repos/:public:OpenReports:Leading%20Product%20Lines%20(pivot%20table).xanalyzer/editor


3
投票

这是绕过登录的最简单方法:

http://pedroalves-bi.blogspot.pt/2015/02/useful-tips-easy-authentication-in.html

这对我有用,我正在使用pentaho 5.4

不要忘记创建anonymousUser并在“系统角色”中仅选中“阅读内容”。

如果你使用管理员用户,然后你尝试访问qazxsw poi它将自动登录,因为浏览器仍然有会话登录。

对不起,我的英语不好,

© www.soinside.com 2019 - 2024. All rights reserved.