Description
Construct bounded CRLF text form parts and deliberate delimiter collisions, reporting ambiguity and parsing the collision-free generated grammar.
A protocol fixture is local test data representing headers, messages, identifiers, or request decisions. Serialization and parsing can be checked without contacting a server, while authentication, delivery, and actual client behavior require separate tests.
Construct bounded CRLF text form parts and deliberate delimiter collisions, reporting ambiguity and parsing the collision-free generated grammar.
When to use this tool
Use this generator to create reproducible multipart form message fixture cases from the supplied model or bank. Inspect the returned evidence before using cases in a test or exercise.
How to use the tool and how it works
- Supply fields, collisionControl in the field shapes below. Set seed when you need an explicit replay.
- Run the tool and correct any input error. For generated controls, distinguish a successful fixture containing an invalid case from failure to generate the fixture.
- Read boundary, body, collides, ambiguous, parts, parsedParts. Use the conventions below and keep answer-bearing fields separate when presenting an exercise.
Generate a boundary from eight sampled bytes and serialize supplied form fields with CRLF delimiters. Optionally plant that boundary inside the first value, delegate collision checking, and parse the bounded generated form only when no collision is found.1
Delegated operations used for this result: multipart boundary generator. Their calculation or parsing conventions apply to the corresponding result fields.2
| Input field | Meaning and units | Accepted input |
|---|---|---|
| fields | Fields | Required. Array of Object; no unknown keys.; minimum items 1; maximum items 16. |
| fields[].name | Name | Required. Text; minimum UTF-16 length 1; maximum UTF-16 length 128. |
| fields[].values | Values | Required. Array of Text; maximum UTF-16 length 65536.; minimum items 1; maximum items 16. |
| collisionControl | Collision Control | Required. Boolean. |
| seed | Optional numeric seed; takes precedence over context randomness. Without either, use the fixed tool.io default seed. | Optional. Safe integer. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| boundary | Boundary | Required. Text; maximum UTF-16 length 65536. |
| body | Body | Required. Text; maximum UTF-16 length 65536. |
| collides | Collides | Required. Boolean. |
| ambiguous | Ambiguous | Required. Boolean. |
| parts | Parts | Required. Array of Object; no unknown keys.; minimum items 1; maximum items 16. |
| parts[].name | Name | Required. Text; maximum UTF-16 length 65536. |
| parts[].value | Value | Required. Text; maximum UTF-16 length 65536. |
| parsedParts | Parsed Parts | Required. Array of Object; no unknown keys.; minimum items 0; maximum items 16. |
| parsedParts[].name | Name | Required. Text; maximum UTF-16 length 65536. |
| parsedParts[].value | Value | Required. Text; maximum UTF-16 length 65536. |
| randomness | Replay metadata: source is seed or context; seed is the normalized 32-bit seed or null for a context source. | Required. Object; no unknown keys. |
| randomness.seed | Optional numeric replay seed; normalization and precedence are explained below. | Required. Safe integer. or Null. |
| randomness.source | Source | Required. Text; one of "context", "seed". |
An explicit safe-integer seed takes precedence over injected context randomness and is normalized to an unsigned 32-bit integer. With no seed and no context source, replay uses the fixed tool.io default seed. A context source must return finite values from zero inclusive to one exclusive; its advancing state must be retained separately. randomness records the source and normalized seed, or null for context. These generators are not cryptographic random sources.
{
"input": {
"fields": [
{
"name": "note",
"values": [
"hello"
]
}
],
"collisionControl": false,
"seed": 42
},
"output": {
"boundary": "toolio-9972daab2c86459f",
"body": "--toolio-9972daab2c86459f\r\nContent-Disposition: form-data; name=\"note\"\r\n\r\nhello\r\n--toolio-9972daab2c86459f--\r\n",
"collides": false,
"ambiguous": false,
"parts": [
{
"name": "note",
"value": "hello"
}
],
"parsedParts": [
{
"name": "note",
"value": "hello"
}
],
"randomness": {
"seed": 42,
"source": "seed"
}
}
} Limitations and assumptions
- A collision marks the body ambiguous and leaves parsedParts empty. This is a simple text-field fixture, not a general multipart/file parser, upload client, or cryptographic boundary generator.
- A replay requires the same complete input and implementation. Randomized construction does not guarantee uniform coverage of every feasible output; finite samples can repeat unless a distinct-selection rule is explicitly stated.
- The field tables state structural bounds; cross-field constraints and bounded search or output budgets also apply. Unknown keys are rejected where the object contract disallows them. Input errors are distinct from null fields and deliberate invalid controls in a successful output.
Alternative or Complementary methods
For a supplied example, inspect the returned construction or delegated check directly. To evaluate a consumer, also test cases chosen for its own boundaries; a generated finite corpus does not establish exhaustive coverage.
References
Similar or alternative tools
- Random QR Message Card Set Generator
Sample supplied synthetic message templates, replace literal the index token and the code token tokens with a one-based card index and six random decimal digits, and delegate standard QR SVG symbols with explicit error correction; other text is literal, duplicates are reported, capacity failures stay structured, and app layout/print export are separate.
- Random HTML Attribute Quoting Corpus Generator
Compose bounded benign start-tag source with caller text, delegated five-character entity escaping, feasible double/single/unquoted/Boolean attribute forms, and duplicate attributes; retain the lexical parser's raw character references and first-duplicate rule, not DOM-decoded values, sanitization, or HTML conformance certification.