Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Java Security > exception in js...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 1689 of 1783
Post > Topic >>

exception in jsse client

by "menkaur@[EMAIL PROTECTED] " <menkaur@[EMAIL PROTECTED] > Apr 17, 2007 at 01:29 AM

Hi. I'm new to java and i'm trying to implement a simple secure client-
server communication using jsse. The server seems to work properly,
but when the client tryes to connect to it, it gets exception:

HelloClient exception: Exception creating connection to: 10.10.10.10;
nested exception is:
        java.net.SocketException:
java.security.NoSuchAlgorithmException: Error constructing
implementation (algorithm: Default, provider: SunJSSE, cl
ass: com.sun.net.ssl.internal.ssl.DefaultSSLContextImpl)
java.rmi.ConnectIOException: Exception creating connection to:
10.10.10.10; nested exception is:
        java.net.SocketException:
java.security.NoSuchAlgorithmException: Error constructing
implementation (algorithm: Default, provider: SunJSSE, cl
ass: com.sun.net.ssl.internal.ssl.DefaultSSLContextImpl)
        at sun.rmi.trans****t.tcp.TCPEndpoint.newSocket(Unknown Source)
        at sun.rmi.trans****t.tcp.TCPChannel.createConnection(Unknown
Source)
        at sun.rmi.trans****t.tcp.TCPChannel.newConnection(Unknown
Source)
        at sun.rmi.server.UnicastRef.invoke(Unknown Source)
        at
java.rmi.server.RemoteObjectInvocationHandler.invokeRemoteMethod(Unknown
Source)
        at
java.rmi.server.RemoteObjectInvocationHandler.invoke(Unknown Source)
        at $Proxy0.sayHello(Unknown Source)
        at HelloClient.main(HelloClient.java:25)
Caused by: java.net.SocketException:
java.security.NoSuchAlgorithmException: Error constructing
implementation (algorithm: Default, provider: SunJSSE,
 class: com.sun.net.ssl.internal.ssl.DefaultSSLContextImpl)
        at
javax.net.ssl.DefaultSSLSocketFactory.throwException(Unknown Source)
        at javax.net.ssl.DefaultSSLSocketFactory.createSocket(Unknown
Source)
        at
RMISSLClientSocketFactory.createSocket(RMISSLClientSocketFactory.java:
55)
        ... 8 more
Caused by: java.security.NoSuchAlgorithmException: Error constructing
implementation (algorithm: Default, provider: SunJSSE, class:
com.sun.net.ssl.in
ternal.ssl.DefaultSSLContextImpl)
        at java.security.Provider$Service.newInstance(Unknown Source)
        at sun.security.jca.GetInstance.getInstance(Unknown Source)
        at sun.security.jca.GetInstance.getInstance(Unknown Source)
        at javax.net.ssl.SSLContext.getInstance(Unknown Source)
        at javax.net.ssl.SSLContext.getDefault(Unknown Source)
        at javax.net.ssl.SSLSocketFactory.getDefault(Unknown Source)
        at
RMISSLClientSocketFactory.createSocket(RMISSLClientSocketFactory.java:
54)
        ... 8 more
Caused by: java.security.UnrecoverableKeyException: Password must not
be null
        at sun.security.provider.JavaKeyStore.engineGetKey(Unknown
Source)
        at sun.security.provider.JavaKeyStore$JKS.engineGetKey(Unknown
Source)
        at java.security.KeyStore.getKey(Unknown Source)
        at
com.sun.net.ssl.internal.ssl.SunX509KeyManagerImpl.<init>(Unknown
Source)
        at com.sun.net.ssl.internal.ssl.KeyManagerFactoryImpl
$SunX509.engineInit(Unknown Source)
        at javax.net.ssl.KeyManagerFactory.init(Unknown Source)
        at
com.sun.net.ssl.internal.ssl.DefaultSSLContextImpl.getDefaultKeyManager(Unk=
nown
Source)
        at
com.sun.net.ssl.internal.ssl.DefaultSSLContextImpl.<init>(Unknown
Source)
        at
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown
Source)
        at java.lang.reflect.Constructor.newInstance(Unknown Source)
        at java.lang.Class.newInstance0(Unknown Source)
        at java.lang.Class.newInstance(Unknown Source)
        ... 15 more

C:\Documents and Settings\user\My
Documents\=D0=A3=D0=BD?=D0=B2=D0=B5=D1=80=
=D1=81=D0=B8=D1=82=D0=B5=D1=82\10 =D1=81=D0=B5=D0=BC\subjects
\java\lrr\4\test\rmi\secureClient>secureClient.bat

C:\Documents and Settings\user\My
Documents\=D0=A3=D0=BD?=D0=B2=D0=B5=D1=80=
=D1=81=D0=B8=D1=82=D0=B5=D1=82\10 =D1=81=D0=B5=D0=BC\subjects
\java\lrr\4\test\rmi\secureClient>java -jar -
Djavax.net.ssl.keyStore=3Dtestkeys s
ecureClient.jar
HelloClient exception: ****t already in use: 1099; nested exception is:
        java.net.BindException: Address already in use: JVM_Bind
java.rmi.server.Ex****tException: ****t already in use: 1099; nested
exception is:
        java.net.BindException: Address already in use: JVM_Bind
        at sun.rmi.trans****t.tcp.TCPTrans****t.listen(Unknown Source)
        at sun.rmi.trans****t.tcp.TCPTrans****t.ex****tObject(Unknown
Source)
        at sun.rmi.trans****t.tcp.TCPEndpoint.ex****tObject(Unknown
Source)
        at sun.rmi.trans****t.LiveRef.ex****tObject(Unknown Source)
        at sun.rmi.server.UnicastServerRef.ex****tObject(Unknown
Source)
        at sun.rmi.registry.RegistryImpl.setup(Unknown Source)
        at sun.rmi.registry.RegistryImpl.<init>(Unknown Source)
        at java.rmi.registry.LocateRegistry.createRegistry(Unknown
Source)
        at HelloClient.main(HelloClient.java:20)
Caused by: java.net.BindException: Address already in use: JVM_Bind
        at java.net.PlainSocketImpl.socketBind(Native Method)
        at java.net.PlainSocketImpl.bind(Unknown Source)
        at java.net.ServerSocket.bind(Unknown Source)
        at java.net.ServerSocket.<init>(Unknown Source)
        at java.net.ServerSocket.<init>(Unknown Source)
        at
sun.rmi.trans****t.proxy.RMIDirectSocketFactory.createServerSocket(Unknown
Source)
        at
sun.rmi.trans****t.proxy.RMIMasterSocketFactory.createServerSocket(Unknown
Source)
        at sun.rmi.trans****t.tcp.TCPEndpoint.newServerSocket(Unknown
Source)
        ... 9 more
The command line for client is: java -jar -
Djavax.net.ssl.keyStore=3Dtestkeys secureClient.jar

What's wrong?
 




 1 Posts in Topic:
exception in jsse client
"menkaur@[EMAIL PROT  2007-04-17 01:29:35 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Jul 9 7:34:45 CDT 2008.