From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id D696E61A21 for ; Thu, 22 Oct 2020 08:38:21 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id CA1EF1CEBA for ; Thu, 22 Oct 2020 08:38:21 +0200 (CEST) Received: from elsa.proxmox.com (212-186-127-178.static.upcbusiness.at [212.186.127.178]) by firstgate.proxmox.com (Proxmox) with ESMTP id B13F51CEAF for ; Thu, 22 Oct 2020 08:38:20 +0200 (CEST) Received: by elsa.proxmox.com (Postfix, from userid 0) id 8FAF6AE195B; Thu, 22 Oct 2020 08:38:20 +0200 (CEST) From: Dietmar Maurer To: pve-devel@lists.proxmox.com Date: Thu, 22 Oct 2020 08:38:17 +0200 Message-Id: <20201022063817.10809-1-dietmar@proxmox.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL -1.090 Adjusted score from AWL reputation of From: address KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: [pve-devel] [PATCH proxmox-widget-toolkit] correctly encode upid paramenter (use encodeURIComponent) X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 22 Oct 2020 06:38:21 -0000 --- src/window/TaskViewer.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/window/TaskViewer.js b/src/window/TaskViewer.js index 0333472..31e1ebc 100644 --- a/src/window/TaskViewer.js +++ b/src/window/TaskViewer.js @@ -14,7 +14,7 @@ Ext.define('Proxmox.window.TaskProgress', { let task = Proxmox.Utils.parse_task_upid(me.upid); let statstore = Ext.create('Proxmox.data.ObjectStore', { - url: "/api2/json/nodes/" + task.node + "/tasks/" + me.upid + "/status", + url: "/api2/json/nodes/" + task.node + "/tasks/" + encodeURIComponent(me.upid) + "/status", interval: 1000, rows: { status: { defaultValue: 'unknown' }, @@ -190,7 +190,7 @@ Ext.define('Proxmox.window.TaskViewer', { }; let statstore = Ext.create('Proxmox.data.ObjectStore', { - url: "/api2/json/nodes/" + task.node + "/tasks/" + me.upid + "/status", + url: "/api2/json/nodes/" + task.node + "/tasks/" + encodeURIComponent(me.upid) + "/status", interval: 1000, rows: rows, }); @@ -199,7 +199,7 @@ Ext.define('Proxmox.window.TaskViewer', { let stop_task = function() { Proxmox.Utils.API2Request({ - url: "/nodes/" + task.node + "/tasks/" + me.upid, + url: "/nodes/" + task.node + "/tasks/" + encodeURIComponent(me.upid), waitMsgTarget: me, method: 'DELETE', failure: function(response, opts) { @@ -233,7 +233,7 @@ Ext.define('Proxmox.window.TaskViewer', { title: gettext('Output'), tbar: [stop_btn2], border: false, - url: "/api2/extjs/nodes/" + task.node + "/tasks/" + me.upid + "/log", + url: "/api2/extjs/nodes/" + task.node + "/tasks/" + encodeURIComponent(me.upid) + "/log", }); me.mon(statstore, 'load', function() { -- 2.20.1