code: @SuppressWarnings("StringSplitter")
      private boolean matchNonProxy(final URL url) {
          final String host = url.getHost();
  
          // code partially from org.apache.maven.plugins.site.AbstractDeployMojo#getProxyInfo
          final String nonProxyHosts = settings.getString(Settings.KEYS.PROXY_NON_PROXY_HOSTS);
          if (null != nonProxyHosts) {
              final String[] nonProxies = nonProxyHosts.split("(,)|(;)|(\\|)");
              for (final String nonProxyHost : nonProxies) {
                  //if ( StringUtils.contains( nonProxyHost, "*" ) )
                  if (null != nonProxyHost && nonProxyHost.contains("*")) {
                      // Handle wildcard at the end, beginning or middle of the nonProxyHost
                      final int pos = nonProxyHost.indexOf('*');
                      final String nonProxyHostPrefix = nonProxyHost.substring(0, pos);
                      final String nonProxyHostSuffix = nonProxyHost.substring(pos + 1);
                      // prefix*
                      if (!StringUtils.isEmpty(nonProxyHostPrefix) && host.startsWith(nonProxyHostPrefix) && StringUtils.isEmpty(nonProxyHostSuffix)) {
                          return true;
                      }
                      // *suffix
                      if (StringUtils.isEmpty(nonProxyHostPrefix) && !StringUtils.isEmpty(nonProxyHostSuffix) && host.endsWith(nonProxyHostSuffix)) {
                          return true;
                      }
                      // prefix*suffix
                      if (!StringUtils.isEmpty(nonProxyHostPrefix) && host.startsWith(nonProxyHostPrefix) && !StringUtils.isEmpty(nonProxyHostSuffix)
                              && host.endsWith(nonProxyHostSuffix)) {
                          return true;
                      }
                  } else if (host.equals(nonProxyHost)) {
                      return true;
                  }
              }
          }
          return false;
      }
docs: Check if host name matches nonProxy settings
  
  @param url the URL to connect to
  @return matching result. true: match nonProxy