system
September 28, 2009, 8:45pm
1
Has anyone had any luck bypassing authentication in an Xcelsius dashboard with Live Office?
Is there any way to embed generic login info (a generic Enterprise account name and password) into a web page that serves up the .swf file, and pass that into the .swf file?
wtsees (BOB member since 2009-09-08)
system
September 28, 2009, 10:56pm
2
Yes that can be done quite easily using jsp for .net code. You simply create a web page, create a session to the BOE using the SDK and passing the session to the flash object using flash variables.
J0sh (BOB member since 2006-10-09)
system
November 30, 2009, 2:49pm
3
I believe I’m really close to getting this to work, however I currently get an error when the dashboard loads :
“soapenv:Client: The service cannot be found for the endpoint reference (EPR) http://:/dswsbobje/services/session”
I do get a successful connection to the CMS. Any help anyone can provide is much appreciated!
Here is the code I’m using the JSP:
<%@ page import="com.crystaldecisions.sdk.exception.SDKException,
com.crystaldecisions.sdk.framework.*,
com.crystaldecisions.sdk.occa.infostore.*,
com.crystaldecisions.sdk.occa.security.*,
java.net.*,
com.crystaldecisions.Enterprise.*,
com.crystaldecisions.sdk.plugin.admin.*"
%>
<%@ page import="java.sql.*"%>
<%
//-------------------------------------------------------------------Create BO Session and redirect to Infoview
IEnterpriseSession enterpriseSession;
String serializedSession = "";
/* * Set Enterprise Logon credentials. */
final String BO_CMS_NAME = "server";
final String BO_AUTH_TYPE = "secEnterprise";
final String BO_USERNAME = "username";
final String BO_PASSWORD = "password";
ILogonTokenMgr logonTokenMgr;
String defaultToken = "";
/*
* Set Java InfoView start page URL
*/
final String INFOVIEW_URL = "http://<server>:8080/InfoViewApp/logon/start.do";
/*
* Log onto Enterprise and serialize the Enterprise Session.
*/
boolean loggedIn = true;
try {
enterpriseSession = CrystalEnterprise.getSessionMgr().logon(BO_USERNAME,BO_PASSWORD, BO_CMS_NAME, BO_AUTH_TYPE);
serializedSession = enterpriseSession.getSerializedSession();
logonTokenMgr = enterpriseSession.getLogonTokenMgr();
defaultToken = logonTokenMgr.getDefaultToken();
}
catch (Exception error)
{
loggedIn = false;
}
//-------------------------------------------------------------------If login successful
if(loggedIn) { //only insert successful logins
String Flashvars="CELogonToken=" + defaultToken + "&CEWebServiceURL=http://<server>::8080/dswsbobje/services/session";
String output = "";
output = output + "<PARAM NAME=movie VALUE='test.swf'>";
output = output + "<PARAM NAME=quality VALUE=high>";
output = output + "<PARAM NAME=FlashVars var='\"" + Flashvars + "\"'>";
output = output + "<EMBED src='test.swf' flashvars='\" " + Flashvars + "\"' quality=high bgcolor=#FFFFFF WIDTH='800' HEIGHT='600' NAME='myMovieName'
ALIGN=\"\" TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'></EMBED></OBJECT>";
out.println(output);
}
//-------------------------------------------------------------------If login failed
else {
out.println("Failed!");
}
%>
[Moderator Edit: Added code formatting - Andreas]
wtsees (BOB member since 2009-09-08)
system
December 1, 2009, 6:34pm
4
I believe the problem is with the token being passed from the JSP to the dashboard. The dashboard successfully loads, but fails when it tries to refresh the Live Office queries. If I remove the flashvars from the last output statement, the dashboard will load just fine, but still prompt for authentication.
Is there something I need to enable with the web server or services? Again, any help is hugely appreciated!
wtsees (BOB member since 2009-09-08)
system
December 2, 2009, 9:24pm
5
FYI to all, I was able to solve this problem. Below is working code to bypass the authentication popup in Xcelsius. This code logs onto the CMS using an Enterprise account, creates a connection token, then passes that token, along with the web services URL, to a new page created dynamically, which loads the dashboard.
<%@ page import="com.crystaldecisions.sdk.exception.SDKException,
com.crystaldecisions.sdk.framework.*,
com.crystaldecisions.sdk.occa.infostore.*,
com.crystaldecisions.sdk.occa.security.*,
java.net.*,
com.crystaldecisions.Enterprise.*,
com.crystaldecisions.sdk.plugin.admin.*,
com.businessobjects.webutil.Encoder"
%>
<%@ page import="java.sql.*"%>
<%
//-------------------------------------------------------------------Create BO Session and redirect to Infoview
IEnterpriseSession enterpriseSession;
/* * Set Enterprise Logon credentials. */
final String BO_CMS_NAME = "[server]";
final String BO_AUTH_TYPE = "secEnterprise";
final String BO_USERNAME = "[username]";
final String BO_PASSWORD = "[password]";
ILogonTokenMgr logonTokenMgr;
String defaultToken = "";
final String INFOVIEW_URL = "http://[server]:[port]/InfoViewApp/logon/start.do";
/*
* Log onto Enterprise
*/
boolean loggedIn = true;
try {
enterpriseSession = CrystalEnterprise.getSessionMgr().logon(BO_USERNAME,BO_PASSWORD, BO_CMS_NAME, BO_AUTH_TYPE);
logonTokenMgr = enterpriseSession.getLogonTokenMgr();
defaultToken = logonTokenMgr.createWCAToken("", 20, 1);
}
catch (Exception error)
{
loggedIn = false;
}
//-------------------------------------------------------------------If login successful
if(loggedIn) {
String Flashvars="&CELogonToken=" + Encoder.encodeURL(defaultToken);
Flashvars += "&CEWebServiceURL=" + Encoder.encodeURL("http://[server]:[port]/dswsbobje/services/session");
String output = "";
output = output + "<OBJECT classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000
codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0' id='myMovieName' style='width: 355px; height: 237px'> \r\r";
output = output + "<PARAM NAME=movie VALUE='System_Standards.swf'> \r\r"; //( \r = carriage return to make output more legible )
output = output + "<PARAM NAME=quality VALUE=high> \r\r";
output = output + "<PARAM NAME=FlashVars value=\"" + Flashvars + "\">\r\r";
output = output + "<EMBED src='System_Standards.swf' flashvars=\" " + Flashvars + "\" quality=high bgcolor=#FFFFFF WIDTH='1000' HEIGHT='600'
NAME='myMovieName' ALIGN=\"\" TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'></EMBED></OBJECT>\r\r";
out.println(output);
}
//-------------------------------------------------------------------If login failed
else {
out.println("Login to Business Objects Failed.");
}
%>
wtsees (BOB member since 2009-09-08)
system
April 14, 2011, 3:22pm
6
hi,
could you please help me with this, im create a jsp file but i cant connect bypass login
is another steps in xcelsius?? after create jsp file?
best regards
MAx
rey_killer (BOB member since 2009-07-08)
Thanks for your post.I have couple of questions on this.Do we need to export dashboard to infoview then create a jsp page and launch it from there.Or somethign else.Also do we need any setting in the Xcelcius dashboard for this to work.I would appreciate the reply.
DataGenius (BOB member since 2006-06-13)
system
May 18, 2012, 10:33am
8
Hi Pros!
We are also stuck at the authentication step
Currently we have an xcelsius output with Live Office connection which comes up with a authentication pop-up window
Can anybody please share steps to bypass the Live Office authentication
Thanks in Advance
LS
luckysoul30 (BOB member since 2006-07-13)
system
June 19, 2012, 6:14am
9
Guys,
Finally we made it work :o
But there seems to be a timeout issue… any idea how to change the Timeout parameter for the session made through the JSP file??
We have already increased the timeout for all the possible apps in web.xml files.
Any help would be greatly appreciated
LS
luckysoul30 (BOB member since 2006-07-13)
system
June 19, 2012, 12:17pm
10
Resolved
In addition to other timeouts we missed the CMS connection timeout which is set at the Windows Registry Level
Please go through this link for detailed steps - http://sunsethill.ca/articles/id/8/infoview-timeout-issues.aspx
LS
luckysoul30 (BOB member since 2006-07-13)
system
June 25, 2012, 9:51am
11
Hi Pros!
We are also stuck at the authentication step
Currently we have an xcelsius output with Live Office connection which comes up with a authentication pop-up window
Can anybody please share steps to bypass the Live Office authentication
Thanks in Advance
LS
vinaykumar.beri (BOB member since 2012-06-25)