]> git.proxmox.com Git - pve-access-control.git/blobdiff - src/PVE/API2/User.pm
api: user: limit email to 254 characters and user comment to 2048
[pve-access-control.git] / src / PVE / API2 / User.pm
index 8e0f4405294c807a3f8c1dbc49752d63d9507122..489d34f3577540abcb5f75a01d7706266ec6cb07 100644 (file)
@@ -35,12 +35,12 @@ register_standard_option('user-email', {
     type => 'string',
     optional => 1,
     format => 'email-opt',
-    maxLength => 4096,
+    maxLength => 254, # 256 including punctuation and separator is the max path as per RFC 5321
 });
 register_standard_option('user-comment', {
     type => 'string',
     optional => 1,
-    maxLength => 8192,
+    maxLength => 2048,
 });
 register_standard_option('user-keys', {
     description => "Keys for two factor auth (yubico).",