If you are unable to create a new account, please email bspsoftware@techdata.com

Author Topic: Authenticating to Cognos using CMS  (Read 2587 times)

Offline mars_22

  • Associate
  • **
  • Join Date: Jan 2020
  • Posts: 1
  • Forum Citizenship: +0/-0
Authenticating to Cognos using CMS
« on: 24 Feb 2020 04:23:06 am »
Hello all,

we're trying to build a web application and host it on a webserver outside of Cognos. This application (or the actions available in the app) should be accessible only to users that are added to Cognos.
I thought that the easiest way to do this would be to use the Mashup Service. We're running Cognos Analytics v. 11.1.3. on RHEL 7.5.

To get started, I was using the original Mashup Services samples - there are two ways of authenticating, either using the standard Cognos logon page or the already mentioned CMS authentication methods. They are (very) briefly described here: https://www.ibm.com/support/knowledgecenter/SSEP7J_11.1.0/com.ibm.swg.ba.cognos.ca_dg_cms.doc/c_rest_log.html#rest_log 

I'm not able to get any of these samples running from an external web server - I'm getting stuck on cross-origin errors ("No 'Access-Control-Allow-Origin' header is present on the requested resource", "Blocked a frame with origin XX from accessing a cross-origin frame").

Has anyone dealt with some similar case? My thinking was to enable CORS on the server under Cognos Analytics, but not sure where exactly should I do that.

Ideally I would like to get the "Standard Cognos logon page" option running as then we don't need to take care of sending the credentials with the request. But I would be happy with any of the options.
Next step then would be to get the CAMPassport and send it as part of a request to Planning Analytics.

Thank you very much in advance for any insight.

mars

Offline DaHammer

  • Full Member
  • ***
  • Join Date: Jun 2016
  • Posts: 19
  • Forum Citizenship: +0/-0
Re: Authenticating to Cognos using CMS
« Reply #1 on: 04 Oct 2020 07:37:04 pm »
Just add

Access-Control-Allow-Origin: *

to your HTTPD.CONF or IIS configuration

https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Access-Control-Allow-Origin