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 6670467
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T03:16:21+00:00 2026-05-26T03:16:21+00:00

I need to consume an AXIS 1.4 Web service over SSL from a .NET

  • 0

I need to consume an AXIS 1.4 Web service over SSL from a .NET client. Currently we implement the System.Net.WebClient, we hand create the XML request and upload it to the web service. This works great for getting back valid results, however if an exception occurs (java.rmi.RemoteException) we only get back a WebException of “Interal Server Error”. Inspecting the response yields no more detail.

If we add the service in Visual Studio 2010 as a .NET 2.0 Web Reference (SoapHttpClientProtocol) we receive the desired java.rmi.RemoteException with all the necessary details to rectify the problem. However, all resulting responses from a valid request are null.

Note: This service is being consumed successfully by other (competitors’) .NET Clients (to which we do not have the source code).

To reiterate: A valid request via WebClient receives valid response objects but every exception is an “Internal Server Error”, a valid request via Web Reference receives null responses but will accurately display the desired java.rmi.RemoteException.

The goal: Valid responses along with complete java.rmi.RemoteExceptions (not vague Internal Server Errors), even if I can get a SoapException to be thrown that’d be a huge improvment.

IDE: Visual Studio 2010 SP1

OS: Windows 7

.NET: 2.0/3.5/4.0 (I have attempted all three versions with the same results)

Language: C#

Example WebClient code:

var lvResult = "";

        try
        {
            var lvStr = "sample request";
            var client = new WebClient();
            client.Headers.Add("SOAPAction", "SampleRequest");

            lvResult = client.UploadString(cvURL, lvStr);
        }
        catch (Exception ex)
        {

        }

UPDATE: To be more specific, this wouldn’t be a problem if a Soap exception was being thrown, however the only exception thrown is a “WebException” which doesn’t seem to give me access to the faultstring. Below is the raw soap fault I’m receiving from the AXIS service:

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <soapenv:Body>
<soapenv:Fault>
  <faultcode>soapenv:Server.userException</faultcode>
  <faultstring>java.rmi.RemoteException: Error in posting Request: Code 02 - No UserId for this user name/password.</faultstring>
  <detail>
    <ns1:hostname xmlns:ns1="http://xml.apache.org/axis/">xxxx</ns1:hostname>
  </detail>
</soapenv:Fault>

SOLUTION: I found a workaround by catching the WebException, and grabbing the response stream for the exception response –

    catch(WebException pvEx)
    {
        var lvResponseString = "";

        if (pvEx.Response != null)
        {
            using (var lvStreamReader = new StreamReader(pvEx.Response.GetResponseStream()))
            {
                //This string now contains the xml soap response
                lvResponseString = lvStreamReader.ReadToEnd(); 
            }
        }

    }
  • 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-05-26T03:16:21+00:00Added an answer on May 26, 2026 at 3:16 am

    This is a post on exactly the problem you have: http://bytes.com/topic/net/answers/427757-soap-faults.

    I think your AXIS service IS returning a SOAPFAULT. You just need to know how to deal with it in your .NET client. And that is described in this post.

    Best regards,
    Marco Kroonwijk

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

Sidebar

Related Questions

I need to consume a SOAP web service from a C# .Net 4.0 client.
I need to consume web services from a .NET web service and serve up
I need to consume a REST web service from my android device. I have
From a .NET application, how do I consume a Web Service developed using gSoap
I need to consume a Web Service via SSL. In order to accomplish that
We need to consume a SOAP 1.1 Web Service, developed using Java, from within
I need to consume an existing web service in ASP.net. The documentation of the
I need to consume an external web service from my VB6 program. I want
I am developing an Android app which need to consume .Net webservices over SSL
I have a web service that I need to consume from BizTalk orchestration. I've

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.