-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

===========================================================================
                         AUSCERT Security Bulletin

                              ASB-2012.0032.2
              Two vulnerabilities corrected in Ruby on Rails
                               14 March 2012

===========================================================================

        AusCERT Security Bulletin Summary
        ---------------------------------

Product:              Ruby on Rails
Operating System:     UNIX variants (UNIX, Linux, OSX)
                      Windows
Impact/Access:        Cross-site Scripting -- Remote with User Interaction
Resolution:           Patch/Upgrade
CVE Names:            CVE-2012-1098 CVE-2012-1099 
Member content until: Wednesday, April  4 2012

Revision History:     March 14 2012: Added CVE's
                      March  5 2012: Initial Release

OVERVIEW

        Two vulnerabilities have been identified in Ruby on Rails prior to
        versions 3.2.2, 3.1.4, 3.0.12 [1,2]


IMPACT

        The vendor has provided the following description of the
        vulnerabilities:
        
        "Due side effects of some optimizations in the String class, users
        that directly manipulate SafeBuffer objects via `[]` and other
        methods that return new instances of SafeBuffer may be inadvertently
        marked as HTML safe." [1]
        
        "When developers generate html options tags manually, user input
        concatenated with manually built tags may not be escaped and an
        attacker can inject arbitrary HTML in to the document. Only manually
        generated select tag options are impacted" [2]


MITIGATION

        Ruby on Rails versions 3.2.2, 3.1.4 and 3.0.12 have been released
        correcting these vulnerabilities. [3]


REFERENCES

        [1] Possible XSS Security Vulnerability in SafeBuffer#[] Options
            http://groups.google.com/group/rubyonrails-security/browse_thread/thread/edd28f1e3d04e913?pli=1

        [2] XSS Vulnerability in the select helper
            http://groups.google.com/group/rubyonrails-security/browse_thread/thread/9da0c515a6c4664?pli=1

        [3] [ANN] Rails 3.2.2 has been released!
            http://weblog.rubyonrails.org/2012/3/1/ann-rails-3-2-2-has-been-released

AusCERT has made every effort to ensure that the information contained
in this document is accurate.  However, the decision to use the information
described is the responsibility of each user or organisation. The decision to
follow or act on information or advice contained in this security bulletin is
the responsibility of each user or organisation, and should be considered in
accordance with your organisation's site policies and procedures. AusCERT
takes no responsibility for consequences which may arise from following or
acting on information or advice contained in this security bulletin.

===========================================================================
Australian Computer Emergency Response Team
The University of Queensland
Brisbane
Qld 4072

Internet Email: auscert@auscert.org.au
Facsimile:      (07) 3365 7031
Telephone:      (07) 3365 4417 (International: +61 7 3365 4417)
                AusCERT personnel answer during Queensland business hours 
                which are GMT+10:00 (AEST).
                On call after hours for member emergencies only.
===========================================================================
-----BEGIN PGP SIGNATURE-----
Comment: http://www.auscert.org.au/render.html?it=1967

iQIVAwUBT1/pEu4yVqjM2NGpAQJ/JxAAvzVSTSZ2V5/pJDU+D3xWjQm+U+daEV6c
3k09u9HiXxOzEgOrNUEWo5qfBLqpiG0MTWY6mbl2ek/O/Is6QgiV4lCV04kfVCuY
fAMhWIy615JUOxyginXIgDzfzZxH4KfVlumK157Z8CWHi97Prvoy9P8DKl6Qi6uZ
dwcLL5VkWN3DFhN17oXQGXvKelTeZDh5IjfypbJ4lnDuPnznAWKXNfqt+21N8Mpb
3lHXLdQszy+aFhYreBdEMglc4Z8bFCmJF8TBosaTqUV0153UoubXXfWZ0SOMdADm
03wB2bmXbWz7rh+JkaDXhJ5tPwvwzlEPnQbmKaxT1PgIGugJdQjLJgZ+9ekkLdff
0ClcWgCO3neBjYOEBTM+QCCUPuWkwdEc8FsHpVjMhbDrV+gN7OYd358t7mW190Uv
7pIJ4d2qIRQOYOSN8AKOshQmW1dlAEVxuaxsIZ74lOihrLVR54SN7FTtzbB0aMpj
FyrVLK8xOPrZjeDcAAYM0VyGDJuIpFY5FavI2a/yYqfjKU2r0+HoVBgOPVkanA/S
eySmYNkS5N1PYOX7Vb2v32wYfn6TJ1Evk8X+A2IcxYi8CHObOGQEkRH5O8MC7zP1
1+cqaQiMxgHYH2vwNhBQTXQQThP5OLbcOHc6bmeh5Dqg99ibhkeWCbtc2kd8NXLf
ddRImAFLSvM=
=UkHs
-----END PGP SIGNATURE-----