[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[EP-tech] XML parsing error message
- Subject: [EP-tech] XML parsing error message
- From: L.E.Green-Hughes at kent.ac.uk (Liam Green-Hughes)
- Date: Tue, 16 Oct 2018 10:10:13 +0000
- References: <firstname.lastname@example.org>
I have come across a bit of an issue with parsing Phrase XML files on EPrints when hosted on RedHat/Centos 7 (I haven't seen this on RedHat 6). Lots of messages like these are being produced:
"Failed to parse XML file: /usr/share/eprints/archives/datadev/cfg/lang/en/phrases/archive_name.xml: error : func=xmlSecNoXxeExternalEntityLoader:file=xmlsec.c:line=53:obj=unknown:subj=xmlSecNoXxeExternalEntityLoader:error=5:libxml2 library function failed:illegal external entity='file:///usr/share/eprints/lib/entities.dtd/entities.dtd'"
It seems that libxml2 is not allowed to parse external DTD files by default on RedHat7. The only way I could get it working was to insert a line to switch off network access to DTD in perl_lib/EPrints/XML/LibXML.pm:
our $PARSER = XML::LibXML->new();
# Added by LGH
Has anyone else come across this?
Liam Green-Hughes | Library Systems Developer
Learning and Research Development, Information Services, University of Kent
-------------- next part --------------
An HTML attachment was scrubbed...