@Override
    public boolean handle(Request request, Response response, Callback callback) throws Exception {
        if (!isRequestToWhitelistedBinding(request) && !hasClientX509Certificate(request)) {
            Response.writeError(request, response, callback, HttpStatus.UNAUTHORIZED_401,
                    "Client did not present a x509 certificate, " +
                    "or presented a certificate not issued by any of the CA certificates in trust store.");
            return true;
        }
        return super.handle(request, response, callback);
    }
A Jetty handler that enforces TLS client authentication with configurable white list.

@author bjorncs
container-core/src/main/java/com/yahoo/jdisc/http/server/jetty/TlsClientAuthenticationEnforcer.java