Skip to content

JSSE: SunJSSE test fixes#354

Merged
cconlon merged 2 commits intowolfSSL:masterfrom
rlm2002:eccurvesConstraints
Apr 10, 2026
Merged

JSSE: SunJSSE test fixes#354
cconlon merged 2 commits intowolfSSL:masterfrom
rlm2002:eccurvesConstraints

Conversation

@rlm2002
Copy link
Copy Markdown
Contributor

@rlm2002 rlm2002 commented Apr 8, 2026

Removes checkAndInitSSLSocket() call in WolfSSLSocket.close(). Function is meant to be called when initializing SSL Socket. Calling during close is counter-intuitive and causes a second, unnecessary exception to be thrown if connection failed during checkAndInitSSLSocket() at EngineHelper.loadKeyAndCertChain().

Fixes SunJSSE test NetSSLCiphersuites/ECCurvesconstraints.java

Sets this.closed = true when receiving a FATAL_ALERT in unwrap() or if buffered data was sent, inbound was closed and close_notify sent in wrap(). Buffer should not receive any more data.

Fixes SunJSSE tests SSLEngine/EngineCloseOnAlert.java and SSLEngineImpl/SSLEngineFailedALPN.java

@rlm2002 rlm2002 self-assigned this Apr 8, 2026
@cconlon cconlon requested a review from Copilot April 8, 2026 17:57
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Removes an out-of-place SSL initialization call from the socket shutdown path to prevent redundant/secondary exceptions during close() after handshake/init failures, unblocking a failing SunJSSE test.

Changes:

  • Removes checkAndInitSSLSocket() invocation from WolfSSLSocket.close()
  • Eliminates the associated close-path comment that suggested SSL init during shutdown

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@rlm2002 rlm2002 changed the title JSSE: remove unnecessary call to checkAndInitSSLSocket() JSSE: SunJSSE test fixes Apr 8, 2026
@rlm2002 rlm2002 assigned cconlon and unassigned rlm2002 Apr 8, 2026
@cconlon cconlon assigned rlm2002 and unassigned cconlon Apr 9, 2026
@rlm2002 rlm2002 force-pushed the eccurvesConstraints branch from f793797 to 768ffcc Compare April 9, 2026 19:46
@rlm2002 rlm2002 force-pushed the eccurvesConstraints branch from 768ffcc to 4d7a3ea Compare April 9, 2026 20:17
@rlm2002 rlm2002 assigned cconlon and unassigned rlm2002 Apr 10, 2026
@cconlon cconlon merged commit 84ebbf7 into wolfSSL:master Apr 10, 2026
102 checks passed
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.

3 participants