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

test: fix flaky test-webcrypto-encrypt-decrypt-aes #37380

Closed

Conversation

RaisinTen
Copy link
Contributor

@RaisinTen RaisinTen commented Feb 15, 2021

  • Use a copy of plaintext to prevent tampering of the original
  • Since subtle.decrypt returns a Promise containing an ArrayBuffer and
    ArrayBuffers cannot be modified directly, create a Buffer from it
    right away so that the modification in the next line works as intended

Fixes: #35586

@nodejs-github-bot nodejs-github-bot added the test Issues and PRs related to the tests. label Feb 15, 2021
@nodejs-github-bot

This comment has been minimized.

* Use a copy of plaintext to prevent tampering of the original
* Since subtle.decrypt returns a Promise containing an ArrayBuffer and
  ArrayBuffers cannot be modified directly, create a Buffer from it
  right away so that the modification in the next line works as intended

Fixes: nodejs#35586
@RaisinTen
Copy link
Contributor Author

Rebased to get a green CI.

@nodejs-github-bot

This comment has been minimized.

@RaisinTen RaisinTen added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Feb 17, 2021
@nodejs-github-bot
Copy link
Collaborator

Copy link
Contributor

@MylesBorins MylesBorins left a comment

Choose a reason for hiding this comment

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

LGTM

@MylesBorins
Copy link
Contributor

Landed in 4411a99

MylesBorins pushed a commit that referenced this pull request Feb 18, 2021
* Use a copy of plaintext to prevent tampering of the original
* Since subtle.decrypt returns a Promise containing an ArrayBuffer and
  ArrayBuffers cannot be modified directly, create a Buffer from it
  right away so that the modification in the next line works as intended

Fixes: #35586

PR-URL: #37380
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
@RaisinTen RaisinTen deleted the test/fix-flaky-webcrypto-test branch February 19, 2021 13:32
targos pushed a commit that referenced this pull request Feb 28, 2021
* Use a copy of plaintext to prevent tampering of the original
* Since subtle.decrypt returns a Promise containing an ArrayBuffer and
  ArrayBuffers cannot be modified directly, create a Buffer from it
  right away so that the modification in the next line works as intended

Fixes: #35586

PR-URL: #37380
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. test Issues and PRs related to the tests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Investigate flaky test-webcrypto-encrypt-decrypt-aes on rhe17-s390x
5 participants