Simple Java client for accessing Shibboleth-protected services?

Richard Eckart de Castilho richard.eckart at gmail.com
Thu Jun 13 16:59:43 EDT 2013


Hi,

I am looking for a simplistic HTTP client which is able to transparently authenticate a communication with a Shibboleth-protected web-service. 

I have started hacking a wrapper around the Apache DefaultHttpClient class, implementing the same HttpClient interface. It authenticates the first time a communication is done, but only the first time. Once the authentication becomes outdated, it currently doesn't work anymore. Now before going on working on this, I'd really like to know if there is nothing similar already.

Looking around a bit, I found some apparently related code, e.g. in org.jasig's deletagated-saml-authentication (HttpRequestPreprocessor , HttpRequestPostprocessor, SAMLDelegatedAuthenticationService, etc.) but no clear example documentation how these really work.

I find it hard to imagine that nobody ever needed/wanted a simple way to communicate with a Shibboleth-protected service. Something as easy as:

ShibbolethHttpClient client = new ShibbolethHttpClient();
client.setUsername(aUsername);
client.setPassword(aPassword);
client.setIdpUrl(aIdpUrl);
client.setSpUrl(aBaseUrl);

Does anybody know of such a simple client? I'd write it, but I'd really prefer using something that's already around, or at least building on something that's already around. 

Cheers,

-- Richard


More information about the users mailing list