Lucene search

K
osvGoogleOSV:GHSA-F89G-WHPF-6Q9M
HistoryNov 09, 2018 - 5:46 p.m.

Cross-Site Scripting in i18next

2018-11-0917:46:56
Google
osv.dev
8

EPSS

0.001

Percentile

30.6%

Affected versions of i18next allow untrusted user input to be injected into dictionary key names, resulting in a cross-site scripting vulnerability.

Proof of Concept

var init = i18n.init({debug: true}, function(){
  var test = i18n.t('__firstName__ __lastName__', {
        escapeInterpolation: true,
        firstName: '__lastNameHTML__',
        lastName: '<script>',
  });
  console.log(test);
});
// equals "<script> <script>"

Recommendation

Update to version 1.10.3 or later.

EPSS

0.001

Percentile

30.6%

Related for OSV:GHSA-F89G-WHPF-6Q9M