Re: Soap SSL Communication

"Scott Nichol" <[email protected]>
Newsgroups gmane.text.xml.soap.devel
Message-ID <[email protected]>
Some docs for using SOAP with SSL are included in the distribution and can
also be found on-line at
http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-soap/java/docs/install/FAQ_
Tomcat_SOAP_SSL.html?rev=HEAD&content-type=text/html.

Scott Nichol

----- Original Message -----
From: "Santa" <[email protected]>
To: <[email protected]>
Sent: Wednesday, August 13, 2003 09:58
Subject: Soap SSL Communication


Hello,

I am Santa, using the SOAP on WAS5.0 also testing on Tomcat 4.0. I would
like to know how to make SSL communication from the Java Soap Client. The
Server is configured for the SSL (HTTPS) communication.

I have written a SOAP Server (HelloSOAP) and deployed on the Tomcat4.0 as
well as WAS5.0.  The Soap Server  Code is -

public class HelloSOAP

public String sayHello(String name){

return " Hello From Soap -- > "+name;
}
}

I am able to communicate with the HelloSOAP using normal HTTP protocol. The
Soap Client Code is -

public class SoapClient {
private  void invokeSayHello(URL url) {
Call call = new Call();
call.setTargetObjectURI("urn:HelloSOAP");

call.setMethodName("sayHello");
call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);

String name = "SP Shukla";
Vector params = new Vector();
params.addElement(new Parameter("name", String.class, name, null));
call.setParams(params);

try {
Response resp = call.invoke(url, "");
if (!resp.generatedFault()) {
Parameter result = resp.getReturnValue();
System.out.println(result.getValue());
} else {
System.out.println("FAULT Returned");
System.out.println(resp.getFault().getFaultString());
}
} catch (SOAPException e) {
System.out.println("Code: "+e.getFaultCode()+ ", Msg:" + e.getMessage());
soapE.printStackTrace();
} catch (Exception e) {
System.out.println("Caught Exception:" + e.getMessage());
e.printStackTrace();
}
}

public static void main(String[] args) {
try {
URL url = new URL("http://localhost:9080/SoapTest/servlet/rpcrouter");
SoapClient soapClient = new SoapClient();
soapClient.invokeSayHello(url);
} catch (MalformedURLException mue) {
mue.printStackTrace();
}
}
}


COULD ANYONE PLEASE HELP ME  FOR THE SSL COMMUNICATION FROM THE JAVA SOAP
CLIENT ????

Please give the web-link also (if possible)

Any early response would be appreciated.


Thanks and Regards,
Santa
email: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.