authentication problem when using RQMUrlUtility
I tried to use RQMUrlUtility to GET a list of test cases, but seems it couldn't pass authentication. I provided my user name and password correctly in command line argument, but all I got was the HTML code from user login page. Could anyone help me to solve this problem?
I downloaded RQMUrlUtility 3.0.1 and RQM version is also 3.0.1
The command I issued is:
java -jar RQMUrlUtility.jar -command GET -user bobwang@ca.ibm.com -password xxxxxxxx -context qm -filepath d:\\listc.xml -url https://ecdclm.ottawa.ibm.com:9445/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/WebSphere+Commerce+(Quality+Management)/testcase
the standard output is:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
<<<<<RQMUrlUtility>>>>>
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RQMUrlUtility: Connected to https://ecdclm.ottawa.ibm.com:9445 using project "We
bSphere+Commerce+(Quality+Management)"
Oct 7, 2011 11:22:01 AM org.apache.commons.httpclient.HttpMethodDirector isRedir
ectNeeded
INFO: Redirect requested but followRedirects is disabled
RQMUrlUtility: Calling method to retrieve XML from a specified URL
RQMUrlUtility: Server Response code: 200
Oct 7, 2011 11:22:01 AM org.apache.commons.httpclient.HttpMethodBase getResponse
Body
WARNING: Going to buffer response body of large or unknown size. Using getRespon
seBodyAsStream instead is recommended.
RQMUrlUtility: XML string retrieved from URL : "https://ecdclm.ottawa
.ibm.com:9445/qm/secure/service/com.ibm.rqm.integration.service.IIntegrationServ
ice/resources/WebSphere+Commerce+(Quality+Management)/testcase " is written to f
ile located at -: " d:\\listc.xml "
looks like everything is fine except "INFO: Redirect requested but followRedirects is disabled", not sure if this is an issue.
And when I opened file d:\listc.xml, I found all I get was the HTML file from the user login page.
<!DOCTYPE html>
<!--
Licensed Materials - Property of IBM
(c) Copyright IBM Corporation 2005-2010. All Rights Reserved.
Note to U.S. Government Users Restricted Rights:
Use, duplication or disclosure restricted by GSA ADP Schedule
Contract with IBM Corp.
-->
<html >
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=8">
<title></title>
<link type="text/css" rel="stylesheet" href="/qm/web/_style/?include=A~&etag=suwYll5R_en_US&_proxyURL=%2Fqm">
<link rel="shortcut icon" href="/qm/web/net.jazz.ajax/jazz.ico">
<style type="text/css">
#net-jazz-ajax-NoScriptMessage {
width: 100%;
color: #D0D0D0;
font-size: 2em;
text-align: center;
position: absolute;
top: 1%;
z-index: 999;
}
</style>
</head>
<body class="tundra">
<noscript><div id="net-jazz-ajax-NoScriptMessage">Javascript is either disabled or not available in your Browser</div></noscript>
<div id="net-jazz-ajax-InitialLoadMessage">Loading...</div>
<div id="net-jazz-ajax-WorkbenchRoot"></div>
<script type="text/javascript">
djConfig = {
isDebug: false,
usePlainJson: true,
baseUrl: "/qm/web/dojo/",
locale: "en-us",
localizationComplete: true
};
/*null*/
net = {jazz: {ajax: {}}};
net.jazz.ajax._contextRoot = "/qm";
net.jazz.ajax._webuiPrefix = "/web/";
</script>
<script type="text/javascript" src="/qm/web/_js/?include=A~&etag=suwYll5R_en_US"></script>
<script type="text/javascript">
/* <!;
net.jazz.ajax._rootServices = 'https://ecdclm.ottawa.ibm.com:9445/qm/rootservices';
net.jazz.ajax._storageService = 'https://ecdclm.ottawa.ibm.com:9445/qm/storage';
net.jazz.ajax._queryService = 'https://ecdclm.ottawa.ibm.com:9445/qm/query';
net.jazz.ajax._infoCenterRoot = 'https://ecdclm.ottawa.ibm.com:9445/qm/../clmhelp';
net.jazz.ajax._oauthRealmName = 'Jazz';
net.jazz.ajax._viewletServiceRoot = 'https://ecdclm.ottawa.ibm.com:9445/qm';
net.jazz.ajax._viewletWebUIRoot = 'https://ecdclm.ottawa.ibm.com:9445/qm';
net.jazz.ajax._hasLocalRepository = true;
net.jazz.ajax._proxyLegacyMode = false;
net.jazz.ajax._oauthDomains = ;
net.jazz.ajax._friendDomains = ;
/* ]]> */
</script>
<script type="text/javascript">
/* <!]> */
</script>
</body>
</html>
I downloaded RQMUrlUtility 3.0.1 and RQM version is also 3.0.1
The command I issued is:
the standard output is:
<<<<<RQMUrlUtility>>>>>
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RQMUrlUtility: Connected to https://ecdclm.ottawa.ibm.com:9445 using project "We
bSphere+Commerce+(Quality+Management)"
Oct 7, 2011 11:22:01 AM org.apache.commons.httpclient.HttpMethodDirector isRedir
ectNeeded
INFO: Redirect requested but followRedirects is disabled
RQMUrlUtility: Calling method to retrieve XML from a specified URL
RQMUrlUtility: Server Response code: 200
Oct 7, 2011 11:22:01 AM org.apache.commons.httpclient.HttpMethodBase getResponse
Body
WARNING: Going to buffer response body of large or unknown size. Using getRespon
seBodyAsStream instead is recommended.
RQMUrlUtility: XML string retrieved from URL : "https://ecdclm.ottawa
.ibm.com:9445/qm/secure/service/com.ibm.rqm.integration.service.IIntegrationServ
ice/resources/WebSphere+Commerce+(Quality+Management)/testcase " is written to f
ile located at -: " d:\\listc.xml "
looks like everything is fine except "INFO: Redirect requested but followRedirects is disabled", not sure if this is an issue.
And when I opened file d:\listc.xml, I found all I get was the HTML file from the user login page.
<!--
Licensed Materials - Property of IBM
(c) Copyright IBM Corporation 2005-2010. All Rights Reserved.
Note to U.S. Government Users Restricted Rights:
Use, duplication or disclosure restricted by GSA ADP Schedule
Contract with IBM Corp.
-->
<html >
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=8">
<title></title>
<link type="text/css" rel="stylesheet" href="/qm/web/_style/?include=A~&etag=suwYll5R_en_US&_proxyURL=%2Fqm">
<link rel="shortcut icon" href="/qm/web/net.jazz.ajax/jazz.ico">
<style type="text/css">
#net-jazz-ajax-NoScriptMessage {
width: 100%;
color: #D0D0D0;
font-size: 2em;
text-align: center;
position: absolute;
top: 1%;
z-index: 999;
}
</style>
</head>
<body class="tundra">
<noscript><div id="net-jazz-ajax-NoScriptMessage">Javascript is either disabled or not available in your Browser</div></noscript>
<div id="net-jazz-ajax-InitialLoadMessage">Loading...</div>
<div id="net-jazz-ajax-WorkbenchRoot"></div>
<script type="text/javascript">
djConfig = {
isDebug: false,
usePlainJson: true,
baseUrl: "/qm/web/dojo/",
locale: "en-us",
localizationComplete: true
};
/*null*/
net = {jazz: {ajax: {}}};
net.jazz.ajax._contextRoot = "/qm";
net.jazz.ajax._webuiPrefix = "/web/";
</script>
<script type="text/javascript" src="/qm/web/_js/?include=A~&etag=suwYll5R_en_US"></script>
<script type="text/javascript">
/* <!;
net.jazz.ajax._rootServices = 'https://ecdclm.ottawa.ibm.com:9445/qm/rootservices';
net.jazz.ajax._storageService = 'https://ecdclm.ottawa.ibm.com:9445/qm/storage';
net.jazz.ajax._queryService = 'https://ecdclm.ottawa.ibm.com:9445/qm/query';
net.jazz.ajax._infoCenterRoot = 'https://ecdclm.ottawa.ibm.com:9445/qm/../clmhelp';
net.jazz.ajax._oauthRealmName = 'Jazz';
net.jazz.ajax._viewletServiceRoot = 'https://ecdclm.ottawa.ibm.com:9445/qm';
net.jazz.ajax._viewletWebUIRoot = 'https://ecdclm.ottawa.ibm.com:9445/qm';
net.jazz.ajax._hasLocalRepository = true;
net.jazz.ajax._proxyLegacyMode = false;
net.jazz.ajax._oauthDomains = ;
net.jazz.ajax._friendDomains = ;
/* ]]> */
</script>
<script type="text/javascript">
/* <!]> */
</script>
</body>
</html>
15 answers
Thanks for the response Paules,
I am not sure if I 'can' post the command I'm using as it might disclose the url and it's a fairly private url.
But I am indeed using the UI URL (this is the URL that I would use on the browser).
I wasn't aware that I should use a dfferent one...
Is there some way of deriving the integration service URL from the UI URL ?
I am not sure if I 'can' post the command I'm using as it might disclose the url and it's a fairly private url.
But I am indeed using the UI URL (this is the URL that I would use on the browser).
I wasn't aware that I should use a dfferent one...
Is there some way of deriving the integration service URL from the UI URL ?
I'm not sure since the JavaScript does not provide much information.
My best guess is that you are using the wrong URL (web UI URL versus integration service URL) to make the request and the RQM URL Utility is attempting to log into the web UI. Can you post your RQM URL Utility parameters?
Thanks
Ok so the URL I can access via the Browser (UI) is:
(with host and port masked out)
https://swgjazz.ibm.com:8023/jazz/web/console/AC#action=com.ibm.rqm.planning.home.actionDispatcher&subAction=viewTestCase&id=6702
I am checking the second url you supply below (first one seems to be broken) here for how to translate that:..
But if you can help that would be great.
Ok so the URL I can access via the Browser (UI) is:
(with host and port masked out)
https://swgjazz.ibm.com:8023/jazz/web/console/AC#action=com.ibm.rqm.planning.home.actionDispatcher&subAction=viewTestCase&id=6702
I am checking the second url you supply below (first one seems to be broken) here for how to translate that:..
But if you can help that would be great.
As mentioned in https://jazz.net/wiki/bin/view/Main/RQMURLUtility, you use https://jazz.net/wiki/bin/view/Main/RqmApi#resourceUrl_for_interaction_with.
You can post proprietary URLs by masking the host/port/etc.
page 2of 1 pagesof 2 pages