]> git.proxmox.com Git - pve-network.git/commitdiff
vnet : alias : check pattern
authorAlexandre Derumier <aderumier@odiso.com>
Mon, 23 Aug 2021 13:22:17 +0000 (15:22 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 24 Aug 2021 12:25:02 +0000 (14:25 +0200)
fix : https://bugzilla.proxmox.com/show_bug.cgi?id=2966
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
PVE/Network/SDN/VnetPlugin.pm

index 96a13b47dd2ac71644fe846c2b994b8736ddf2e8..121fb7ffd9e0a6ccb6532cf74bc06ae81ecf5f42 100644 (file)
@@ -68,6 +68,8 @@ sub properties {
         alias => {
             type => 'string',
             description => "alias name of the vnet",
+            pattern => qr/[a-z0-9\._\-\+\s]{1,256}/i,
+            maxLength => 256,
            optional => 1,
         },
     };