Skip to content

Commit

Permalink
MDL-13705
Browse files Browse the repository at this point in the history
  • Loading branch information
skodak committed Feb 28, 2008
1 parent 15cda9c commit 8cd2314
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/weblib.php
Expand Up @@ -2058,6 +2058,7 @@ function cleanAttributes2($htmlArray){
}
$arreach['value'] = preg_replace("/j\s*a\s*v\s*a\s*s\s*c\s*r\s*i\s*p\s*t/i", "Xjavascript", $arreach['value']);
$arreach['value'] = preg_replace("/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n/i", "Xexpression", $arreach['value']);
$arreach['value'] = preg_replace("/b\s*i\s*n\s*d\s*i\s*n\s*g/i", "Xbinding", $arreach['value']);
} else if ($arreach['name'] == 'href') {
//Adobe Acrobat Reader XSS protection
$arreach['value'] = preg_replace('/(\.(pdf|fdf|xfdf|xdp|xfd))[^a-z0-9_\.\-].*$/i', '$1', $arreach['value']);
Expand Down

0 comments on commit 8cd2314

Please sign in to comment.