dgradecak / alfresco-jwt-auth

Alfresco Identity Service without Keycloak - but with a custom signed JWT
Apache License 2.0
10 stars 6 forks source link

JWT Issued By External OAUTH Server is Not Accepted #3

Closed manurajsingh closed 3 years ago

manurajsingh commented 3 years ago

Hello Daniel

I have a setup where Alfresco Content Repository is running in Docker and I have enabled following settings in docker compose file to allow for bearer JWT token to be method of authentication

-Dauthentication.chain=identity-service1:identity-service -Didentity-service.register-node-at-startup=true -Didentity-service.authentication.enabled=true -Didentity-service.authentication.enable-username-password-authentication=false -Didentity-service.bearer-only=true
-Didentity-service.realm-public-key=INTENTIONALLY BLANK

When attempting to reach admin console via above settings using Spring Cloud Gateway to generate token (all is ok).

When attempting to reach admin console via above settings, where token is issued by Authorisation Server (Apereo CAS), I get error saying Authorisation 'Bearer' not supported. I do get that same error when I attempt REST API calls.

I have found it is the issuer (iss) in JWT token payload that is different in my case. If I update iss to http://localhost:8180/auth/realms/alfresco , all is ok.

I cannot locate any setting on repository side that is looking for this validation.

Any insights will be useful.

The version of Afresco Content Repository that I am using is 6.2.0-ga Community edition.

Thanks in advance.

dgradecak commented 3 years ago

hi, I am sorry but I cannot help you with that kind of issue. Please use the issues on this project only for questions and issues related to the project itself or ask on alfresco hub.