[cas-user] Re: CAS redirecting to multiple apps not working

2018-05-23 Thread Andy Ng
Hi Érico,

Likely your colleague have done some customization on CAS. Default CAS only 
have a username, password and some other things, and login success won't 
immediately have redirection links

so, I think a little bit more information will be needed, in order to start 
solving your problem:
- What are the redirection links? You can blur out the server detail, but 
something "app1 redirection links is 
http://localhost:8080/cas?service=http://www.example.com/app1"; will tell us 
more about your problem
- You said sends me to login page, you mean send you back to 
"http://localhost:8080/cas"; correct? If so, any parameter attached? 

Another thing, CAS don't work / don't work well with http, try setup to 
https. I don't use JBoss myself so I won't be able to help on that.

Cheers!
- Andy




On Wednesday, 23 May 2018 21:14:30 UTC+8, Érico Teixeira wrote:
>
> Hello 
>
> I've started woking on a set of apps developed by another programmer 
>
> I login through http://localhost:8080/cas that contains a menu with the 
> redirection for the other apps 
>
> This redirection is not working ... I've deployed other 2 apps along with 
> CAS(5.1) and all are successfully deployed :
>
> CAS and app1 in jboss EAP 7 running in 8080 
>
> app2 through spring boot running in 8090 
>
> Both app1 and app2 behave the same way ... I click on their menus and the 
> redirection sends me to login page instead of redirecting me to app1 or 
> app2 
>
> There are no erros on jboss logs 
>
> There are no erros on network tab in firefox or chrome 
>
> I don't know what other info I could past here to simulate the error 
>
> Please, I am stuck on this for a few days and don't know what else to 
> investigate
>
> Thks
> Érico
>

-- 
- Website: https://apereo.github.io/cas
- Gitter Chatroom: https://gitter.im/apereo/cas
- List Guidelines: https://goo.gl/1VRrw7
- Contributions: https://goo.gl/mh7qDG
--- 
You received this message because you are subscribed to the Google Groups "CAS 
Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cas-user+unsubscr...@apereo.org.
To view this discussion on the web visit 
https://groups.google.com/a/apereo.org/d/msgid/cas-user/8f1bcce1-f1b9-4cb6-a68c-6bde820867e2%40apereo.org.


Re: [cas-user] Re: CAS redirecting to multiple apps not working

2018-05-23 Thread Érico
Hello Andy

thanks a lot for your help

the app1 link is the following :
http://localhost:8080/cas/login?service=http%3A%2F%2Flocalhost%3A8080%2Fregistro-acidente%2Flogin%2Fcas

regarding login page ... yes it is  http://localhost:8080/cas then
http://localhost:8080/cas/login
I am sending the login header and parameters attached on this mail

I am also sending my /private/etc/cas/config/cas.properties

the directory privileges are the following :

ls -la /private/etc/cas
total 32
drwxrwxrwx@   7 ericomartins  wheel   224 16 Mai 10:09 .
drwxr-xr-x@ 121 root  wheel  3872 18 Mai 09:33 ..
-rw-r--r--@   1 ericomartins  wheel  8196 22 Mai 09:28 .DS_Store
drwxr-xr-x@   5 ericomartins  wheel   160 23 Abr 10:41 config
drwxrwxrwx@   5 ericomartins  wheel   160 16 Mai 09:34 config-old
drwxrwxrwx@   6 ericomartins  wheel   192 22 Mai 10:40 logs
-rwxr-xr-x1 ericomartins  wheel  1951 15 Mai 09:41 thekeystore

CAS app has a application.properties file with the following :

server.context-path=/cas

server.port=8443

#server.ssl.key-store=file:/etc/cas/thekeystore

server.ssl.key-store=file:/private/etc/cas/thekeystore

server.ssl.key-store-password=changeit

server.ssl.key-password=changeit

Best Regards
Érico




2018-05-23 11:05 GMT-03:00 Andy Ng :

> Hi Érico,
>
> Likely your colleague have done some customization on CAS. Default CAS
> only have a username, password and some other things, and login success
> won't immediately have redirection links
>
> so, I think a little bit more information will be needed, in order to
> start solving your problem:
> - What are the redirection links? You can blur out the server detail, but
> something "app1 redirection links is http://localhost:8080/cas?
> service=http://www.example.com/app1"; will tell us more about your problem
> - You said sends me to login page, you mean send you back to "
> http://localhost:8080/cas"; correct? If so, any parameter attached?
>
> Another thing, CAS don't work / don't work well with http, try setup to
> https. I don't use JBoss myself so I won't be able to help on that.
>
> Cheers!
> - Andy
>
>
>
>
> On Wednesday, 23 May 2018 21:14:30 UTC+8, Érico Teixeira wrote:
>>
>> Hello
>>
>> I've started woking on a set of apps developed by another programmer
>>
>> I login through http://localhost:8080/cas that contains a menu with the
>> redirection for the other apps
>>
>> This redirection is not working ... I've deployed other 2 apps along with
>> CAS(5.1) and all are successfully deployed :
>>
>> CAS and app1 in jboss EAP 7 running in 8080
>>
>> app2 through spring boot running in 8090
>>
>> Both app1 and app2 behave the same way ... I click on their menus and the
>> redirection sends me to login page instead of redirecting me to app1 or
>> app2
>>
>> There are no erros on jboss logs
>>
>> There are no erros on network tab in firefox or chrome
>>
>> I don't know what other info I could past here to simulate the error
>>
>> Please, I am stuck on this for a few days and don't know what else to
>> investigate
>>
>> Thks
>> Érico
>>
> --
> - Website: https://apereo.github.io/cas
> - Gitter Chatroom: https://gitter.im/apereo/cas
> - List Guidelines: https://goo.gl/1VRrw7
> - Contributions: https://goo.gl/mh7qDG
> ---
> You received this message because you are subscribed to the Google Groups
> "CAS Community" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cas-user+unsubscr...@apereo.org.
> To view this discussion on the web visit https://groups.google.com/a/
> apereo.org/d/msgid/cas-user/8f1bcce1-f1b9-4cb6-a68c-
> 6bde820867e2%40apereo.org
> 
> .
>

-- 
- Website: https://apereo.github.io/cas
- Gitter Chatroom: https://gitter.im/apereo/cas
- List Guidelines: https://goo.gl/1VRrw7
- Contributions: https://goo.gl/mh7qDG
--- 
You received this message because you are subscribed to the Google Groups "CAS 
Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cas-user+unsubscr...@apereo.org.
To view this discussion on the web visit 
https://groups.google.com/a/apereo.org/d/msgid/cas-user/CAORQCTLkJy3U-mp1tadOg0wYhgvkMePp9ib9foj37DcPhmbS0Q%40mail.gmail.com.

Response headers (1,066 KB) 
Cache-Control   
no-store
Connection  
keep-alive
Content-Language
pt-BR
Content-Type
text/html;charset=UTF-8
Date
Wed, 23 May 2018 14:10:43 GMT
Expires 
Pragma  
Server  
JBoss-EAP/7
Set-Cookie  
TGC=eyJhbGciOiJIUzUxMiJ9.WlhsS… path=/cas/; secure; HttpOnly
Transfer-Encoding   
chunked
X-Content-Type-Options  
nosniff
X-Frame-Options 
DENY
X-Powered-By
Undertow/1
X-XSS-Protection
1; mode=block
Request headers (577 B) 
Accept  
text/html,application/xhtml+xm…plication/xml;q=0.9,*/*;q=0.8
Accept-Encoding 
gzip, deflate
Accept-Language 
pt-BR,pt;q=0.8,en-US;q=0.5,en;q=0.3
Connection  
keep-aliv

Re: [cas-user] Re: CAS redirecting to multiple apps not working

2018-05-23 Thread Andy Ng
Hi Érico,

Pretty sure CAS Single Sign On (SSO) only works with https, you can try the 
following yourself:
- Login to "http://localhost:8080/cas";
- Immediately refresh the page
>From my experience, you might not see yourself not login again, because SSO 
is not working properly with http.

Anyway, my point is, you need to make your CAS use https first.

I am not familiar with JBoss, but if you go to 
https://localhost:8443/cas/login now, will you be able to see the page? If 
not then probably thekeystore is not loaded properly
See if this section helps 
you: https://github.com/apereo/cas-overlay-template#deployment

Another point might be, with you link:
http://localhost:8080/cas/login?service=http%3A%2F%2Flocalhost%3A8080%2Fregistro-acidente%2Flogin%2Fcas
it will actually first check if you are login first, then redirect you to:
http://localhost:8080/registro-acidente/login/cas

So, you have an JBoss application located at here? 
http://localhost:8080/registro-acidente

CAS 5 by default do not have this url "
http://localhost:8080/registro-acidente/...  ", if that is your app1 / app2 
link, then that's fine

Cheers!
-Andy


On Wednesday, 23 May 2018 22:19:58 UTC+8, Érico Teixeira wrote:
>
> Hello Andy 
>
> thanks a lot for your help 
>
> the app1 link is the following : 
>
> http://localhost:8080/cas/login?service=http%3A%2F%2Flocalhost%3A8080%2Fregistro-acidente%2Flogin%2Fcas
>
> regarding login page ... yes it is  http://localhost:8080/cas then 
> http://localhost:8080/cas/login
> I am sending the login header and parameters attached on this mail
>
> I am also sending my /private/etc/cas/config/cas.properties 
>
> the directory privileges are the following : 
>
> ls -la /private/etc/cas
> total 32
> drwxrwxrwx@   7 ericomartins  wheel   224 16 Mai 10:09 .
> drwxr-xr-x@ 121 root  wheel  3872 18 Mai 09:33 ..
> -rw-r--r--@   1 ericomartins  wheel  8196 22 Mai 09:28 .DS_Store
> drwxr-xr-x@   5 ericomartins  wheel   160 23 Abr 10:41 config
> drwxrwxrwx@   5 ericomartins  wheel   160 16 Mai 09:34 config-old
> drwxrwxrwx@   6 ericomartins  wheel   192 22 Mai 10:40 logs
> -rwxr-xr-x1 ericomartins  wheel  1951 15 Mai 09:41 thekeystore
>
> CAS app has a application.properties file with the following : 
>
> server.context-path=/cas
>
> server.port=8443
>
> #server.ssl.key-store=file:/etc/cas/thekeystore
>
> server.ssl.key-store=file:/private/etc/cas/thekeystore
>
> server.ssl.key-store-password=changeit
>
> server.ssl.key-password=changeit
>
> Best Regards
> Érico
>
>
>
>
> 2018-05-23 11:05 GMT-03:00 Andy Ng >:
>
>> Hi Érico,
>>
>> Likely your colleague have done some customization on CAS. Default CAS 
>> only have a username, password and some other things, and login success 
>> won't immediately have redirection links
>>
>> so, I think a little bit more information will be needed, in order to 
>> start solving your problem:
>> - What are the redirection links? You can blur out the server detail, but 
>> something "app1 redirection links is 
>> http://localhost:8080/cas?service=http://www.example.com/app1"; will tell 
>> us more about your problem
>> - You said sends me to login page, you mean send you back to "
>> http://localhost:8080/cas"; correct? If so, any parameter attached? 
>>
>> Another thing, CAS don't work / don't work well with http, try setup to 
>> https. I don't use JBoss myself so I won't be able to help on that.
>>
>> Cheers!
>> - Andy
>>
>>
>>
>>
>> On Wednesday, 23 May 2018 21:14:30 UTC+8, Érico Teixeira wrote:
>>>
>>> Hello 
>>>
>>> I've started woking on a set of apps developed by another programmer 
>>>
>>> I login through http://localhost:8080/cas that contains a menu with the 
>>> redirection for the other apps 
>>>
>>> This redirection is not working ... I've deployed other 2 apps along 
>>> with CAS(5.1) and all are successfully deployed :
>>>
>>> CAS and app1 in jboss EAP 7 running in 8080 
>>>
>>> app2 through spring boot running in 8090 
>>>
>>> Both app1 and app2 behave the same way ... I click on their menus and 
>>> the redirection sends me to login page instead of redirecting me to app1 or 
>>> app2 
>>>
>>> There are no erros on jboss logs 
>>>
>>> There are no erros on network tab in firefox or chrome 
>>>
>>> I don't know what other info I could past here to simulate the error 
>>>
>>> Please, I am stuck on this for a few days and don't know what else to 
>>> investigate
>>>
>>> Thks
>>> Érico
>>>
>> -- 
>> - Website: https://apereo.github.io/cas
>> - Gitter Chatroom: https://gitter.im/apereo/cas
>> - List Guidelines: https://goo.gl/1VRrw7
>> - Contributions: https://goo.gl/mh7qDG
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "CAS Community" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cas-user+u...@apereo.org .
>> To view this discussion on the web visit 
>> https://groups.google.com/a/apereo.org/d/msgid/cas-user/8f1bcce1-f1b9-4cb6-a68c-6bde820867e2%40apereo.org
>>  
>