Commit ae69902a authored by Medicean's avatar Medicean

Fix #134 修复部分 self-xss 引起的体验问题

parent c2f5432f
......@@ -34,7 +34,7 @@ class Files {
for(let gb in global_bookmarks) {
bookmark_opts.push({
id: 'bookmark_'+ global_bookmarks[gb],
text: gb,
text: antSword.noxss(gb),
icon: 'bookmark',
type: 'button',
enabled: manager.path !== global_bookmarks[gb]
......@@ -47,7 +47,7 @@ class Files {
for (let _ in bookmark) {
bookmark_opts.push({
id: 'bookmark_' + _,
text: bookmark[_],
text: antSword.noxss(bookmark[_]),
icon: 'bookmark-o',
type: 'button',
enabled: manager.path !== _
......
......@@ -26,7 +26,7 @@ module.exports = {
data.push({
id: _['_id'],
data: [
_['url'], _['ip'], _['addr'], _['note'],
antSword.noxss(_['url']), _['ip'], _['addr'], antSword.noxss(_['note']),
new Date(_['ctime']).format('yyyy/MM/dd hh:mm:ss'),
new Date(_['utime']).format('yyyy/MM/dd hh:mm:ss')
]
......
......@@ -80,7 +80,7 @@ class ShellManager {
this.category['sidebar'].addItem({
id: _,
bubble: _data['category'][_],
text: `<i class="fa fa-folder-o"></i> ${_}`
text: `<i class="fa fa-folder-o"></i> ${antSword.noxss(_)}`
});
}
// 加载分类数据
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment