Mercurial > dive4elements > river
changeset 5943:a96350a1c160
Pass trusted key filename to Response in WAS Authenticator.
author | Bernhard Herzog <bh@intevation.de> |
---|---|
date | Wed, 08 May 2013 17:56:14 +0200 |
parents | 92da396f80d7 |
children | d6f13dba21fe |
files | gwt-client/src/main/java/org/dive4elements/river/client/server/auth/was/Authenticator.java gwt-client/src/main/java/org/dive4elements/river/client/server/auth/was/Response.java |
diffstat | 2 files changed, 7 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/gwt-client/src/main/java/org/dive4elements/river/client/server/auth/was/Authenticator.java Wed May 08 17:56:14 2013 +0200 +++ b/gwt-client/src/main/java/org/dive4elements/river/client/server/auth/was/Authenticator.java Wed May 08 17:56:14 2013 +0200 @@ -62,7 +62,10 @@ return null; } else { - return new Response(entity, username, password, features); + String trustedKey = + (String)context.getInitParameter("saml-trusted-public-key"); + return new Response(entity, username, password, features, + context.getRealPath(trustedKey)); } } catch(GeneralSecurityException e) {
--- a/gwt-client/src/main/java/org/dive4elements/river/client/server/auth/was/Response.java Wed May 08 17:56:14 2013 +0200 +++ b/gwt-client/src/main/java/org/dive4elements/river/client/server/auth/was/Response.java Wed May 08 17:56:14 2013 +0200 @@ -39,7 +39,9 @@ private Features features; - public Response(HttpEntity entity, String username, String password, Features features) throws AuthenticationException, IOException { + public Response(HttpEntity entity, String username, String password, + Features features, String trustedKeyFile) + throws AuthenticationException, IOException { if (entity == null) { throw new ServiceException("Invalid response");