Jerome, Do you know where the encoding is coming from? It looks like you're getting double-encoded (which is why CAS sees the encoded version).
Cheers, Scott On Tue, Aug 9, 2011 at 11:24 AM, Jerome Steunenberg <[email protected]>wrote: > Hi Bill, > > Thanks for your help. Did I say UTF-8 encoded ? I meant URL encoded! Sorry > about that. > > Anyway, I've tried putting > https://pguh-bi/jasperserver-pro/j_acegi_cas_security_check in the service > registry but I get: > <ServiceManagement: Unauthorized Service Access. Service > [https%253A%252F%252Fpguh-bi%252Fjasperserver-pro%252Fj_acegi_cas_security_check] > not found in Service Registry.> > > If I put > https%253A%252F%252Fpguh-bi%252Fjasperserver-pro%252Fj_acegi_cas_security_check > in the service registry, it works fine. > > Apparently, if you put http** in the service registry, it works but you get > the following error: > 011-08-09 10:46:11,903 WARN [org.jasig.cas.util.HttpClient] - <Error > Sending message to url endpoint > [https%253A%252F%252Fpguh-bi%252Fjasperserver-pro%252Fj_acegi_cas_security_check]. > Error is [no protocol: > https%253A%252F%252Fpguh-bi%252Fjasperserver-pro%252Fj_acegi_cas_security_check]> > > If you put the complete URL-encoded in the service registry then somehow > CAS is able to use that URL but not otherwise. Strange... > > Authentication seems to work fine now. > Thanks for your help, > > Jerome > > ----- Original Message ----- > From: "William G. Thompson, Jr." <[email protected]> > To: [email protected] > Sent: Monday, August 8, 2011 6:45:57 PM > Subject: Re: [cas-user] UTF-8 encoding of callback URL > > Hi Jerome, > > The service parameter in the redirect URL is URL Encoded. Try putting > this in the services registry: > https://pguh-bi/jasperserver-pro/j_acegi_cas_security_check > > Bill > > http://meyerweb.com/eric/tools/dencoder/ > > > > On Mon, Aug 8, 2011 at 11:45 AM, Jerome Steunenberg > <[email protected]> wrote: > > Hello, > > > > I'm using CAS 3.4.4 successfully for authentication of two apps behind > mod_auth_cas and phpCAS. > > Now, I'm working on adding a third app behind a > org.springframework.security.providers.cas.CasAuthenticationProvider > (Jasperserver). > > The redirect to the CAS server works fine but the callback URL is UTF-8 > encoded and looks like this: > > > > > https://sso/cas/login?service=https%25253A%25252F%25252Fpguh-bi%25252Fjasperserver-pro%25252Fj_acegi_cas_security_check > > sso is the CAS server and pguh-bi is the Tomcat webapp that I want to > CASify. > > > > So, the problem is that CAS gives this error: > > 2011-08-08 15:04:13,425 WARN > [org.jasig.cas.CentralAuthenticationServiceImpl] - <ServiceManagement: > Unauthorized Service Access. Service > [http%253A%252F%252Fpguh-bi%252Fjasperserver-pro%252Fj_acegi_cas_security_check] > not found in Service Registry.> > > > > I can solve this by making sure that the URL is authorized by the > in-memory data store for the ServiceRegistry: > > <bean > class="org.jasig.cas.services.RegisteredServiceImpl"> > > <property name="id" value="4" /> > > <property name="name" value="PGUH-BI" /> > > <property name="description" value="Allow PGUH-BI > UTF8 encoded URL" /> > > <property name="serviceId" value="http**" /> > > </bean> > > > > But that's not very clean and now I get the following error: > > > > 2011-08-08 17:21:44,968 WARN [org.jasig.cas.util.HttpClient] - <Error > Sending message to url endpoint > [https%253A%252F%252Fpguh-bi%252Fjasperserver-pro%252Fj_acegi_cas_security_check]. > Error is [no protocol: > https%253A%252F%252Fpguh-bi%252Fjasperserver-pro%252Fj_acegi_cas_security_check]> > > > > because https%253A%252F%252F is not recognized as a correct URL. > > > > Does anybody know how I can solve this ? Is this a CAS config problem or > a springframework config problem ? > > > > Cheers, > > > > Jerome Steunenberg > > > > -- > > You are currently subscribed to [email protected] as: > [email protected] > > To unsubscribe, change settings or access archives, see > http://www.ja-sig.org/wiki/display/JSG/cas-user > > > > -- > You are currently subscribed to [email protected] as: > [email protected] > To unsubscribe, change settings or access archives, see > http://www.ja-sig.org/wiki/display/JSG/cas-user > > > -- > You are currently subscribed to [email protected] as: > [email protected] > To unsubscribe, change settings or access archives, see > http://www.ja-sig.org/wiki/display/JSG/cas-user > > -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-user
