RE: [SPAM] - RE: [Axis 1.2] WSDL2Java for HTTPs url throws exception. - Message is from an unknown sender

2006-06-15 Thread subir.sasikumar








That is a good
suggestion!!!

But that means you
think that WSDL2Java will not work with https based urls…isn’t it???

 




 
  
  -Subir S
  
  
   
  
 
 
  
   
  
 
 
  
   
  
 




 









From: Dhakshinamoorthy,
Hariharasudhan [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 15, 2006
12:46 PM
To: axis-user@ws.apache.org
Subject: RE: [SPAM] - RE: [Axis
1.2] WSDL2Java for HTTPs url throws exception. - Message is from an unknown
sender



 



Aasi
kukar ,





Another way
is to save a local copy of the wsdl and try WSDL2Java ;-)





-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Sent: Thursday, June 15, 2006
12:42 PM
To: axis-user@ws.apache.org
Subject: [SPAM] - RE: [Axis 1.2]
WSDL2Java for HTTPs url throws exception. - Message is from an unknown sender

Hi Remy,

 

I agree with your
first point that SSL enforces the name of the certificate and the server host.

I agree that is what
is happening in the first case. (The exception being thrown below).

 

But in the client I
suppose the URL that we talk is the same URL that we give as the
targetEndPointAddress.

 

I have changed this
address from https:///prwp/services/UploadServices to
https:///prwp/services/UploadServices and vice versa and I can
access the web service successfully. I don't understand the reason for that.

 

I have added a topaz.subir.com
for the  to the tomcat server.xml
so that I can invoke my webservices using both ip address and host name.

 

Shouldn't the same
work with WSDL2Java also. Can you throw or some other Axis Developers throw
some light on this.

 

Regards,




 
  
  Subir S
  
  
   
  
 
 
  
   
  
 
 
  
   
  
 




 









From: Remy Bertrand
[mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 15, 2006 1:16
AM
To: axis-user@ws.apache.org
Subject: Re: [Axis 1.2] WSDL2Java
for HTTPs url throws exception.



 



The problem is not that WSDL2Java cannot resolve IP address,
it's that https protocol enforce that the name of the certificate must
correspond to the server host.





 





If you generate the certificate with name topaz.subir.com,
you have to give this name to WSDL2java, not the IP address.





 





If you were doing that in a browser, you would have an alert
because the name in the certificate doesn't correspond to the hostname. In a
Java program, this is an exception...





 





And lasts, your client probably uses the host name in his
own code, thats why he can connect to the service.





 





Rémy







- Original Message - 





From: [EMAIL PROTECTED]






To: axis-user@ws.apache.org






Sent: Wednesday, June
14, 2006 11:50 AM





Subject: [Axis 1.2]
WSDL2Java for HTTPs url throws exception.





 



Hi,

 

I
am getting a weird error when trying run WSDL2Java using https connection.

 

I
have SSL enabled using mod-ssl in Apache server connected to tomcat server
using JK2.

 

Jdk
is 1.5.0_03, tomcat 5.0.9, apache 2.0.52

 

I use the following
to generate the stubs

 

java
-Djavax.net.ssl.trustStore=C:\TraceLogs\tempstore.jks
-Djavax.net.ssl.trustStorePassword=subir123 org.apache.axis.wsdl.WSDL2Java
https://192.168.134.145:443/prwp/services/UploadServices?wsdl -p
prwp.soapclient -o .

 

I get the following
exception.

 

java.io.IOException:
HTTPS hostname wrong:  should be <192.168.134.145>

   
at sun.net.www.protocol.https.HttpsClient.checkURLSpoofing(HttpsClient.j

ava:493)

   
at sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:

418)

   
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect

(AbstractDelegateHttpsURLConnection.java:170)

   
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon

nection.java:913)

  
 at
sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Http

sURLConnectionImpl.java:234)

   
at com.sun.org.apache.xerces.internal.impl.XMLEntityManager.setupCurrent

Entity(XMLEntityManager.java:973)

   
at com.sun.org.apache.xerces.internal.impl.XMLVersionDetector.determineD

ocVersion(XMLVersionDetector.java:184)

   
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(X

ML11Configuration.java:798)

   
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(X

ML11Configuration.java:764)

   
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.

java:148)

   
at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.

java:250)

   
at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Doc

umentBuilderImpl.java:292)

   
at org.apache.axis.utils.XMLUtils.newDocument(XMLUtils.java:369)

   
at org.apache.axis.utils.XMLUtils.newDocument(XMLUtils.java:420)

 
  at
org.apache.axis.wsdl.symbolTable.SymbolTable.populate(SymbolTable.jav

a:480)

   
at org.apache.axis.wsdl.gen.Parser$WSDLRunnable.run(Parser.java:360)

   
at java.lang.Thread.run(Thread.j

RE: [SPAM] - RE: [Axis 1.2] WSDL2Java for HTTPs url throws exception. - Message is from an unknown sender

2006-06-15 Thread Dhakshinamoorthy, Hariharasudhan



Aasi kukar ,
Another way is to save a local copy of the wsdl and try WSDL2Java 
;-)

  -Original Message-From: [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]Sent: Thursday, June 15, 2006 
  12:42 PMTo: axis-user@ws.apache.orgSubject: [SPAM] - RE: 
  [Axis 1.2] WSDL2Java for HTTPs url throws exception. - Message is from an 
  unknown sender
  
  Hi 
  Remy,
   
  I agree with 
  your first point that SSL enforces the name of the certificate and the server 
  host.
  I agree that is 
  what is happening in the first case. (The exception being thrown 
  below).
   
  But in the 
  client I suppose the URL that we talk is the same URL that we give as the 
  targetEndPointAddress.
   
  I have changed 
  this address from https:///prwp/services/UploadServices to 
  https:///prwp/services/UploadServices and vice versa and I 
  can access the web service successfully. I don't understand the reason for 
  that.
   
  I have added a 
  topaz.wipro.com 
  for the  to the tomcat server.xml so that I can invoke my 
  webservices using both ip address and host name.
   
  Shouldn't the 
  same work with WSDL2Java also. Can you throw or some other Axis Developers 
  throw some light on this.
   
  Regards,
  
  


  
Subir 
S
  
 

  
 

  
 
   
  
  
  
  
  From: Remy 
  Bertrand [mailto:[EMAIL PROTECTED] Sent: Thursday, June 15, 2006 1:16 
  AMTo: axis-user@ws.apache.orgSubject: Re: [Axis 1.2] WSDL2Java for 
  HTTPs url throws exception.
   
  
  The problem is not that WSDL2Java 
  cannot resolve IP address, it's that https protocol enforce that the name of 
  the certificate must correspond to the server 
  host.
  
   
  
  If you generate the certificate 
  with name topaz.subir.com, you have to give this name to WSDL2java, not the IP 
  address.
  
   
  
  If you were doing that in a 
  browser, you would have an alert because the name in the certificate doesn't 
  correspond to the hostname. In a Java program, this is an 
  exception...
  
   
  
  And lasts, your client probably 
  uses the host name in his own code, thats why he can connect to the 
  service.
  
   
  
  Rémy
  

- Original Message - 


From: [EMAIL PROTECTED] 


To: axis-user@ws.apache.org 


Sent: 
Wednesday, June 14, 2006 11:50 AM

Subject: [Axis 
1.2] WSDL2Java for HTTPs url throws 
exception.

 
Hi,
 
I 
am getting a weird error when trying run WSDL2Java using https 
connection.
 
I 
have SSL enabled using mod-ssl in Apache server connected to tomcat server 
using JK2.
 
Jdk 
is 1.5.0_03, tomcat 5.0.9, apache 2.0.52
 
I use the 
following to generate the stubs
 
java 
-Djavax.net.ssl.trustStore=C:\TraceLogs\tempstore.jks 
-Djavax.net.ssl.trustStorePassword=subir123 org.apache.axis.wsdl.WSDL2Java 
https://192.168.134.145:443/prwp/services/UploadServices?wsdl -p 
prwp.soapclient -o .
 
I get the 
following exception.
 
java.io.IOException: 
HTTPS hostname wrong:  should be 
<192.168.134.145>
    
at 
sun.net.www.protocol.https.HttpsClient.checkURLSpoofing(HttpsClient.j
ava:493)
    
at 
sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:
418)
    
at 
sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect
(AbstractDelegateHttpsURLConnection.java:170)
    
at 
sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
nection.java:913)
   
 at 
sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Http
sURLConnectionImpl.java:234)
    
at 
com.sun.org.apache.xerces.internal.impl.XMLEntityManager.setupCurrent
Entity(XMLEntityManager.java:973)
    
at 
com.sun.org.apache.xerces.internal.impl.XMLVersionDetector.determineD
ocVersion(XMLVersionDetector.java:184)
    
at 
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(X
ML11Configuration.java:798)
    
at 
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(X
ML11Configuration.java:764)
    
at 
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.
java:148)
    
at 
com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.
java:250)
    
at 
com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Doc
umentBuilderImpl.java:292)
    
at 
org.apache.axis.utils.XMLUtils.newDocument(XMLUtils.java:369)
    
at 
org.apache.axis.utils.XMLUtils.newDocument(XMLUtils.java:420)
  
  at 
org.apache.axis.wsdl.symbolTable.SymbolTable.populate(SymbolTable.jav
a:480)
    
at 
org.apache.axis.wsdl.gen.Parser$WSD