-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

===========================================================================
             AUSCERT External Security Bulletin Redistribution

                               ESB-2019.0880
       MSA-19-0004: "Log in as" functionality exposed to JavaScript
                      risk on other users' Dashboards
                               19 March 2019

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

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

Product:           Moodle
Publisher:         Moodle
Operating System:  Windows
                   UNIX variants (UNIX, Linux, OSX)
Impact/Access:     Execute Arbitrary Code/Commands -- Existing Account
Resolution:        Mitigation
CVE Names:         CVE-2019-3847  

Original Bulletin: 
   https://moodle.org/mod/forum/discuss.php?d=384010&parent=1547742

- --------------------------BEGIN INCLUDED TEXT--------------------

MSA-19-0004: "Log in as" functionality exposed to JavaScript risk on other
users' Dashboards
Tuesday, 19 March 2019, 11:06 AM

Users with the "login as other users" capability (such as administrators/
managers) can access other users' Dashboards, but the JavaScript those other
users may have added to their Dashboard was not being escaped when being viewed
by the user logging in on their behalf.

Please note that for versions 3.1 and 3.4 only, this fix removes access to
other users' Dashboards while using the login-as functionality. Versions 3.5
and 3.6 have additional sanitizing implemented, which allowed the risk to be
removed while retaining Dashboard access. If you require access to Dashboards
through the login-as feature, we recommend upgrading to Moodle 3.5 or above
(noting that 3.1 and 3.4 will also no longer receive security updates after
their next releases in May 2019).

Severity/Risk:     Serious
Versions affected: 3.6 to 3.6.2, 3.5 to 3.5.4, 3.4 to 3.4.7, 3.1 to 3.1.16 and
                  earlier unsupported versions
Versions fixed:    3.6.3, 3.5.5, 3.4.8 and 3.1.17
Reported by:       Daniel Thatcher
Workaround:        Use incognito/private browsing mode when using the "Log in as"
                  functionality, then close the private window
                  before logging back in as your own user, to
                  minimise session or cookie related risks.
                  Alternatively, avoid visiting the Dashboard
                  when logged in as other users until patch is
                  applied.
CVE identifier:    CVE-2019-3847
Changes (master):  http://git.moodle.org/gw?p=moodle.git&a=search&h=HEAD&st=commit&s=MDL-63786
Tracker issue:     MDL-63786 "Log in as" functionality exposed to JavaScript risk
                  on other users' Dashboards

- --------------------------END INCLUDED TEXT--------------------

You have received this e-mail bulletin as a result of your organisation's
registration with AusCERT. The mailing list you are subscribed to is
maintained within your organisation, so if you do not wish to continue
receiving these bulletins you should contact your local IT manager. If
you do not know who that is, please send an email to auscert@auscert.org.au
and we will forward your request to the appropriate person.

NOTE: Third Party Rights
This security bulletin is provided as a service to AusCERT's members.  As
AusCERT did not write the document quoted above, AusCERT has had no control
over its content. 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.

NOTE: This is only the original release of the security bulletin.  It may
not be updated when updates to the original are made.  If downloading at
a later date, it is recommended that the bulletin is retrieved directly
from the author's website to ensure that the information is still current.

Contact information for the authors of the original document is included
in the Security Bulletin above.  If you have any questions or need further
information, please contact them directly.

Previous advisories and external security bulletins can be retrieved from:

        https://www.auscert.org.au/bulletins/

===========================================================================
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

iQIVAwUBXJCTKGaOgq3Tt24GAQiTQg/9GB6DUwwfyrxe11QTHQJ43n6zqgiG6JdQ
cjTkgNg2D9dqRxqAkLPu7ZQanz7tW6uwLJNYiz0r5eCscuVkyAHC6UxvNVvW+IjN
4YTwbpFoTIK03sSvzsAPCCfvMJ/v2rzYLv/v6k4uYRV4E3fPFzE89kJTBMTt5HTS
rRpIcUuMveifT0ZEJJghfzmO1o0Q6aT+kAaemtTj4PbkZrdzl4RGIj2OLnixWYN3
pPlEunPShO4KVN/pNlGcwEKJUhZa8wRESbIlH2kOXL7ViExcuSRutkIBqXx7EVo5
4WnvkmRELi9yJKa8g5YF7UT6uG6yDNnES048WEh967UN+KnKCSvVzmWL5PipxRB3
lXQMuwD7xgQ4F4VhW1vcEVuPUJg64CQ1YUO2G6IsBtmAKeNbAOtXt6MtUzqg+See
4HOlCWDUW95MKbfOYENun8k3HY9IgM6XmGhVwQ3ilrnpQNrYczXDxKiluUvH5Z7C
dua7PEDfzWoT/c289OkJMh/IBm5sRVqr2JZqm8ABSyX83QIqC61kOU/SEqKWd/mC
dRfS+asobxPowozQeR12WTv5uKVCaVT2usRi/AbnjKqfZJ9PggS2hzUbE0u+JhHp
IkPVfxUjgCLjHFYpr1UtIY12IxbW2kfCzqd5wB1Njmx5EVtFPTU9MsrtMBemPghy
Xwp7fDWMbvU=
=BC0W
-----END PGP SIGNATURE-----