[pmg-devel] [PATCH pmg-api 2/2] cluster: add '=' to ssh pubkey pattern

Stoiko Ivanov s.ivanov at proxmox.com
Wed Jul 14 16:44:30 CEST 2021


ssh public keys are base64 encoded, thus can potentially contain =.
until now the RSA keys generated by Debian were 2048 bits long and did
not need padding

with bullseye (openssh (1:8.0p1-1)) the RSA keysize got increased to
3072 bits, and now does contain a =

noticed while trying to join a PMG container from a bullseye template
to my existing cluster (the error happens on the new node).

Signed-off-by: Stoiko Ivanov <s.ivanov at proxmox.com>
---
 src/PMG/ClusterConfig.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/PMG/ClusterConfig.pm b/src/PMG/ClusterConfig.pm
index b615a6c..8d77cc4 100644
--- a/src/PMG/ClusterConfig.pm
+++ b/src/PMG/ClusterConfig.pm
@@ -46,7 +46,7 @@ use warnings;
 use base qw(PMG::ClusterConfig::Base);
 
 sub valid_ssh_pubkey {
-    return'^[A-Za-z0-9\.\/\+]{200,}$';
+    return'^[A-Za-z0-9\.\/\+=]{200,}$';
 }
 
 sub type {
-- 
2.30.2





More information about the pmg-devel mailing list