Skip to content
This repository has been archived by the owner on Apr 6, 2021. It is now read-only.

java client 2.2.0 BufferOverflowException if ssl cert is expired. #93

Open
h3adache opened this issue Jun 27, 2017 · 3 comments
Open

java client 2.2.0 BufferOverflowException if ssl cert is expired. #93

h3adache opened this issue Jun 27, 2017 · 3 comments

Comments

@h3adache
Copy link

SSL cert was installed using the instructions from deepstream tutorials

Everything works fine but when the cert expired and client tries to connect.
I get a BufferOverflowException without any other error/information and not any indication what the error was.

Exception in thread "Thread-10" java.nio.BufferOverflowException
        at java.nio.DirectByteBuffer.put(DirectByteBuffer.java:363)
        at java.nio.DirectByteBuffer.put(DirectByteBuffer.java:342)
        at sun.nio.ch.IOUtil.write(IOUtil.java:60)
        at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:471)
        at org.java_websocket.SSLSocketChannel2.close(SSLSocketChannel2.java:270)
        at org.java_websocket.WebSocketImpl.closeConnection(WebSocketImpl.java:453)
        at org.java_websocket.WebSocketImpl.closeConnection(WebSocketImpl.java:472)
        at org.java_websocket.WebSocketImpl.eot(WebSocketImpl.java:509)
        at org.java_websocket.client.WebSocketClient.interruptableRun(WebSocketClient.java:249)
        at org.java_websocket.client.WebSocketClient.run(WebSocketClient.java:188)
        at java.lang.Thread.run(Thread.java:745)

There's a possibly related issue on TooTallNate/Java-WebSocket#380

@afiller
Copy link

afiller commented Jul 18, 2017

The same problem also occurs when the certificate is not "trustworthy". I tried it with an old version of the JDK which does not trust letsencrypt yet, and got the same error.

An appropriate exception would be good here.

@h3adache
Copy link
Author

h3adache commented Sep 6, 2017

This is fixed in TooTallNate/Java-WebSocket now https://github.com/TooTallNate/Java-WebSocket/milestone/7

@yasserf
Copy link
Contributor

yasserf commented Sep 9, 2017

Thanks for letting us know! We'll get out a release very shortly

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants