You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// test.jsfunctionpass(name){try{return!!newHeaders({[name]: "test"});}catch(e){returnfalse;}}functionassert(cond,message){if(!cond)console.error(message);}functiontest(){for(constcharof`"(),/:;<=>?@[\\]{}`.split("")){assert(!pass(char),`The string \`${char}\` should throw an error.`);}}test();
Expected Behavior
The above test should succeed.
Logs & Screenshots
> $ node test.js
The string `"` should throw an error.The string `(` should throw an error.The string `)` should throw an error.The string `,` should throw an error.The string `/` should throw an error.The string `:` should throw an error.The string `;` should throw an error.The string `<` should throw an error.The string `=` should throw an error.The string `>` should throw an error.The string `?` should throw an error.The string `@` should throw an error.The string `[` should throw an error.The string `\` should throw an error.The string `]` should throw an error.The string `{` should throw an error.The string `}` should throw an error.
Environment
Windows 11
Node.js v21.1.0
Undici v5.27.2
Additional context
None
The text was updated successfully, but these errors were encountered:
Bug Description
The following character
"(),/:;<=>?@[\]{}
is not allowed in the specification, but is allowed in Undici.References:
https://fetch.spec.whatwg.org/#header-name
https://tools.ietf.org/html/rfc7230#section-3.2.6
https://tools.ietf.org/html/rfc9110#section-5.6.2
Reproducible By
There is a simple test.
Expected Behavior
The above test should succeed.
Logs & Screenshots
Environment
Windows 11
Node.js v21.1.0
Undici v5.27.2
Additional context
None
The text was updated successfully, but these errors were encountered: