+2 votes
1 view

I tried to integration Knowage 7.1 with CAS 6.2 overlay. After successfully login using CAS user then got error in knowage. Error 500. I don't know what the root cause. I just followed the steps from knowage documentation->https://knowage-suite.readthedocs.io/en/7.1/installation-guide/cas-installation.html.

.

Thank you for your help

Riza

Environment Knowage 7.1 CE, Centos 7 64 but, Tomcat bundle, Chrome
asked Jul 7, 2020 in Single Sign-On by riza.ansori (180 points) | 1 view

Hello,

Same problem with CAS 4.07. I followed the CAS Installation documentation  with manual installation and Docker image of knowage 7.1.7 CE Edition. Same results and same error message in knowage.log.

Some help would be really appreciated.

Franck

Environment Knowage 7.1 CE, Debian 9 64 bit, Tomcat 8.5, Firefox

2 Answers

+1 vote
Hi,

Did you manage to get CAS working with Knowage ?
I face the same error 500 after successful login in CAS.
Same JWT parsing error in the log : https://pastebin.com/aGkah71c

I'm using Knowage 7.4.6

Thanks
answered Aug 26, 2021 by rlagarde (3,170 points)

Some more information from DEBUG log bellow.
USERID (biadmin) is sent to be parsed as a JWT

[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,792 DEBUG it.eng.spagobi.services.common.SsoServiceFactory.createProxyService:43 - IN
[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,793 DEBUG it.eng.spagobi.services.common.SsoServiceFactory.createProxyService:53 -  Instatiate successfully:it.eng.spagobi.services.cas.CasSsoService3NoProxy
[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,793 DEBUG it.eng.spagobi.services.cas.CasSsoService3NoProxy.readUserIdentifier:62 - CAS user in HttpServletRequest:biadmin
[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,794 DEBUG it.eng.spagobi.services.cas.CasSsoService3NoProxy.readUserIdentifier:63 - CAS user in HttpSession:biadmin
[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,794 DEBUG it.eng.spagobi.services.common.JWTSsoService.jwtToken2userId:181 - JWT token in input is [biadmin]
[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,795 DEBUG it.eng.spagobi.services.common.JWTSsoService.jwtToken2userId:181 - JWT token in input is [biadmin]
[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,795 DEBUG it.eng.spagobi.services.common.JWTSsoService.jwtToken2userId:181 - JWT token in input is [biadmin]
[ajp-nio-10.10.1.5-8009-exec-8] 26 août 2021 12:20:58,795 ERROR it.eng.spagobi.commons.utilities.UserUtilities.getUserProfile:249 - Exception while creating user profile
com.auth0.jwt.exceptions.JWTDecodeException: The token was expected to have 3 parts, but got 1.
        at com.auth0.jwt.TokenUtils.splitToken(TokenUtils.java:21)
        at com.auth0.jwt.JWTDecoder.<init>(JWTDecoder.java:27)
        at com.auth0.jwt.JWT.decode(JWT.java:21)
        at com.auth0.jwt.JWTVerifier.verify(JWTVerifier.java:352)
        at it.eng.spagobi.services.common.JWTSsoService.jwtToken2userId(JWTSsoService.java:183)
        at it.eng.spagobi.security.InternalSecurityServiceSupplierImpl.createUserProfile(InternalSecurityServiceSupplierImpl.java:122)
        at it.eng.spagobi.commons.utilities.UserUtilities.getUserProfile(UserUtilities.java:222)
        at it.eng.spagobi.commons.utilities.GeneralUtilities.createNewUserProfile(GeneralUtilities.java:240)
        at it.eng.spagobi.commons.filters.ProfileFilter.doFilter(ProfileFilter.java:135)
...
0 votes
Hello,

Same problem for me with Knowage 8.0.1, will this bug ever be fixed ?

If CAS integration is broken, I won't use Knowage at all.

Thanks
answered Nov 24, 2021 by pbaus (220 points)

Dear Pierre,
We are using CAS and Knowage in some projects, so this integration is working.

Some configuration detail could be wrong, if you describe in detail the steps you did, we'll help you to configure the integration, we need to know:
- The CAS Version
- Are you using https ?
- The value of sso_class variable
- Send me the web.xml file in /webapps/knowage/WEB-INF/

Best Regards

A.

Hello,

I followed exactly the documentation here : https://knowage-suite.readthedocs.io/en/8.0/installation-guide/cas-installation.html

We use CAS version 5, https through httpd with ajp proxy, and the sso_class variable is set to value="it.eng.spagobi.services.cas.CasSsoService3NoProxy".

Here is the web.xml : https://www.knowage-suite.com/qa/?qa=blob&qa_blobid=3396213167076084829

Also the logs : https://www.knowage-suite.com/qa/?qa=blob&qa_blobid=6444188824996670921

Thank you for your help.

Hi,

Did you have the time to take a look at the files ?

I'm still unable to login with CAS, I tried with the last Knowage version 8.0.5 but nothing changed.

Thank you
1,555 questions
1,017 answers
2,038 comments
2,568 users