Repository navigation
codecs: one verb for every library: value_formats, basic_armor, the decode bound and over in place - #3
Merged
Conversation
added 30 commits
December 2, 2026 14:45
…put its decode accepts, never below max_encoded_size; the core refuses a longer input on every path
…ecode bound, refusing a longer intermediate before it is made
… through over under its decode bound
…ons, and every value operation refuses a pair through the declaration, one error
…d a declared byte input refused alone
… long as its longest text
…param on a partial specialization
…, the armor with its label in its type, and where a value's intermediate lives under its decode bound
…e no pair is refused
…ember output (MSVC C4458)
…bers a library keeps, the examples' regions and namespace
…odec is governed by its declaration encodable and decodable take the bytes' path only when no value codec of the pair converts, and the typed decode takes a byte result's path on the same condition, so that a refused pair of such a type is refused by its declaration in every form, never converted by the value codec or as bytes. value_formats_test pins the concepts and the forms; the message tests declared_byte_input_reason and declared_byte_result pin the one error. One spelling of composition_inner's type, with typename.
…ic_armor's row, the decode bound's error and intermediate); the example's helper in the anonymous namespace
…the lint takes without typename (lint fix)
…e for a byte value's value codec its own paragraph (doc fix)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
codecs' change
one-verb(webcpporg/proposals,libraries/codecs/openspec/changes/one-verb/):codecs::encodeandcodecs::decodeare the verbs of every library (owner decision 31).max_decode_input_size, the longest input its decode accepts, never belowmax_encoded_size(the build stops). The core refuses a longer input withcodecs::error::input_too_longon every path, directly and throughover(owner decision 29).overdecodes a value in place under that bound, up to 4096 bytes, with no heap andnoexcept. Above 4096 it uses the allocator, refusing an over-long input before it allocates, and wipes the intermediate when the value is secret (owner decision 30).over, and a new fuzz target,over_value.codecs::value_formats,format_list,directionandcheck_conversion. Every value operation, the buffer and token forms included, refuses a pair through that declaration with one error: the library's sentence or the type's list. A declared type that is also a byte input or a byte result follows its declaration too.formats::basic_armor<Label>: an armor whose label is fixed by its type, with an exact capacity (text<241>againsttext<347>for 138 bytes underPRIVATE KEY).over_valueandvalue_formats,pem'sfixed_labelregion, and the changelog.Verified locally on the final head, with no CI run (owner's rule):
The crypto pull request that follows removes
crypto::encodeandcrypto::decode.🤖 Generated with Claude Code