all lists on lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [PATCH manager] fix #3426: ui: parser: adapt parseSSHKey to accept "@..." suffix
@ 2021-06-07 10:44 Lorenz Stechauner
  2021-07-22  7:06 ` Lorenz Stechauner
  2021-07-23  7:09 ` [pve-devel] applied: " Dominik Csapak
  0 siblings, 2 replies; 3+ messages in thread
From: Lorenz Stechauner @ 2021-06-07 10:44 UTC (permalink / raw)
  To: pve-devel

also rearranged the regex groups to allow sk-ecdsa-sha2-...

note: FIDO keys are now parsable, the backend only supports it with
OpenSSH >= 8.2. This may be achieved with upgrading to PVE 7 or
using a back port.
---
 www/manager6/Parser.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/www/manager6/Parser.js b/www/manager6/Parser.js
index bb6a9a33..23236dac 100644
--- a/www/manager6/Parser.js
+++ b/www/manager6/Parser.js
@@ -565,7 +565,7 @@ Ext.define('PVE.Parser', {
     parseSSHKey: function(key) {
 	//                |--- options can have quotes--|     type    key        comment
 	let keyre = /^(?:((?:[^\s"]|"(?:\\.|[^"\\])*")+)\s+)?(\S+)\s+(\S+)(?:\s+(.*))?$/;
-	let typere = /^(?:(?:sk-)?ssh-(?:dss|rsa|ed25519)|ecdsa-sha2-nistp\d+)$/;
+	let typere = /^(?:(?:sk-)?(?:ssh-(?:dss|rsa|ed25519)|ecdsa-sha2-nistp\d+)(?:@(?:[a-z0-9_-]+\.)+[a-z]{2,})?)$/;
 
 	let m = key.match(keyre);
 	if (!m || m.length < 3 || !m[2]) { // [2] is always either type or key
-- 
2.20.1





^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [pve-devel] [PATCH manager] fix #3426: ui: parser: adapt parseSSHKey to accept "@..." suffix
  2021-06-07 10:44 [pve-devel] [PATCH manager] fix #3426: ui: parser: adapt parseSSHKey to accept "@..." suffix Lorenz Stechauner
@ 2021-07-22  7:06 ` Lorenz Stechauner
  2021-07-23  7:09 ` [pve-devel] applied: " Dominik Csapak
  1 sibling, 0 replies; 3+ messages in thread
From: Lorenz Stechauner @ 2021-07-22  7:06 UTC (permalink / raw)
  To: Lorenz Stechauner, Proxmox VE development discussion

ping

On 07.06.21 12:44, Lorenz Stechauner wrote:
> also rearranged the regex groups to allow sk-ecdsa-sha2-...
>
> note: FIDO keys are now parsable, the backend only supports it with
> OpenSSH >= 8.2. This may be achieved with upgrading to PVE 7 or
> using a back port.
> ---
>   www/manager6/Parser.js | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/www/manager6/Parser.js b/www/manager6/Parser.js
> index bb6a9a33..23236dac 100644
> --- a/www/manager6/Parser.js
> +++ b/www/manager6/Parser.js
> @@ -565,7 +565,7 @@ Ext.define('PVE.Parser', {
>       parseSSHKey: function(key) {
>   	//                |--- options can have quotes--|     type    key        comment
>   	let keyre = /^(?:((?:[^\s"]|"(?:\\.|[^"\\])*")+)\s+)?(\S+)\s+(\S+)(?:\s+(.*))?$/;
> -	let typere = /^(?:(?:sk-)?ssh-(?:dss|rsa|ed25519)|ecdsa-sha2-nistp\d+)$/;
> +	let typere = /^(?:(?:sk-)?(?:ssh-(?:dss|rsa|ed25519)|ecdsa-sha2-nistp\d+)(?:@(?:[a-z0-9_-]+\.)+[a-z]{2,})?)$/;
>   
>   	let m = key.match(keyre);
>   	if (!m || m.length < 3 || !m[2]) { // [2] is always either type or key




^ permalink raw reply	[flat|nested] 3+ messages in thread

* [pve-devel] applied: [PATCH manager] fix #3426: ui: parser: adapt parseSSHKey to accept "@..." suffix
  2021-06-07 10:44 [pve-devel] [PATCH manager] fix #3426: ui: parser: adapt parseSSHKey to accept "@..." suffix Lorenz Stechauner
  2021-07-22  7:06 ` Lorenz Stechauner
@ 2021-07-23  7:09 ` Dominik Csapak
  1 sibling, 0 replies; 3+ messages in thread
From: Dominik Csapak @ 2021-07-23  7:09 UTC (permalink / raw)
  To: Proxmox VE development discussion, Lorenz Stechauner

applied




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-07-23  7:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-07 10:44 [pve-devel] [PATCH manager] fix #3426: ui: parser: adapt parseSSHKey to accept "@..." suffix Lorenz Stechauner
2021-07-22  7:06 ` Lorenz Stechauner
2021-07-23  7:09 ` [pve-devel] applied: " Dominik Csapak

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal