Development #74702
vérification alternative pour le format PDF
Début:
21 février 2023
Echéance:
% réalisé:
0%
Temps estimé:
Patch proposed:
Non
Planning:
Non
Description
Il y a des PDF qui n'ont pas leur entête %PDF au début, ne sont pas reconnus comme PDF par libmagic.
poppler regarde 1024 octets pour trouver l'entête,
#define headerSearchSize \ 1024 // read this many bytes at beginning of // file to look for '%PDF'
ghostscript à peu près pareil,
dup 1023 string .peekstring pop % "1024 string" exceeds current %stdin buffer % Valid PDF file cannot be smaller than 400 bytes. (%PDF-) search { 3 1 roll pop pop dup (%!PS) search not { length 0 ne { 1 index exch readstring pop pop (%stderr) (w) file dup ( **** Warning: File has some garbage before %PDF- .\n) writestring flushfile
Révisions associées
Historique
Mis à jour par Robot Gitea il y a environ un an
- Statut changé de Nouveau à Solution proposée
- Assigné à mis à Frédéric Péters
Frédéric Péters (fpeters) a ouvert une pull request sur Gitea concernant cette demande :
- URL : https://git.entrouvert.org/entrouvert/wcs/pulls/184
- Titre : misc: second guess libmagic for PDF files with garbage at start (#74702)
- Modifications : https://git.entrouvert.org/entrouvert/wcs/pulls/184/files
Mis à jour par Robot Gitea il y a environ un an
- Statut changé de Solution proposée à Solution validée
Serghei Mihai (smihai) a approuvé une pull request sur Gitea concernant cette demande :
Mis à jour par Robot Gitea il y a environ un an
- Statut changé de Solution validée à Résolu (à déployer)
Frédéric Péters (fpeters) a mergé une pull request sur Gitea concernant cette demande :
- URL : https://git.entrouvert.org/entrouvert/wcs/pulls/184
- Titre : misc: second guess libmagic for PDF files with garbage at start (#74702)
- Modifications : https://git.entrouvert.org/entrouvert/wcs/pulls/184/files
Mis à jour par Transition automatique il y a environ un an
- Statut changé de Résolu (à déployer) à Solution déployée
misc: second guess libmagic for PDF files with garbage at start (#74702)