title: How to enable TLS 1.1 and 1.2 for android 4.1.1
body: <p>I am using Android version 4.4 And try o call a web service through HttpTransportSE but my server is not responding because of TLS is not enabled. how to enable please help. my code for http class is below :</p>
  <pre><code>String jsonData = &quot;&quot;;
      String NameSpace = &quot;http://tempuri.org/&quot;;
      String MethodNameGodown = &quot;&quot;, SOAP_ACTION = &quot;&quot;;
      SoapPrimitive response = null;
      MethodNameGodown = &quot;MethodName&quot;;
      SOAP_ACTION = NameSpace + MethodNameGodown;
  
      SoapObject soapObject = new SoapObject(NameSpace, MethodNameGodown);
  
      soapObject.addProperty(&quot;UserID&quot;, username);
      soapObject.addProperty(&quot;Password&quot;, password);
      soapObject.addProperty(&quot;ESN&quot;, &quot;xym&quot;);
      SoapSerializationEnvelope soapEnvelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
      soapEnvelope.dotNet = true;
      soapEnvelope.setOutputSoapObject(soapObject);
  
      HttpTransportSE androidHttpTransport = new HttpTransportSE(sharedPreferences.getString(&quot;server_Middleware&quot;, &quot;&quot;), Constants.loginScreenTimeOut);
  
     
      try {
          androidHttpTransport.call(SOAP_ACTION, soapEnvelope);
          response = (SoapPrimitive) soapEnvelope.getResponse();
  
      } catch (IOException e) {
          e.printStackTrace();
      } catch (XmlPullParserException e) {
          e.printStackTrace();
      }
      return response + &quot;&quot;;
  </code></pre>