LibWeb/MimeSniff: Update Rar signature to match spec

This commit is contained in:
Kemal Zebari 2025-07-30 22:51:02 -07:00 committed by Jelle Raaijmakers
parent 068974732f
commit 4e4026c89a
Notes: github-actions[bot] 2025-07-31 14:22:38 +00:00
2 changed files with 3 additions and 3 deletions

View file

@ -498,8 +498,8 @@ Optional<MimeType> match_an_archive_type_pattern(ReadonlyBytes input)
// The string "PK" followed by ETX EOT, the ZIP archive signature.
BytePatternTableRow { "\x50\x4B\x03\x04"sv, "\xFF\xFF\xFF\xFF"sv, no_ignored_bytes, "application/zip"sv },
// The string "Rar " followed by SUB BEL NUL, the RAR archive signature.
BytePatternTableRow { "\x52\x61\x72\x20\x1A\x07\x00"sv, "\xFF\xFF\xFF\xFF\xFF\xFF\xFF"sv, no_ignored_bytes, "application/x-rar-compressed"sv },
// The string "Rar!" followed by SUB BEL NUL, the RAR 4.x archive signature.
BytePatternTableRow { "\x52\x61\x72\x21\x1A\x07\x00"sv, "\xFF\xFF\xFF\xFF\xFF\xFF\xFF"sv, no_ignored_bytes, "application/x-rar-compressed"sv },
};
for (auto const& row : pattern_table) {