[CVE-2015-3227] Possible Denial of Service attack in Active Support

7,544 views
Skip to first unread message

Aaron Patterson

unread,
Jun 16, 2015, 2:27:13 PM6/16/15
to secu...@suse.de, rubyonrail...@googlegroups.com, oss-se...@lists.openwall.com, ruby-sec...@googlegroups.com
Possible Denial of Service attack in Active Support

There is a possible denial of service attack in the XML processing in Active
Support. This vulnerability has been assigned the CVE identifier CVE-2015-3227.

Versions Affected: All.
Not affected: None.
Fixed Versions: 4.2.2, 4.1.11

Impact
------
Specially crafted XML documents can cause applications to raise a
`SystemStackError` and potentially cause a denial of service attack. This
only impacts applications using REXML or JDOM as their XML processor. Other
XML processors that Rails supports are not impacted.

All users running an affected release should either upgrade or use one of the work arounds immediately.

Releases
--------
The FIXED releases are available at the normal locations.

Workarounds
-----------
Use an XML parser that is not impacted by this problem, such as Nokogiri or
LibXML. You can change the processor like this:

ActiveSupport::XmlMini.backend = 'Nokogiri'

If you cannot change XML parsers, then adjust
`RUBY_THREAD_MACHINE_STACK_SIZE`.

Patches
-------
To aid users who aren't able to upgrade immediately we have provided patches for the two supported release series. They are in git-am format and consist of a single changeset.

* 4-2-xml_depth.patch - Patch for 4.2 series
* 4-1-xml_depth.patch - Patch for 4.1 series
* 3-2-xml_depth.patch - Patch for 3.2 series

Please note that only the 4.2.x and 4.1.x series are supported at present. Users of earlier unsupported releases are advised to upgrade as soon as possible as we cannot guarantee the continued availability of security fixes for unsupported releases.

Credits
-------

Thanks to Tomek Rabczak from the NCC Group, and Matthew Draper for reporting
this issue.

--
Aaron Patterson
http://tenderlovemaking.com/
3-2-xml_depth.patch
4-1-xml_depth.patch
4-2-xml_depth.patch
Reply all
Reply to author
Forward
0 new messages