diff --git a/data/custom.xml b/data/custom.xml index 4766f15..64264d1 100644 --- a/data/custom.xml +++ b/data/custom.xml @@ -23,7 +23,7 @@ - + @@ -39,7 +39,7 @@ - + @@ -55,7 +55,7 @@ - + diff --git a/lib/marcel/tables.rb b/lib/marcel/tables.rb index 2b3c2a2..0b6270f 100644 --- a/lib/marcel/tables.rb +++ b/lib/marcel/tables.rb @@ -2160,11 +2160,11 @@ module Marcel ['audio/mpeg', [[0, "\377\362"], [0, "\377\363"], [0, "\377\364"], [0, "\377\365"], [0, "\377\366"], [0, "\377\367"], [0, "\377\372"], [0, "\377\373"], [0, "\377\374"], [0, "\377\375"], [0, "\377\377"], [0, 'ID3']]], ['application/pdf', [[0, '%PDF-'], [0, "\357\273\277%PDF-"]]], ['application/msword', [[0..8, "\320\317\021\340\241\261\032\341", [[546, 'jbjb'], [546, 'bjbj']]]]], - ['application/vnd.openxmlformats-officedocument.wordprocessingml.document', [[0, "PK\003\004", [[30, '[Content_Types].xml', [[0..4096, 'word/']]], [30, '_rels/.rels', [[0..4096, 'word/']]]]]]], + ['application/vnd.openxmlformats-officedocument.wordprocessingml.document', [[0, "PK\003\004", [[30..65536, '[Content_Types].xml', [[0..4096, 'word/']]], [30, '_rels/.rels', [[0..4096, 'word/']]]]]]], ['application/vnd.ms-powerpoint', [[0..8, "\320\317\021\340\241\261\032\341", [[1152..4096, "P\000o\000w\000e\000r\000P\000o\000i\000n\000t\000 D\000o\000c\000u\000m\000e\000n\000t"]]]]], - ['application/vnd.openxmlformats-officedocument.presentationml.presentation', [[0, "PK\003\004", [[30, '[Content_Types].xml', [[0..4096, 'ppt/']]], [30, '_rels/.rels', [[0..4096, 'ppt/']]]]]]], + ['application/vnd.openxmlformats-officedocument.presentationml.presentation', [[0, "PK\003\004", [[30..65536, '[Content_Types].xml', [[0..4096, 'ppt/']]], [30, '_rels/.rels', [[0..4096, 'ppt/']]]]]]], ['application/vnd.ms-excel', [[2080, 'Microsoft Excel 5.0 Worksheet'], [2080, 'Foglio di lavoro Microsoft Exce'], [2114, 'Biff5'], [2121, 'Biff5'], [0..8, "\320\317\021\340\241\261\032\341", [[1152..4096, "W\000o\000r\000k\000b\000o\000o\000k"]]]]], - ['application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', [[0, "PK\003\004", [[30, '[Content_Types].xml', [[0..4096, 'xl/']]], [30, '_rels/.rels', [[0..4096, 'xl/']]]]]]], + ['application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', [[0, "PK\003\004", [[30..65536, '[Content_Types].xml', [[0..4096, 'xl/']]], [30, '_rels/.rels', [[0..4096, 'xl/']]]]]]], ['application/x-dbf', [[0, "(?s)^[\\\\002\\\\003\\\\060\\\\061\\\\062\\\\103\\\\143\\\\203\\\\213\\\\313\\\\365\\\\345\\\\373].[\\\\001-\\\\014][\\\\001-\\\\037].{4}(?:.[^\\\\000]|[\\\\101-\\\\377].)(?:[^\\\\000\\\\001].|.[^\\\\000]).{31}(?<=[\\\\000][^\\\\000]{0,10})[A-Z@+]"]]], ['image/x-tga', [[1, "\001\001\000\000", [[8, ".*[\\\\124\\\\122\\\\125\\\\105\\\\126\\\\111\\\\123\\\\111\\\\117\\\\116\\\\055\\\\130\\\\106\\\\111\\\\114\\\\105\\\\056\\\\000]"]]], [1, "\000\002\000\000", [[8, ".*[\\\\124\\\\122\\\\125\\\\105\\\\126\\\\111\\\\123\\\\111\\\\117\\\\116\\\\055\\\\130\\\\106\\\\111\\\\114\\\\105\\\\056\\\\000]"]]], [1, "\000\003\000\000", [[8, ".*[\\\\124\\\\122\\\\125\\\\105\\\\126\\\\111\\\\123\\\\111\\\\117\\\\116\\\\055\\\\130\\\\106\\\\111\\\\114\\\\105\\\\056\\\\000]"]]]]], ['application/x-endnote-refer', [[0..50, '%A ', [[0..1000, "\n%D ", [[0..1000, "\n%T "]]]]]]], diff --git a/test/fixtures/magic/application/vnd.openxmlformats-officedocument.presentationml.presentation/converted_from_google_slide.pptx b/test/fixtures/magic/application/vnd.openxmlformats-officedocument.presentationml.presentation/converted_from_google_slide.pptx new file mode 100644 index 0000000..c416689 Binary files /dev/null and b/test/fixtures/magic/application/vnd.openxmlformats-officedocument.presentationml.presentation/converted_from_google_slide.pptx differ diff --git a/test/fixtures/magic/application/vnd.openxmlformats-officedocument.spreadsheetml.sheet/converted_from_google_sheet.xlsx b/test/fixtures/magic/application/vnd.openxmlformats-officedocument.spreadsheetml.sheet/converted_from_google_sheet.xlsx new file mode 100644 index 0000000..4651041 Binary files /dev/null and b/test/fixtures/magic/application/vnd.openxmlformats-officedocument.spreadsheetml.sheet/converted_from_google_sheet.xlsx differ diff --git a/test/fixtures/magic/application/vnd.openxmlformats-officedocument.wordprocessingml.document/converted_from_google_doc.docx b/test/fixtures/magic/application/vnd.openxmlformats-officedocument.wordprocessingml.document/converted_from_google_doc.docx new file mode 100644 index 0000000..b829fc8 Binary files /dev/null and b/test/fixtures/magic/application/vnd.openxmlformats-officedocument.wordprocessingml.document/converted_from_google_doc.docx differ