mirror of
https://github.com/apache/httpcomponents-client.git
synced 2025-02-17 07:26:47 +00:00
Makes no sense to me but hope it will make VMWare happy
git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1603773 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
8ad27884ef
commit
3269410866
@ -108,7 +108,7 @@ public void testBasicSSL() throws Exception {
|
|||||||
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
||||||
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
||||||
final Socket socket = socketFactory.createSocket(context);
|
final Socket socket = socketFactory.createSocket(context);
|
||||||
final InetSocketAddress remoteAddress = new InetSocketAddress(this.server.getInetAddress(), this.server.getLocalPort());
|
final InetSocketAddress remoteAddress = new InetSocketAddress("localhost", this.server.getLocalPort());
|
||||||
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
||||||
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
||||||
try {
|
try {
|
||||||
@ -134,7 +134,7 @@ public void testClientAuthSSL() throws Exception {
|
|||||||
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
||||||
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
||||||
final Socket socket = socketFactory.createSocket(context);
|
final Socket socket = socketFactory.createSocket(context);
|
||||||
final InetSocketAddress remoteAddress = new InetSocketAddress(this.server.getInetAddress(), this.server.getLocalPort());
|
final InetSocketAddress remoteAddress = new InetSocketAddress("localhost", this.server.getLocalPort());
|
||||||
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
||||||
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
||||||
try {
|
try {
|
||||||
@ -161,7 +161,7 @@ public void testClientAuthSSLFailure() throws Exception {
|
|||||||
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
||||||
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
||||||
final Socket socket = socketFactory.createSocket(context);
|
final Socket socket = socketFactory.createSocket(context);
|
||||||
final InetSocketAddress remoteAddress = new InetSocketAddress(this.server.getInetAddress(), this.server.getLocalPort());
|
final InetSocketAddress remoteAddress = new InetSocketAddress("localhost", this.server.getLocalPort());
|
||||||
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
||||||
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
||||||
try {
|
try {
|
||||||
@ -200,7 +200,7 @@ public String chooseAlias(
|
|||||||
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
final SSLConnectionSocketFactory socketFactory = new SSLConnectionSocketFactory(
|
||||||
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
SSLTestContexts.createClientSSLContext(), hostVerifier);
|
||||||
final Socket socket = socketFactory.createSocket(context);
|
final Socket socket = socketFactory.createSocket(context);
|
||||||
final InetSocketAddress remoteAddress = new InetSocketAddress(this.server.getInetAddress(), this.server.getLocalPort());
|
final InetSocketAddress remoteAddress = new InetSocketAddress("localhost", this.server.getLocalPort());
|
||||||
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
||||||
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
||||||
try {
|
try {
|
||||||
@ -229,7 +229,7 @@ public void testSSLTrustVerification() throws Exception {
|
|||||||
SSLConnectionSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER);
|
SSLConnectionSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER);
|
||||||
|
|
||||||
final Socket socket = socketFactory.createSocket(context);
|
final Socket socket = socketFactory.createSocket(context);
|
||||||
final InetSocketAddress remoteAddress = new InetSocketAddress(this.server.getInetAddress(), this.server.getLocalPort());
|
final InetSocketAddress remoteAddress = new InetSocketAddress("localhost", this.server.getLocalPort());
|
||||||
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
||||||
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
||||||
sslSocket.close();
|
sslSocket.close();
|
||||||
@ -262,7 +262,7 @@ public boolean isTrusted(
|
|||||||
SSLConnectionSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER);
|
SSLConnectionSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER);
|
||||||
|
|
||||||
final Socket socket = socketFactory.createSocket(context);
|
final Socket socket = socketFactory.createSocket(context);
|
||||||
final InetSocketAddress remoteAddress = new InetSocketAddress(this.server.getInetAddress(), this.server.getLocalPort());
|
final InetSocketAddress remoteAddress = new InetSocketAddress("localhost", this.server.getLocalPort());
|
||||||
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
final HttpHost target = new HttpHost("localhost", this.server.getLocalPort(), "https");
|
||||||
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
final SSLSocket sslSocket = (SSLSocket) socketFactory.connectSocket(0, socket, target, remoteAddress, null, context);
|
||||||
sslSocket.close();
|
sslSocket.close();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user