Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
c283f5e7
Commit
c283f5e7
authored
Jan 24, 2011
by
Reed Loden
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 619637: (CVE-2010-4569) [SECURITY] XSS in user autocomplete due to lack of encoding by YUI
[r=mkanat r=dkl a=LpSolit]
parent
fee4dfba
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
field.js
js/field.js
+8
-1
No files found.
js/field.js
View file @
c283f5e7
...
@@ -661,6 +661,13 @@ function browserCanHideOptions(aSelect) {
...
@@ -661,6 +661,13 @@ function browserCanHideOptions(aSelect) {
/* (end) option hiding code */
/* (end) option hiding code */
// A convenience function to sanitize raw text for harmful HTML before outputting
function
_escapeHTML
(
text
)
{
return
text
.
replace
(
/&/g
,
'&'
).
replace
(
/</g
,
'<'
).
replace
(
/>/g
,
'>'
);
}
/**
/**
* The Autoselect
* The Autoselect
*/
*/
...
@@ -686,7 +693,7 @@ YAHOO.bugzilla.userAutocomplete = {
...
@@ -686,7 +693,7 @@ YAHOO.bugzilla.userAutocomplete = {
return
stringified
;
return
stringified
;
},
},
resultListFormat
:
function
(
oResultData
,
enteredText
,
sResultMatch
)
{
resultListFormat
:
function
(
oResultData
,
enteredText
,
sResultMatch
)
{
return
(
oResultData
.
real_name
+
" ("
+
oResultData
.
email
+
")"
);
return
(
_escapeHTML
(
oResultData
.
real_name
)
+
" ("
+
_escapeHTML
(
oResultData
.
email
)
+
")"
);
},
},
debug_helper
:
function
(
){
debug_helper
:
function
(
){
/* used to help debug any errors that might happen */
/* used to help debug any errors that might happen */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment