Merge 5c6a78cee077622ee85b56ab51f1e81b56878c22 into e1ea8e5fe9806df22c4688fdf0fdfd530a096d58

This commit is contained in:
Erki Aring 2025-08-04 16:45:18 +02:00 committed by GitHub
commit 3949fa4d07
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -146,6 +146,9 @@ xml_unload_external_entity(const char *URI, xmlCharEncoding enc) {
return NULL;
}
static void xml_error_func(void *ctx, const char *msg, ...) {
//modsec_rec *msr = (modsec_rec *)ctx;
}
/**
* Initialise XML parser.
@ -160,6 +163,8 @@ int xml_init(modsec_rec *msr, char **error_msg) {
msr->xml = apr_pcalloc(msr->mp, sizeof(xml_data));
if (msr->xml == NULL) return -1;
xmlSetGenericErrorFunc(msr, xml_error_func);
if(msr->txcfg->xml_external_entity == 0) {
entity = xmlParserInputBufferCreateFilenameDefault(xml_unload_external_entity);
}