buffer: fix `atob` input validation · nodejs/node@7533d08 · GitHub
Skip to content

Commit 7533d08

Browse files
buffer: fix atob input validation
This commit fixes a few inconsistencies between Node.js `atob` implementation and the WHATWG spec. Refs: https://infra.spec.whatwg.org/#forgiving-base64-decode Fixes: #42646 PR-URL: #42662 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com>
1 parent aa52873 commit 7533d08

2 files changed

Lines changed: 45 additions & 4 deletions

File tree

lib/buffer.js

Lines changed: 22 additions & 3 deletions

test/parallel/test-btoa-atob.js

Lines changed: 23 additions & 1 deletion

0 commit comments

Comments
 (0)