php-src/ext/fileinfo/magicdata.patch
Anatol Belski 86f79b299e
fileinfo: Backport xz detection fix
Upstream: 9b0459afab

Fixes: #11298

Signed-off-by: Anatol Belski <ab@php.net>
2023-07-01 17:58:38 +02:00

80 lines
3 KiB
Diff

diff -ur Magdir/compress Magdir.orig/compress
--- Magdir/compress 2023-07-01 16:33:17.323889842 +0200
+++ Magdir.orig/compress 2021-03-31 01:47:28.000000000 +0200
@@ -1,5 +1,5 @@
#------------------------------------------------------------------------------
-# $File: compress,v 1.81 2021/04/19 17:01:45 christos Exp $
+# $File: compress,v 1.80 2021/03/15 17:49:24 christos Exp $
# compress: file(1) magic for pure-compression formats (no archives)
#
# compress, gzip, pack, compact, huf, squeeze, crunch, freeze, yabba, etc.
@@ -265,13 +265,14 @@
# http://tukaani.org/xz/xz-file-format.txt
0 ustring \xFD7zXZ\x00 XZ compressed data, checksum
-!:strength * 2
-!:mime application/x-xz
>7 byte&0xf 0x0 NONE
>7 byte&0xf 0x1 CRC32
>7 byte&0xf 0x4 CRC64
>7 byte&0xf 0xa SHA-256
+!:strength * 2
+!:mime application/x-xz
+
# https://github.com/ckolivas/lrzip/blob/master/doc/magic.header.txt
0 string LRZI LRZIP compressed data
>4 byte x - version %d
diff -ur Magdir/fonts Magdir.orig/fonts
--- Magdir/fonts 2023-07-01 16:32:41.731654699 +0200
+++ Magdir.orig/fonts 2021-02-23 01:49:24.000000000 +0100
@@ -384,13 +384,11 @@
# https://www.w3.org/TR/WOFF/
0 string wOFF Web Open Font Format
-!:mime font/woff
>0 use woff
>20 beshort x \b, version %d
>22 beshort x \b.%d
# https://www.w3.org/TR/WOFF2/
0 string wOF2 Web Open Font Format (Version 2)
-!:mime font/woff2
>0 use woff
#>20 belong x \b, totalCompressedSize %d
>24 beshort x \b, version %d
diff -ur Magdir/mail.news Magdir.orig/mail.news
--- Magdir/mail.news 2023-07-01 16:32:41.731654699 +0200
+++ Magdir.orig/mail.news 2021-03-31 01:47:28.000000000 +0200
@@ -1,5 +1,5 @@
#------------------------------------------------------------------------------
-# $File: mail.news,v 1.27 2021/04/05 16:36:14 christos Exp $
+# $File: mail.news,v 1.26 2021/03/21 14:37:03 christos Exp $
# mail.news: file(1) magic for mail and news
#
# Unfortunately, saved netnews also has From line added in some news software.
@@ -81,4 +81,4 @@
# File format spec: https://wiki.dovecot.org/Design/Dcrypt/#File_format
# From: Stephen Gildea
0 string CRYPTED\003\007 Dovecot encrypted message
->9 byte x \b, dcrypt version %d
+>9 byte xu \b, dcrypt version %d
diff -ur Magdir/rpm Magdir.orig/rpm
--- Magdir/rpm 2023-07-01 16:32:41.731654699 +0200
+++ Magdir.orig/rpm 2021-02-23 01:49:24.000000000 +0100
@@ -29,7 +29,6 @@
>>8 beshort 17 SuperH
>>8 beshort 18 Xtensa
>>8 beshort 255 noarch
->>10 string x %s
#delta RPM Daniel Novotny (dnovotny@redhat.com)
0 string drpm Delta RPM
diff -ur Magdir/securitycerts Magdir.orig/securitycerts
--- Magdir/securitycerts 2023-07-01 16:32:41.731654699 +0200
+++ Magdir.orig/securitycerts 2021-02-23 01:49:24.000000000 +0100
@@ -4,5 +4,3 @@
0 search/1 -----BEGIN\ CERTIFICATE------ RFC1421 Security Certificate text
0 search/1 -----BEGIN\ NEW\ CERTIFICATE RFC1421 Security Certificate Signing Request text
0 belong 0xedfeedfe Sun 'jks' Java Keystore File data
-
-0 string \0volume_key volume_key escrow packet