google-code-export / rubycas-client

Automatically exported from code.google.com/p/rubycas-client
1 stars 1 forks source link

Request to reopen Ticket 35 #43

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Request XML (without ActiveResource) from a Rails application that is 
protected by CAS
2. Requesting AJAX widget should NOT handle 401.
3. 401 will cause call to fail.

What is the expected output? What do you see instead?

In the general case, the Rails app should simply reauthenticate with CAS, 
avoiding service disruption.

What version of the product are you using? On what operating system?

Rubycas-client 2.2.1.1 with a Rails 2.3.11 application.

Please provide any additional information below.

This patch seems to be ActiveResource specific.  It is requested that it be 
broken out into a separate adapter instead, since it accomodates a specific 
application more than the general case.

Original issue reported on code.google.com by J.Mark.B...@gmail.com on 31 May 2012 at 7:55

GoogleCodeExporter commented 9 years ago
It's up to you to catch the 401 response and force re-authentication.

I guess maybe rubycas-client could detect that XHR request and return some 
javascript to force redirection of the whole browser window to the cas server, 
but this really feels like something you should be handling in your app instead 
of expecting rubycas-client to do it for you.

Original comment by matt.zuk...@gmail.com on 22 Jun 2012 at 5:47

GoogleCodeExporter commented 9 years ago
The point is that the behavior of rubycas-client is abnormal and exists 
apparently only to accommodate the peculiar requirements of ActiveResource, 
making your rather defensive response somewhat ironic.  No matter, that is why 
projects are forked.

Original comment by J.Mark.B...@gmail.com on 23 Jun 2012 at 2:53