Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PPP-5351]-XSS Findings For Data-Access #1284

Open
wants to merge 1 commit into
base: BACKLOG-41215
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU Lesser General Public License for more details.
*
* Copyright (c) 2002-2017 Hitachi Vantara.. All rights reserved.
* Copyright (c) 2002-2024 Hitachi Vantara.. All rights reserved.
*/

define(["common-ui/util/xss"], function(xssUtil) {
Messages = function()
{
};
Expand Down Expand Up @@ -49,7 +50,7 @@ Messages.entityDecoder=document.createElement('textarea');
Messages.html_entity_decode = function(str)
{
try{
Messages.entityDecoder.innerHTML = str;
xssutil.setHtml(Messages.entityDecoder, str)
var value = Messages.entityDecoder.value;
value = unescape(value);
return value;
Expand Down Expand Up @@ -117,8 +118,9 @@ var cnt = 0;
element = elementOrId;
}
if (element) {
element.innerHTML = Messages.getString(msgKey);
xssutil.setHtml(element, Messages.getString(msgKey));
}
};
/* static init */
Messages.init();
});