Skip to content

doc: "Buffers and character encodings" issue regarding base64/base64url  #39975

@robguinness-snyk

Description

@robguinness-snyk

📗 API Reference Docs Problem

  • Version: v16.8.0 (possibly other versions as well)
  • Subsystem: Buffer / encodings

Location

Section of the site where the content exists

Affected URL(s):

Description

Concise explanation of the problem

The documentation for 'base64' and 'base64url' both reference RFC 4648, Section 5, but base64 and base64url are two distinct encodings, and the contents of Section 5 states "This encoding may be referred to as "base64url". This encoding should not be regarded as the same as the "base64" encoding and should not be referred to as only "base64". Unless clarified otherwise, "base64" refers to the base 64 in the previous section."

Because of this, it is unclear whether buf.toString('base64') returns base64 or base64url. If it indeed returns base64url, then it is unclear why 'base64url' exists as another encoding option.


  • I would like to work on this issue and
    submit a pull request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bufferIssues and PRs related to the buffer subsystem.docIssues and PRs related to the documentations.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions