private HttpURLConnection getSecureConnection(URL url) throws IOException {
    AuthenticatedURL.Token token = new AuthenticatedURL.Token();
    try {
      return new AuthenticatedURL().openConnection(url, token);
    } catch (AuthenticationException e) {
      throw new IOException(e);
    }
  }
Gets the Hadoop kerberos secure connection (not an SSL connection).
ql/src/java/org/apache/hadoop/hive/ql/exec/tez/YarnQueueHelper.java