BasicAuthOptions options = new BasicAuthOptions(api.getEndpointProperties()); if (options.getUsername() != null && options.getPassword() != null) { if (options.isRequireSSL() && !isSsl) {
BasicAuthOptions options = new BasicAuthOptions(api.getEndpointProperties()); if (options.getUsername() != null && options.getPassword() != null) { if (options.isRequireSSL() && !isSsl) {
private void verifyConnection() { switch (options.getRequiredAuthType()) { case BASIC: basicOptions = new BasicAuthOptions(api.getEndpointProperties()); if (!options.isSsl() && basicOptions.isRequireSSL()) throw new ConnectorException("Endpoint security requested (BASIC auth) but endpoint is not secure (SSL)."); break; case MTLS: if (!options.isSsl()) throw new ConnectorException("Mutual TLS specified, but endpoint is not HTTPS."); break; case DEFAULT: break; } }