Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7728161
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T05:38:55+00:00 2026-06-01T05:38:55+00:00

I have to access the webservice with 2 way authentication. Below is my approach.

  • 0

I have to access the webservice with 2 way authentication. Below is my approach.

Created MyCustomSSLSocketFactory class.

  1. Loaded TrustManagers
  2. Loaded Keystore Managers
  3. Created SSL Context and SSL socket factory as below.

I call this class method just before calling webservice method.

Then i have done as below:-

AxisProperties.setProperty("axis.socketSecureFactory",
                            "com.elipva.zephyr.twofa.util.MyCustomSSLSocketFactory");

Security.setProperty("ssl.SocketFactory.provider",
                    "com.elipva.zephyr.twofa.util.MyCustomSSLSocketFactory");


SSLContext context = SSLContext.getInstance(protocolVersion);
context.init(keyManagers, trustManagers, null);
SSLSocketFactory socketFactory = context.getSocketFactory();

URL url = new URL(urlString);
URLConnection connection = url.openConnection();
  if (connection instanceof HttpsURLConnection) {
    ((HttpsURLConnection) connection)
                .setSSLSocketFactory(sslSocketFactory);

            connection.connect();
        }   

when i access the webservice it gives me below error.

org.apache.axis2.AxisFault: Unconnected sockets not implemented
    at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)
    at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:203)
    at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:76)
    at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:400)
    at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:225)
    at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:435)
    at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:402)
    at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229)
    at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165)

Please let me know if i am missing anything.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T05:38:56+00:00Added an answer on June 1, 2026 at 5:38 am

    I think it could be this Java bug – https://bugs.java.com/bugdatabase/view_bug?bug_id=6771432

    Note that this is supposedly fixed in java 1.6.0_u14

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created a Java web service and I am trying to access this
I have a webservice that's behind form's authentication. The site that hosts the service
I have a C# .net webservice that I need to restrict access to. I
I have created a Web service using Netbeans', JEE6 and Jersey - Webservice from
SCENARIO I have to access a web service with a .NET client. The service
I have a web service that I want to access when it is added
I have an ASP.NET web service that I can access via a windows program
I have My Sharepoint Web Service URL, but when i try to access it
I have access to a virtual machine via vmware client and want to do
I have access to a joomla edition but not the source, and I need

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.