Skip to content

Commit

Permalink
Fix code scanning alert no. 4: Resolving XML external entity in user-…
Browse files Browse the repository at this point in the history
…controlled data

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
  • Loading branch information
hazendaz and github-advanced-security[bot] authored Sep 25, 2024
1 parent 1378858 commit 29b29f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/com/ibatis/common/xml/NodeletParser.java
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ private Document createDocument(InputStream inputStream)
factory.setIgnoringComments(true);
factory.setIgnoringElementContentWhitespace(false);
factory.setCoalescing(false);
factory.setExpandEntityReferences(true);
factory.setExpandEntityReferences(false);

DocumentBuilder builder = factory.newDocumentBuilder();
builder.setEntityResolver(entityResolver);
Expand Down

0 comments on commit 29b29f9

Please sign in to comment.