Skip to content

Decide whether strict base64url belongs in this output-encoding library #149

Description

@jmanico

Reviewed 2026-09-25 (America/Los_Angeles) against main at bd249f5. Execution order and cross-issue ownership: #169. Batch 06.

This scope replaces the dated implementation prescriptions in the original report and earlier comments; linked historical evidence remains useful but must be rechecked before implementation.

Review disposition

The proposal delegates transport encoding to Java 8's Base64 API and proposes canonical decoding. No submitted implementation is present and no security regression is established. Its decoding/canonicalization surface conflicts with this library's documented output-encoding scope, so resolve that product/API decision before adding public methods or tag bindings.

  • Record whether to reject, document JDK use, or accept a narrowly justified utility. Base64url is transport encoding, not XSS prevention, validation, authentication, encryption or token-signature verification.
  • If accepted, specify byte/String types, canonical padding policy, null/error contracts, strict UTF-8 decoding and malformed UTF-16 handling for String encoding. Default UTF-8 replacement can silently map different Java strings to the same bytes; choose/reject explicitly.
  • Define rejection of nonalphabet/whitespace, invalid lengths, padding variants and nonzero trailing bits; errors must not echo input. Test canonical round trips and negative cases with the JDK codec as an implementation primitive, not a new codec implementation.
  • Specify bounded allocation/Writer semantics for large input and explain why byte grouping does not fit the existing char-to-char Encoder/EncodedWriter contract.
  • Decide whether view-layer exposure is useful; if accepted, encoding only, no decoder tags, and update facade/TLD/parity tests deliberately rather than weakening Guard facade mappings and JSP/Jakarta parity #167's invariants.
  • Document output-context restrictions and version the new API deliberately. Leave ESAPI delegates unchanged.

Implementation is deferred pending this explicit decision. #142/#128 own the larger scope/versioning policy. Deferral is not evidence that 1.5's backlog gate is complete.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: designExplicit future API/scope/compatibility decisions.enhancementpriority: P3Future scope or compatibility decision; not implementation approval.security-reviewSecurity-sensitive scope or acceptance criteria; not a vulnerability classification.triage: decisionDecision required before implementation; neither rejected nor accepted by triage.

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions