class HeaderInterceptor implements Interceptor {
    private final Config config;

    private HeaderInterceptor(Config config) {
      this.config = config;
    }

    @Override
    public void before(BasicBuilder builder, HttpRequest request, RequestTags tags) {
      if (config.getCustomHeaders() != null && !config.getCustomHeaders().isEmpty()) {
        for (Map.Entry<String, String> entry : config.getCustomHeaders().entrySet()) {
          builder.header(entry.getKey(), entry.getValue());
        }
      }
      if (config.getUserAgent() != null && !config.getUserAgent().isEmpty()) {
        builder.setHeader("User-Agent", config.getUserAgent());
      }
    }
  }

  private static final Logger LOGGER = LoggerFactory.getLogger(HttpClientUtils.class);
  private static final String HEADER_INTERCEPTOR = "HEADER";
  private static final String KUBERNETES_BACKWARDS_COMPATIBILITY_INTERCEPTOR_DISABLE = "kubernetes.backwardsCompatibilityInterceptor.disable";
  private static final String BACKWARDS_COMPATIBILITY_DISABLE_DEFAULT = "true";
  private static final Pattern IPV4_PATTERN = Pattern.compile(
      "(http://|https://)?(?<ipAddressOrSubnet>(([01]?\\d\\d?|2[0-4]\\d|25[0-5])\\.){3}([01]?\\d\\d?|2[0-4]\\d|25[0-5])(\\/([1-2]\\d|3[0-2]|\\d))?)(\\D+|$)");
  private static final Pattern INVALID_HOST_PATTERN = Pattern.compile("[^\\da-zA-Z.\\-/:]+");

  private HttpClientUtils() {
  }

  static URI getProxyUri(URL master, Config config) throws URISyntaxException {
    String proxy = config.getHttpsProxy();
    if (master.getProtocol().equals("http")) {
      proxy = config.getHttpProxy();
    }
    if (proxy != null) {
      URI proxyUrl = new URI(proxy);
      if (proxyUrl.getPort() < 0) {
        throw new IllegalArgumentException("Failure in creating proxy URL. Proxy port is required!");
      }
      return proxyUrl;
    }
    return null;
  }

  public static Map<String, io.fabric8.kubernetes.client.http.Interceptor> createApplicableInterceptors(Config config,
      HttpClient.Factory factory) {<FILL_FUNCTION_BODY>

    Map<String, io.fabric8.kubernetes.client.http.Interceptor> interceptors = new LinkedHashMap<>();

    // Header Interceptor
    interceptors.put(HEADER_INTERCEPTOR, new HeaderInterceptor(config));
    // Impersonator Interceptor
    interceptors.put(ImpersonatorInterceptor.NAME, new ImpersonatorInterceptor(config.getRequestConfig()));
    // Token Refresh Interceptor
    interceptors.put(TokenRefreshInterceptor.NAME, new TokenRefreshInterceptor(config, factory, Instant.now()));
    // Backwards Compatibility Interceptor
    String shouldDisableBackwardsCompatibilityInterceptor = Utils
        .getSystemPropertyOrEnvVar(KUBERNETES_BACKWARDS_COMPATIBILITY_INTERCEPTOR_DISABLE,
            BACKWARDS_COMPATIBILITY_DISABLE_DEFAULT);
    if (!Boolean.parseBoolean(shouldDisableBackwardsCompatibilityInterceptor)) {
      interceptors.put(BackwardsCompatibilityInterceptor.NAME, new BackwardsCompatibilityInterceptor());
    }

    return interceptors;
  
<no_super_class>