mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 00:27:43 +00:00
LibWeb: Partially implement 'Extract header (list) values' AOs
The header-specific ABNF rules are completely ignored for now, but we can at least extract a single header value, which at least works for simple cases like `Location`-based redirects.
This commit is contained in:
parent
14e722617c
commit
455aa34011
2 changed files with 45 additions and 2 deletions
|
@ -73,6 +73,8 @@ struct RangeHeaderValue {
|
|||
[[nodiscard]] bool is_forbidden_header_name(ReadonlyBytes);
|
||||
[[nodiscard]] bool is_forbidden_response_header_name(ReadonlyBytes);
|
||||
[[nodiscard]] bool is_request_body_header_name(ReadonlyBytes);
|
||||
[[nodiscard]] ErrorOr<Optional<Vector<ByteBuffer>>> extract_header_values(Header const&);
|
||||
[[nodiscard]] ErrorOr<Optional<Vector<ByteBuffer>>> extract_header_list_values(ReadonlyBytes, HeaderList const&);
|
||||
[[nodiscard]] Optional<RangeHeaderValue> parse_single_range_header_value(ReadonlyBytes);
|
||||
[[nodiscard]] ErrorOr<ByteBuffer> default_user_agent_value();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue