Skip to content
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

8277881 Missing SessionID in TLS1.3 resumption in compatibility mode #6583

Closed
wants to merge 3 commits into from

Conversation

djelinski
Copy link
Member

@djelinski djelinski commented Nov 29, 2021

All TLS 1.3 handshakes in compatibility mode must send a non-empty SessionID field. Currently TLS1.3 session resumptions are sending empty session ID. This patch fixes that problem.

All jdk_core tests passed. The newly added check passes with the patch, fails without it.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8277881: Missing SessionID in TLS1.3 resumption in compatibility mode

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk pull/6583/head:pull/6583
$ git checkout pull/6583

Update a local copy of the PR:
$ git checkout pull/6583
$ git pull https://git.openjdk.java.net/jdk pull/6583/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 6583

View PR using the GUI difftool:
$ git pr show -t 6583

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk/pull/6583.diff

@bridgekeeper
Copy link

bridgekeeper bot commented Nov 29, 2021

👋 Welcome back djelinski! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot added the rfr Pull request is ready for review label Nov 29, 2021
@openjdk
Copy link

openjdk bot commented Nov 29, 2021

@djelinski The following label will be automatically applied to this pull request:

  • security

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the security security-dev@openjdk.org label Nov 29, 2021
@mlbridge
Copy link

mlbridge bot commented Nov 29, 2021

Webrevs

Copy link
Contributor

@ascarpino ascarpino left a comment

Choose a reason for hiding this comment

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

Please add " 2021," to the copyright of ResumeTLS13withSNI.java.
I have run all the tests and they pass.

Have you run this fix on your customer's setup or similar setup to confirm this fixed their problem?

@djelinski
Copy link
Member Author

Thanks @ascarpino for reviewing. Copyright year updated.

Yes I confirmed that the updated version fixes the problem.

Interestingly, aside from the empty SessionID there were no other differences between the initial and resumption ClientHello messages, i.e. pre_shared_key extension was absent in both. I suppose the server didn't send any NewSessionTicket, but didn't investigate it further.

Copy link
Contributor

@ascarpino ascarpino left a comment

Choose a reason for hiding this comment

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

Approved

@openjdk
Copy link

openjdk bot commented Dec 23, 2021

⚠️ @djelinski the full name on your profile does not match the author name in this pull requests' HEAD commit. If this pull request gets integrated then the author name from this pull requests' HEAD commit will be used for the resulting commit. If you wish to push a new commit with a different author name, then please run the following commands in a local repository of your personal fork:

$ git checkout tls13-compat
$ git commit -c user.name='Preferred Full Name' --allow-empty -m 'Update full name'
$ git push

@openjdk
Copy link

openjdk bot commented Dec 23, 2021

@djelinski This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8277881: Missing SessionID in TLS1.3 resumption in compatibility mode

Reviewed-by: ascarpino

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 385 new commits pushed to the master branch:

  • 4669bcd: 8279244: test accompaning fix for JDK-8205187 is failing in Windows
  • a3b1c6b: Merge
  • 04ad668: 8279204: [BACKOUT] JDK-8278413: C2 crash when allocating array of size too large
  • 730f670: 8268297: jdk/jfr/api/consumer/streaming/TestLatestEvent.java times out
  • 9d5ae2e: 8279076: C2: Bad AD file when matching SqrtF with UseSSE=0
  • 04ee921: 8278967: rmiregistry fails to start because SecurityManager is disabled
  • 2be3e7e: 8278239: vmTestbase/nsk/jvmti/RedefineClasses/StressRedefine failed with EXCEPTION_ACCESS_VIOLATION at 0x000000000000000d
  • 9df200f: 8278795: Create test library and tests for langtools snippets
  • 7aff03a: 8267517: async logging for stdout and stderr
  • ff2ca4f: 8205187: javac/javadoc should not crash if no java.lang; crash message obsolete
  • ... and 375 more: https://git.openjdk.java.net/jdk/compare/40fef2311c95eca0ec34652f9fc0e56b827b8380...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@ascarpino) but any other Committer may sponsor as well.

➡️ To flag this PR as ready for integration with the above commit message, type /integrate in a new comment. (Afterwards, your sponsor types /sponsor in a new comment to perform the integration).

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Dec 23, 2021
@djelinski
Copy link
Member Author

/integrate

@openjdk openjdk bot added the sponsor Pull request is ready to be sponsored label Dec 23, 2021
@openjdk
Copy link

openjdk bot commented Dec 23, 2021

@djelinski
Your change (at version f62fb60) is now ready to be sponsored by a Committer.

@ascarpino
Copy link
Contributor

/sponsor

@openjdk
Copy link

openjdk bot commented Dec 24, 2021

Going to push as commit 9d99a37.
Since your change was applied there have been 385 commits pushed to the master branch:

  • 4669bcd: 8279244: test accompaning fix for JDK-8205187 is failing in Windows
  • a3b1c6b: Merge
  • 04ad668: 8279204: [BACKOUT] JDK-8278413: C2 crash when allocating array of size too large
  • 730f670: 8268297: jdk/jfr/api/consumer/streaming/TestLatestEvent.java times out
  • 9d5ae2e: 8279076: C2: Bad AD file when matching SqrtF with UseSSE=0
  • 04ee921: 8278967: rmiregistry fails to start because SecurityManager is disabled
  • 2be3e7e: 8278239: vmTestbase/nsk/jvmti/RedefineClasses/StressRedefine failed with EXCEPTION_ACCESS_VIOLATION at 0x000000000000000d
  • 9df200f: 8278795: Create test library and tests for langtools snippets
  • 7aff03a: 8267517: async logging for stdout and stderr
  • ff2ca4f: 8205187: javac/javadoc should not crash if no java.lang; crash message obsolete
  • ... and 375 more: https://git.openjdk.java.net/jdk/compare/40fef2311c95eca0ec34652f9fc0e56b827b8380...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Dec 24, 2021
@openjdk openjdk bot closed this Dec 24, 2021
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review sponsor Pull request is ready to be sponsored labels Dec 24, 2021
@openjdk
Copy link

openjdk bot commented Dec 24, 2021

@ascarpino @djelinski Pushed as commit 9d99a37.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@djelinski djelinski deleted the tls13-compat branch December 29, 2021 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integrated Pull request has been integrated security security-dev@openjdk.org
Development

Successfully merging this pull request may close these issues.

2 participants