oauth redirection problem

57 views
Skip to first unread message

Leo Pintos

unread,
Jan 10, 2018, 8:20:19 AM1/10/18
to CAS Community
Hi Guys!

I'm trying to configure oauth but I have some problems with the "redirect uri" after the success login
I put the below configuration in my json registered service:
{
"@class" : "org.apereo.cas.support.oauth.
services.OAuthRegisteredService",
"clientId": "app_prueba",
"clientSecret": "clientSecret",
"bypassApprovalPrompt": true,
"generateRefreshToken": false,
"serviceId" : "^https://localhost:8443/clienteoauth/recepcionCode",
"name" : "MyOAuthservice",
"id" : 10000002,
}

and I call the service with:
https://localhost:8443/cas/oauth2.0/authorize?response_type=code&client_id=app_prueba&redirect_uri=https://localhost:8443/clienteoauth/recepcionCode

After the success login the app redirect to the server page(wildfly page) and not to the "redirect_uri"
I can see the following in the log:

2018-01-10 10:11:31,397 DEBUG [org.apereo.cas.support.oauth.web.OAuth20CasCallbackUrlResolver] (default task-3) Final resolved callback URL is [https://localhost:8443/cas/oauth2.0/callbackAuthorize?client_name=CasOAuthClient&client_id=app_prueba&redirect_uri=https://localhost:8443/clienteoauth/recepcionCode]
2018-01-10 10:11:31,397 DEBUG [org.apereo.cas.support.oauth.web.response.OAuth20DefaultCasClientRedirectActionBuilder] (default task-3) Final redirect url is [https://localhost:8443/cas/login?service=https%3A%2F%2Flocalhost%3A8443%2Fcas%2Foauth2.0%2FcallbackAuthorize%3Fclient_name%3DCasOAuthClient%26client_id%3Dapp_prueba%26redirect_uri%3Dhttps%3A%2F%2Flocalhost%3A8443%2Fclienteoauth%2FrecepcionCode]
.
.
.
2018-01-10 10:11:41,708 DEBUG [org.apereo.cas.support.oauth.web.OAuth20CasCallbackUrlResolver] (default task-9) Final resolved callback URL is [https://localhost:8443/cas/oauth2.0/callbackAuthorize?client_name=CasOAuthClient&client_id=app_prueba&redirect_uri=https://localhost:8443/clienteoauth/recepcionCode]
2018-01-10 10:11:42,160 DEBUG [org.apereo.cas.support.oauth.validator.OAuth20AuthenticationServiceSelectionStrategy] (default task-12) Authentication request isidentified as an OAuth request

Any help?
Thanks in advance.
Leo.
Reply all
Reply to author
Forward
0 new messages