SECURITY: ve.ui.MWMediaDialog: Escape plaintext image metadata fields

CVE-2021-44855

Bug: T293589
Change-Id: I691b4065e67c53c4276599c8d16c31ab5591db3a
This commit is contained in:
sbassett 2021-11-16 12:17:18 -06:00 committed by Reedy
parent ff22ddd7a8
commit 839b64d882

View file

@ -788,9 +788,9 @@ ve.ui.MWMediaDialog.prototype.cleanAPIresponse = function ( rawResponse, config
}
// Check if the string should be truncated
return isTruncated && !config.ignoreCharLimit ?
return mw.html.escape( isTruncated && !config.ignoreCharLimit ?
originalText.slice( 0, charLimit ) + ellipsis :
originalText;
originalText );
};
/**