Title: Passing different encodings to Cipheriv updates results in ERR_INTERNAL_ASSERTION · Issue #64689 · nodejs/node · GitHub
Open Graph Title: Passing different encodings to Cipheriv updates results in ERR_INTERNAL_ASSERTION · Issue #64689 · nodejs/node
X Title: Passing different encodings to Cipheriv updates results in ERR_INTERNAL_ASSERTION · Issue #64689 · nodejs/node
Description: Version v26.4.0 Platform Linux archbtw 7.1.3-arch2-2 #1 SMP PREEMPT_DYNAMIC Thu, 16 Jul 2026 17:41:28 +0000 x86_64 GNU/Linux Subsystem Crypto What steps will reproduce the bug? let key = scryptSync('hello', 'salt', 24) let init_vector = ...
Open Graph Description: Version v26.4.0 Platform Linux archbtw 7.1.3-arch2-2 #1 SMP PREEMPT_DYNAMIC Thu, 16 Jul 2026 17:41:28 +0000 x86_64 GNU/Linux Subsystem Crypto What steps will reproduce the bug? let key = scryptSync...
X Description: Version v26.4.0 Platform Linux archbtw 7.1.3-arch2-2 #1 SMP PREEMPT_DYNAMIC Thu, 16 Jul 2026 17:41:28 +0000 x86_64 GNU/Linux Subsystem Crypto What steps will reproduce the bug? let key = scryptSync...
Opengraph URL: https://github.com/nodejs/node/issues/64689
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Passing different encodings to Cipheriv updates results in ERR_INTERNAL_ASSERTION","articleBody":"### Version\n\nv26.4.0\n\n### Platform\n```text\nLinux archbtw 7.1.3-arch2-2 #1 SMP PREEMPT_DYNAMIC Thu, 16 Jul 2026 17:41:28 +0000 x86_64 GNU/Linux\n```\n### Subsystem\nCrypto\n\n### What steps will reproduce the bug?\n\n```js\nlet key = scryptSync('hello', 'salt', 24)\nlet init_vector = randomFillSync(new Uint8Array(16))\nconst cipher = createCipheriv('aes-192-cbc', key, init_vector);\n\nlet encrypted = cipher.update('some clear text data', 'utf8', 'hex');\nencrypted += cipher.final('utf8');\n```\n\n### What is the expected behavior? Why is that the expected behavior?\n\nThe error should be handled gracefully and reported to the user.\n\n### What do you see instead?\n\n```\nUncaught Error [ERR_INTERNAL_ASSERTION]: Cannot change encoding\nThis is caused by either a bug in Node.js or incorrect usage of Node.js internals.\nPlease open an issue with this stack trace at https://github.com/nodejs/node/issues\n at assert.fail (node:internal/assert:17:9)\n at getDecoder (node:internal/crypto/cipher:101:12)\n at Cipheriv.final (node:internal/crypto/cipher:175:21) {\n code: 'ERR_INTERNAL_ASSERTION'\n```\n","author":{"url":"https://github.com/stickynotememo","@type":"Person","name":"stickynotememo"},"datePublished":"2026-07-23T06:25:46Z","url":"https://github.com/nodejs/node/issues/64689"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:f4e4002a-e593-5a5b-db45-29937fa8a145 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D6EE:1BB194:442455:583A6F:6AED2248 |
| html-safe-nonce | 3b7b4051045e2cda4958b3add05d35a010f6f77df62aafc3bac718c871431c75 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJENkVFOjFCQjE5NDo0NDI0NTU6NTgzQTZGOjZBRUQyMjQ4IiwidmlzaXRvcl9pZCI6IjgzOTY0MjAyMjUxODI4MDI1MDQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 16ffe6c0dae38727f4a3936bb55b1fb56536152b604804120648a4787c6a6afb |
| hovercard-subject-tag | issue:4956075248 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/64689/issue_layout |
| twitter:image | https://opengraph.githubassets.com/b1593219d0bcefa5504e86a08d3e6d4d4db1b114b454fe6471d0179f640d43f8/nodejs/node/issues/64689 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/b1593219d0bcefa5504e86a08d3e6d4d4db1b114b454fe6471d0179f640d43f8/nodejs/node/issues/64689 |
| og:image:alt | Version v26.4.0 Platform Linux archbtw 7.1.3-arch2-2 #1 SMP PREEMPT_DYNAMIC Thu, 16 Jul 2026 17:41:28 +0000 x86_64 GNU/Linux Subsystem Crypto What steps will reproduce the bug? let key = scryptSync... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | stickynotememo |
| hostname | github.com |
| expected-hostname | github.com |
| None | e3e0f7f63e50c6fe879198a93a0a023a648ecc0a5e9bc3b5e033ac57172237e6 |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 707a24b346ac8a82878b9c084efaa38a997660cb |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width