Code Monkey home page Code Monkey logo

Comments (5)

3breadt avatar 3breadt commented on July 20, 2024

Can you please share an example on how the Billion-laugh attack can be launched against the XMLPropertyListParser? Because I cannot reproduce it.

All recommended factory settings as per the XXE prevention cheat sheet are already in place.
See #26.

A quick unit test confirmed that the current settings prevent the attack. The following exception is thrown by the parser:
[Fatal Error] :1:1: JAXP00010001: The parser has encountered more than "64000" entity expansions in this document; this is the limit imposed by the JDK

So what is the added benefit of XMLConstants.FEATURE_SECURE_PROCESSING?

from dd-plist.

zahiritpro avatar zahiritpro commented on July 20, 2024

Can you try parsing with the xml content in below link https://en.wikipedia.org/wiki/Billion_laughs_attack#Code_example

from dd-plist.

3breadt avatar 3breadt commented on July 20, 2024

That's exactly the XML I used for testing.

from dd-plist.

3breadt avatar 3breadt commented on July 20, 2024

If you don't object, I would close this issue.

from dd-plist.

zahiritpro avatar zahiritpro commented on July 20, 2024

Yeah I see the test working fine.
I could notice if fSecureProcess property of DocumentBuilderFactory is true, the parser works fine.
This property wasn't true when I tried in my application, hence the attack was through.
Will check what is different

You shall close the issue. Thank you..!

from dd-plist.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.