[pve-devel] [PATCH manager 2/2] add htmlEncode to various fields

Dominik Csapak d.csapak at proxmox.com
Thu Feb 18 15:21:40 CET 2016


and the same for manager6

Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 www/manager6/dc/AuthView.js          | 1 +
 www/manager6/dc/GroupView.js         | 1 +
 www/manager6/dc/PoolView.js          | 1 +
 www/manager6/dc/SecurityGroups.js    | 2 +-
 www/manager6/dc/UserView.js          | 1 +
 www/manager6/grid/FirewallAliases.js | 2 +-
 www/manager6/ha/Groups.js            | 1 +
 www/manager6/ha/Resources.js         | 1 +
 www/manager6/panel/IPSet.js          | 2 +-
 www/manager6/pool/StatusView.js      | 1 +
 10 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/www/manager6/dc/AuthView.js b/www/manager6/dc/AuthView.js
index dde2139..70ef226 100644
--- a/www/manager6/dc/AuthView.js
+++ b/www/manager6/dc/AuthView.js
@@ -131,6 +131,7 @@ Ext.define('PVE.dc.AuthView', {
 		    header: gettext('Comment'),
 		    sortable: false,
 		    dataIndex: 'comment',
+		    renderer: Ext.String.htmlEncode,
 		    flex: 1
 		}
 	    ],
diff --git a/www/manager6/dc/GroupView.js b/www/manager6/dc/GroupView.js
index 668aa5a..0e412db 100644
--- a/www/manager6/dc/GroupView.js
+++ b/www/manager6/dc/GroupView.js
@@ -95,6 +95,7 @@ Ext.define('PVE.dc.GroupView', {
 		{
 		    header: gettext('Comment'),
 		    sortable: false,
+		    renderer: Ext.String.htmlEncode,
 		    dataIndex: 'comment',
 		    flex: 1
 		}
diff --git a/www/manager6/dc/PoolView.js b/www/manager6/dc/PoolView.js
index c9accf7..a65944c 100644
--- a/www/manager6/dc/PoolView.js
+++ b/www/manager6/dc/PoolView.js
@@ -95,6 +95,7 @@ Ext.define('PVE.dc.PoolView', {
 		{
 		    header: gettext('Comment'),
 		    sortable: false,
+		    renderer: Ext.String.htmlEncode,
 		    dataIndex: 'comment',
 		    flex: 1
 		}
diff --git a/www/manager6/dc/SecurityGroups.js b/www/manager6/dc/SecurityGroups.js
index 0e31295..d8562e7 100644
--- a/www/manager6/dc/SecurityGroups.js
+++ b/www/manager6/dc/SecurityGroups.js
@@ -167,7 +167,7 @@ Ext.define('PVE.SecurityGroupList', {
 	    selModel: sm,
 	    columns: [
 		{ header: gettext('Group'), dataIndex: 'group', width: 100 },
-		{ header: gettext('Comment'), dataIndex: 'comment', flex: 1 }
+		{ header: gettext('Comment'), dataIndex: 'comment', renderer: Ext.String.htmlEncode, flex: 1 }
 	    ],
 	    listeners: {
 		itemdblclick: run_editor,
diff --git a/www/manager6/dc/UserView.js b/www/manager6/dc/UserView.js
index 41c3e81..291c52b 100644
--- a/www/manager6/dc/UserView.js
+++ b/www/manager6/dc/UserView.js
@@ -219,6 +219,7 @@ Ext.define('PVE.dc.UserView', {
 		{
 		    header: gettext('Comment'),
 		    sortable: false,
+		    renderer: Ext.String.htmlEncode,
 		    dataIndex: 'comment',
 		    flex: 1
 		}
diff --git a/www/manager6/grid/FirewallAliases.js b/www/manager6/grid/FirewallAliases.js
index c8ca4fa..9af9c52 100644
--- a/www/manager6/grid/FirewallAliases.js
+++ b/www/manager6/grid/FirewallAliases.js
@@ -171,7 +171,7 @@ Ext.define('PVE.FirewallAliases', {
 	    columns: [
 		{ header: gettext('Name'), dataIndex: 'name', width: 100 },
 		{ header:  gettext('IP/CIDR'), dataIndex: 'cidr', width: 100 },
-		{ header: gettext('Comment'), dataIndex: 'comment', flex: 1 }
+		{ header: gettext('Comment'), dataIndex: 'comment', renderer: Ext.String.htmlEncode, flex: 1 }
 	    ],
 	    listeners: {
 		itemdblclick: run_editor
diff --git a/www/manager6/ha/Groups.js b/www/manager6/ha/Groups.js
index e596c00..ca0ad51 100644
--- a/www/manager6/ha/Groups.js
+++ b/www/manager6/ha/Groups.js
@@ -108,6 +108,7 @@ Ext.define('PVE.ha.GroupsView', {
 		{
 		    header: gettext('Comment'),
 		    flex: 1,
+		    renderer: Ext.String.htmlEncode,
 		    dataIndex: 'comment'
 		}
 	    ],
diff --git a/www/manager6/ha/Resources.js b/www/manager6/ha/Resources.js
index 495f039..4419f38 100644
--- a/www/manager6/ha/Resources.js
+++ b/www/manager6/ha/Resources.js
@@ -133,6 +133,7 @@ Ext.define('PVE.ha.ResourcesView', {
 		{
 		    header: gettext('Description'),
 		    flex: 1,
+		    renderer: Ext.String.htmlEncode,
 		    dataIndex: 'comment'
 		}
 	    ],
diff --git a/www/manager6/panel/IPSet.js b/www/manager6/panel/IPSet.js
index 2aae7df..821f467 100644
--- a/www/manager6/panel/IPSet.js
+++ b/www/manager6/panel/IPSet.js
@@ -148,7 +148,7 @@ Ext.define('PVE.IPSetList', {
 	    selModel: sm,
 	    columns: [
 		{ header: 'IPSet', dataIndex: 'name', width: 100 },
-		{ header: gettext('Comment'), dataIndex: 'comment', flex: 1 }
+		{ header: gettext('Comment'), dataIndex: 'comment', renderer: Ext.String.htmlEncode, flex: 1 }
 	    ],
 	    listeners: {
 		itemdblclick: run_editor,
diff --git a/www/manager6/pool/StatusView.js b/www/manager6/pool/StatusView.js
index 8049364..a376e09 100644
--- a/www/manager6/pool/StatusView.js
+++ b/www/manager6/pool/StatusView.js
@@ -13,6 +13,7 @@ Ext.define('PVE.pool.StatusView', {
 	var rows = {
 	    comment: {
 		header: gettext('Comment'), 
+		renderer: Ext.String.htmlEncode,
 		required: true
 	    }
 	};
-- 
2.1.4





More information about the pve-devel mailing list