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 4619E71635 for ; Fri, 11 Jun 2021 10:30:44 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 383F6F0AD for ; Fri, 11 Jun 2021 10:30:44 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (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 firstgate.proxmox.com (Proxmox) with ESMTPS id 58FD0F0A0 for ; Fri, 11 Jun 2021 10:30:43 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 2B31042AF5 for ; Fri, 11 Jun 2021 10:30:43 +0200 (CEST) To: =?UTF-8?Q?Dominic_J=c3=a4ger?= , Proxmox VE development discussion References: <20210517080318.51405-1-l.stechauner@proxmox.com> <20210517080318.51405-8-l.stechauner@proxmox.com> <20210611072746.GA40697@mala.proxmox.com> From: Lorenz Stechauner Message-ID: <257a0e7e-4e78-6922-6ac3-757eaa180613@proxmox.com> Date: Fri, 11 Jun 2021 10:30:41 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <20210611072746.GA40697@mala.proxmox.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-SPAM-LEVEL: Spam detection results: 0 AWL 1.215 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment NICE_REPLY_A -0.001 Looks like a legit reply (A) SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [proxmox.com] Subject: Re: [pve-devel] [PATCH v6 manager 7/7] fix #1710: ui: storage: add download from url button 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: Fri, 11 Jun 2021 08:30:44 -0000 Thanks for the feedback :) On 11.06.21 09:27, Dominic Jäger wrote: > On Mon, May 17, 2021 at 10:03:18AM +0200, Lorenz Stechauner wrote: >> + iso: [ > + 'application/octet-stream', >> + 'application/x-iso9660-image', >> + 'application/x-ima', > When I try do download a Proxmox VE image I get type x-cd-image. > https://www.proxmox.com/en/downloads?task=callelement&format=raw&item_id=589&element=f85c494b-2b32-4109-b8c1-083cca2b7db6&method=download&args[0]=b9d30b3515e7a12dff5619ff1e1843be > Then the download button should not be deactivated. I'll add x-cd-image to the list. Maybe a "I know, what I'm doing" checkbox in "advanced" will also work? (Which activates the download button without checking the mime type) The goal was, to restrict the user as much as possible to avoid possible errors in the future. >> + advancedColumn1: [ >> + { >> + xtype: 'textfield', >> + name: 'checksum', >> + fieldLabel: gettext('Checksum'), >> + allowBlank: true, >> + disabled: true, >> + emptyText: gettext('none'), >> + id: 'downloadUrlChecksum', >> + }, >> + { >> + xtype: 'pveHashAlgorithmSelector', >> + name: 'checksum-algorithm', >> + fieldLabel: gettext('Hash algorithm'), >> + allowBlank: true, >> + hasNoneOption: true, >> + value: '__default__', >> + listeners: { >> + change: 'hashChange', >> + }, >> + }, > An algorithm must be selected before entering something into the textfield. > Therefore, I'd place the algorithm selector above/before the textfield. >> + ], >> + advancedColumn2: [ >> + { >> + xtype: 'textfield', >> + fieldLabel: gettext('MIME type'), >> + name: 'mimetype', >> + disabled: true, >> + editable: false, > Non-editable might be good in general, but I cannot download the PVE image with > (unsupported) type x-cd-image because it will remain invalid forever. >> + emptyText: gettext('unknown'), >> + listeners: { >> + change: 'typeChange', >> + }, >> + }, >> + { >> + xtype: 'proxmoxcheckbox', >> + name: 'verify-certificates', >> + fieldLabel: gettext('Verify certificates'), >> + uncheckedValue: 0, >> + checked: true, >> + listeners: { >> + change: 'urlChange', >> + }, >> + }, >> + ], >> + }, >> + ], >> + > Downloading a Debian image and verifying with SHA512 worked for me > https://cdimage.debian.org/debian-cd/current/amd64/iso-dvd/debian-10.9.0-amd64-DVD-1.iso > > Tested-by: Dominic Jäger