title: Force AXIS client to use TLS
body: <p>How can I force a SOAP Axis client to use TLS instead of SSL? I have this code:</p>
  
  <pre><code>        SOAPMessage soapMessage = MessageFactory.newInstance()
                  .createMessage();
          SOAPPart soapPart = soapMessage.getSOAPPart();
          javax.xml.soap.SOAPEnvelope soapEnvelope = soapPart.getEnvelope();
  
          Service service = new Service();
          Call call = (Call) service.createCall();
          call.setTargetEndpointAddress(new java.net.URL(endpoint));
          call.setOperationStyle(org.apache.axis.constants.Style.DOCUMENT);
          call.setSOAPActionURI("urn:processDocument");
          call.setUsername(user);
          call.setPassword(password);
          call.setTimeout(10000);
          call.invoke(new Message(soapEnvelope.toString()));
  </code></pre>
  
  <p>The error on execution is: </p>
  
  <pre><code>javax.net.ssl.SSLException: Received fatal alert: unexpected_message
      at org.apache.axis.AxisFault.makeFault(AxisFault.java:101)
      at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:154)
      at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
      at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
      at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
      at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
      at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
      at org.apache.axis.client.Call.invoke(Call.java:2767)
      at org.apache.axis.client.Call.invoke(Call.java:1870)
      at TestTLSConnect.main(TestTLSConnect.java:100)
  </code></pre>
  
  <p>Also I activated SSL logging and I can see this:</p>
  
  <pre><code>main, WRITE: SSLv3 Handshake, length = 79
  main, READ: TLSv1 Alert, length = 2
  main, RECV TLSv1 ALERT:  fatal, unexpected_message
  </code></pre>
  
  <p>I tried setting the protocol with System.setProperty("https.protocols", "TLSv1");, but I get the same error and the same log message. </p>