Skip to content

Make SSLSocketChannel2 handle multiple SSL messages in 1 buffer read #153

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 5 commits into from
Closed

Conversation

2fours
Copy link
Contributor

@2fours 2fours commented Feb 3, 2013

Took me a few days to track this bug down. On my node server the Server Hello, Certificate, and ServerHelloDone messages were being returned in one tcp packet. The code in SSLSocketChannel2 was only handling the first message in the packet, so the SSL handshake would never complete. Please ignore the other file changes, SSLSocketChannel2 is the only file you need to merge.

Thanks for the great library.

Adam

@Davidiusdadi
Copy link
Collaborator

thank you very much for finding and fixing this problem - i will merge SSLSocketChannel2 today.

Davidiusdadi pushed a commit that referenced this pull request Feb 4, 2013
@Davidiusdadi
Copy link
Collaborator

hm i overcomplicated things by pulling everythin and then rebasing.

@2fours You will possibly have to force a pull...

@2fours
Copy link
Contributor Author

2fours commented Feb 5, 2013

There seem to be problems on older android platforms because of this bug in SSLEngine : https://code.google.com/p/android/issues/detail?id=12955#c12. It appears that the only way this will work on these platforms is to abandon SSLEngine and use SSLSocket. Any chance of that happening?

@Davidiusdadi
Copy link
Collaborator

Do you mean that your code is working fine but there is a problem with what i merged?

If there is a general probelm i would like to know the exact exeption or build error message and the android version you are working on.

The solution suggested in #141 might solve the problem.

@2fours
Copy link
Contributor Author

2fours commented Feb 5, 2013

The merged code is fine, the problem is the library will never work on Android versions < 3.0 (which is where the bug is fixed I believe) as long as it uses SSLEngine. #141 will not fix the issue.

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

Successfully merging this pull request may close these issues.

2 participants