Логотип exploitDog
Консоль
Логотип exploitDog

exploitDog

github логотип

GHSA-cmh5-qc8w-xvcq

Опубликовано: 24 июл. 2018
Источник: github
Github: Прошло ревью
CVSS3: 6.1

Описание

Cross-Site Scripting in i18next

Affected versions of i18next may fail to sanitize user input when certain configuration options are used. When using the .init method, passing interpolation options without passing an escapeValue will default to undefined rather than the assumed true.

Proof of Concept

var init = i18n.init({ interpolation: { prefix: "__", suffix: "__", escapeValue: true } }, function(){ var test = i18n.t('__firstName__ __lastName__', { firstName: 'Bob', lastName: '["foo","bar"]', }); console.log(test); });

When escapeValue is explicitly passed, the result of test is:

<script>alert(1)</script> Johnson

This is supposed to be the default. However, if escapeValue is not included, the result is the unescaped string:

<script>alert(1)</script> Johnson

Recommendation

Update to version 3.4.4 or later.

Пакеты

Наименование

i18next

npm
Затронутые версииВерсия исправления

>= 2.0.0, < 3.4.4

3.4.4

EPSS

Процентиль: 45%
0.00223
Низкий

6.1 Medium

CVSS3

Дефекты

CWE-79

Связанные уязвимости

CVSS3: 6.1
ubuntu
больше 7 лет назад

i18next is a language translation framework. When using the .init method, passing interpolation options without passing an escapeValue will default to undefined rather than the assumed true. This can result in a cross-site scripting vulnerability because user input is assumed to be escaped, but is not. This vulnerability affects i18next 2.0.0 and later.

CVSS3: 6.1
nvd
больше 7 лет назад

i18next is a language translation framework. When using the .init method, passing interpolation options without passing an escapeValue will default to undefined rather than the assumed true. This can result in a cross-site scripting vulnerability because user input is assumed to be escaped, but is not. This vulnerability affects i18next 2.0.0 and later.

CVSS3: 6.1
debian
больше 7 лет назад

i18next is a language translation framework. When using the .init meth ...

EPSS

Процентиль: 45%
0.00223
Низкий

6.1 Medium

CVSS3

Дефекты

CWE-79