The Burp Suite User Forum was discontinued on the 1st November 2024.

Burp Suite User Forum

For support requests, go to the Support Center. To discuss with other Burp users, head to our Discord page.

SUPPORT CENTER DISCORD

Enterprise Edition: JUnit file cannot be parsed with Jenkins

Yuta | Last updated: Apr 30, 2024 02:42PM UTC

Hi team, Our team is using the CI-driven scan feature of the Enterprise Edition integrating Jenkins and we are currently facing "XML Parsing Error: reference to invalid character number" error when we try to display the scan result from the JUnit file generated by Burp Suite using Jenkins 'JUnit' plugin (https://plugins.jenkins.io/junit/) and 'Warnings' plugin (https://plugins.jenkins.io/warnings-ng/). It seems there are invalid characters inside the JUnit file: ``` XML Parsing Error: reference to invalid character number Location: https://XXXXX/jenkins/job/XXXXX/job/XXXXX/lastSuccessfulBuild/artifact/burp_junit_report.xml Line Number 6251, Column 6: PK]]>&#3;&#4; -----^ ``` ``` Failed to read test report file /home/jenkins/workspace/XXXXX/XXXXX/burp_junit_report.xml org.dom4j.DocumentException: Error on line 6251 of document : Character reference "&#3" is an invalid XML character. at org.dom4j.io.SAXReader.read(SAXReader.java:511) at org.dom4j.io.SAXReader.read(SAXReader.java:392) at hudson.tasks.junit.SuiteResult.parse(SuiteResult.java:194) at hudson.tasks.junit.TestResult.parse(TestResult.java:422) at hudson.tasks.junit.TestResult.parsePossiblyEmpty(TestResult.java:337) at hudson.tasks.junit.TestResult.parse(TestResult.java:279) at hudson.tasks.junit.TestResult.parse(TestResult.java:265) at hudson.tasks.junit.TestResult.parse(TestResult.java:243) at hudson.tasks.junit.TestResult.<init>(TestResult.java:196) at hudson.tasks.junit.JUnitParser$ParseResultCallable.invoke(JUnitParser.java:185) at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3616) at hudson.remoting.UserRequest.perform(UserRequest.java:211) at hudson.remoting.UserRequest.perform(UserRequest.java:54) at hudson.remoting.Request$2.run(Request.java:377) at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:78) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:125) at java.base/java.lang.Thread.run(Unknown Source) Caused by: org.xml.sax.SAXParseException; lineNumber: 6251; columnNumber: 10; Character reference "&#3" is an invalid XML character. at java.xml/com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLScanner.scanCharReferenceValue(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source) at java.xml/com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) at org.dom4j.io.SAXReader.read(SAXReader.java:494) ... 19 more ``` It would be great if you could help us solve this error. This is a blocker for us to display scan results on Jenkins native UI. Our environment is as follows: - Enterprise: v2024.3.2 - Agent: public.ecr.aws/portswigger/enterprise-scan-container:2024.3.1 - Jenkins: v2.426.3 - Jenkins JUnit plugin: 1265.v65b_14fa_f12f0 - Jenkins Warnings plugin: 11.3.0 Let me know if you need further information. Thank you very much for your help.

Josh, PortSwigger Agent | Last updated: May 01, 2024 12:19PM UTC

Hi Yuta, can you send us an email at support@portswigger.net about this? It might be easier to diagnose this over email rather than the forum.

Yuta | Last updated: May 02, 2024 02:59AM UTC

Hi Josh, Actually, we sent an email to support@ already last week and we haven't got a reply so far. Let me send an email again to support@ about this topic just in case. Thank you so much for your support!

Ben, PortSwigger Agent | Last updated: May 02, 2024 06:30AM UTC