Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8221378

No socks support in java.net.Httpclient

    Details

    • Subcomponent:
    • CPU:
      x86_64
    • OS:
      windows_10

      Description

      ADDITIONAL SYSTEM INFORMATION :
      all os, jdk 11

      A DESCRIPTION OF THE PROBLEM :
      New API java.net.http doesn't support SOCKS. I tried sth like:

      HttpClient.newBuilder().proxy(new ProxySelector() {
      @Override
      public List<Proxy> select(URI uri) {
      return Arrays.asList(socks);
      }

      @Override
      public void connectFailed(URI uri, SocketAddress sa, IOException ioe) {
      System.out.println(socks + ": " + ioe);
      }

      })

      but it goes direct. It doesn't show any error. Maybe add an error that socks is not supported or add socks support, please.


        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                psonal Pallavi Sonal (Inactive)
                Reporter:
                webbuggrp Webbug Group
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: