Merge pull request #34281 from sokumon/template-injection-xss

fix(xss): sanitize on input itself
This commit is contained in:
Soham Kulkarni 2025-10-06 17:25:11 +05:30 committed by GitHub
commit 73ff731b41
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -66,6 +66,7 @@ frappe.search.AwesomeBar = class AwesomeBar {
"input",
frappe.utils.debounce(function (e) {
var value = e.target.value;
value = frappe.utils.xss_sanitise(value);
var txt = value.trim().replace(/\s\s+/g, " ");
var last_space = txt.lastIndexOf(" ");
me.global_results = [];