Lucene search

K
osvGoogleOSV:GHSA-3R8J-PMCH-5J2H
HistoryDec 05, 2019 - 7:57 p.m.

Internal exception message exposure for login action in Sylius

2019-12-0519:57:04
Google
osv.dev
19

0.001 Low

EPSS

Percentile

22.7%

Internal exception message exposure for login action

Impact

Exception messages from internal exceptions (like database exception) are wrapped by \Symfony\Component\Security\Core\Exception\AuthenticationServiceException and propagated through the system to UI. Therefore, some internal system information may leak and be visible to the customer.

A validation message with the exception details will be presented to the user when one will try to log into the shop.

Patches

Has the problem been patched? What versions should users upgrade to?

Workarounds

The src/Sylius/Bundle/UiBundle/Resources/views/Security/_login.html.twig file should be overridden and lines https://github.com/Sylius/Sylius/blob/1.4/src/Sylius/Bundle/UiBundle/Resources/views/Security/_login.html.twig#L13-L17 should be replaced with

        {% if last_error %}
            <div>
                {{ messages.error(last_error.messageKey) }}
            </div>
        {% endif %}

The messageKey field should be used instead of the message.

0.001 Low

EPSS

Percentile

22.7%

Related for OSV:GHSA-3R8J-PMCH-5J2H