HAPI FHIR is a complete implementation of the HL7 FHIR standard for healthcare interoperability in Java. Prior to 6.9.11, the hidden scan command concatenates attacker-controlled Implementation Guide titles, profile titles, and source references into scan.html without escaping in Scanner.java. As a result, a user who scans an attacker-supplied IG/profile and then opens or publishes the generated local/CI HTML report can trigger stored cross-site scripting, executing attacker-controlled JavaScript in the report's browser context. This issue is fixed in version 6.9.11.
Summary
AIBefore 6.9.11, the hidden scan command writes attacker-controlled Implementation Guide titles, profile titles, and source references into scan.html without escaping them. If a user scans an attacker-supplied IG or profile and then opens or publishes the local or CI HTML report, attacker-controlled JavaScript can run in the report's browser context.
Who should check
Engineers running hapifhir org.hl7.fhir.core, ca.uhn.hapi.fhir:org.hl7.fhir.validation, or ca.uhn.hapi.fhir:org.hl7.fhir.validation.cli before 6.9.11 should check their deployments.
What to do
- 1Upgrade to version 6.9.11.