teichmann@5861: /* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde teichmann@5861: * Software engineering by Intevation GmbH teichmann@5861: * teichmann@5993: * This file is Free Software under the GNU AGPL (>=v3) teichmann@5861: * and comes with ABSOLUTELY NO WARRANTY! Check out the teichmann@5993: * documentation coming with Dive4Elements River for details. teichmann@5861: */ teichmann@5861: teichmann@5835: package org.dive4elements.river.client.server; bjoern@2949: bjoern@2949: import java.security.cert.CertificateException; bjoern@2949: import java.security.cert.X509Certificate; bjoern@2949: bjoern@2949: import org.apache.http.conn.ssl.TrustStrategy; bjoern@2949: bjoern@2949: public class GGInATrustStrategy implements TrustStrategy { bjoern@2949: bjoern@2949: /** christian@6198: * Temporary class to accept all certificates for GGinA Authentication. bjoern@2949: */ bjoern@2949: bjoern@2949: @Override tom@8856: public boolean isTrusted( tom@8856: X509Certificate[] chain, tom@8856: String authType tom@8856: ) throws CertificateException { bjoern@2949: // FIXME validate Certificate bjoern@2949: return true; bjoern@2949: } bjoern@2949: } bjoern@2949: