EPrints Technical Mailing List Archive

Message: #07535

< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First

[EP-tech] XML parsing error message

Hi Everyone,

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