3 ms·
> text/plain is a superset of everything that can be represented by plain text Not in the context of web forms. Just checked the spec and "text/plain" just se
by xg15 4mo ago
> text/plain is a superset of everything that can be represented by plain text
Not in the context of web forms.
Just checked the spec and "text/plain" just seems to be an alias for "application/x-www-form-urlencoded" [1] - i.e. stuff that looks like
key=value&anotherkey=anothervalue
on the wire.
Apparently though, keys and values can contain arbitrary characters and arent percent-encoded, so you can do a "quine" where the "key" is
{"foo": "bar", "ignore": "
and the "value" is
"}
And then the browser will happily send
{"foo": "bar", "ignore": "="}
over the wire, which is valid json.
[1] https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#converting-an-entry-list-to-a-list-of-name-value-pairs https://html.spec.whatwg.org/multipage/form-control-infrastr...