Fix bug 1688 - widening validation parameters 41/11241/1 master
authorsousaedu <eduardo.sousa@canonical.com>
Thu, 7 Oct 2021 14:17:32 +0000 (15:17 +0100)
committersousaedu <eduardo.sousa@canonical.com>
Thu, 7 Oct 2021 14:17:32 +0000 (15:17 +0100)
Change-Id: Ic6d0f00cc77682392b2f151ee3e01892029016e5
Signed-off-by: sousaedu <eduardo.sousa@canonical.com>
osm_nbi/validation.py

index c5f3ef2..681a67d 100644 (file)
@@ -549,7 +549,7 @@ wim_account_edit_schema = {
         "wim": name_schema,
         "wim_type": wim_type,
         "wim_url": description_schema,
-        "user": shortname_schema,
+        "user": string_schema,
         "password": passwd_schema,
         "config": {"type": "object"},
     },
@@ -568,7 +568,7 @@ wim_account_new_schema = {
         "wim": name_schema,
         "wim_type": wim_type,
         "wim_url": description_schema,
-        "user": shortname_schema,
+        "user": string_schema,
         "password": passwd_schema,
         "config": {
             "type": "object",
@@ -583,7 +583,7 @@ sdn_properties = {
     "name": name_schema,
     "type": {"type": "string"},
     "url": {"type": "string"},
-    "user": shortname_schema,
+    "user": string_schema,
     "password": passwd_schema,
     "config": {"type": "object"},
     "description": description_schema,
@@ -703,7 +703,7 @@ vca_new_schema = {
         "name": name_schema,
         "description": description_schema,
         "endpoints": description_list_schema,
-        "user": shortname_schema,
+        "user": string_schema,
         "secret": passwd_schema,
         "cacert": long_description_schema,
         "lxd-cloud": shortname_schema,
@@ -734,7 +734,7 @@ vca_edit_schema = {
         "description": description_schema,
         "endpoints": description_list_schema,
         "port": integer1_schema,
-        "user": shortname_schema,
+        "user": string_schema,
         "secret": passwd_schema,
         "cacert": long_description_schema,
         "lxd-cloud": shortname_schema,
@@ -777,7 +777,7 @@ osmrepo_properties = {
     "description": description_schema,
     "type": osmrepo_types,
     "url": description_schema
-    # "user": shortname_schema,
+    # "user": string_schema,
     # "password": passwd_schema
 }
 osmrepo_new_schema = {
@@ -907,7 +907,7 @@ user_new_schema = {
     "title": "New user schema",
     "type": "object",
     "properties": {
-        "username": shortname_schema,
+        "username": string_schema,
         "domain_name": shortname_schema,
         "password": passwd_schema,
         "projects": nameshort_list_schema,
@@ -922,7 +922,7 @@ user_edit_schema = {
     "type": "object",
     "properties": {
         "password": passwd_schema,
-        "username": shortname_schema,  # To allow User Name modification
+        "username": string_schema,  # To allow User Name modification
         "projects": {"oneOf": [nameshort_list_schema, array_edition_schema]},
         "project_role_mappings": project_role_mappings,
         "add_project_role_mappings": project_role_mappings,
@@ -1216,7 +1216,7 @@ authentication_schema = {
         "paramsBasic": {
             "type": "object",
             "properties": {
-                "userName": shortname_schema,
+                "userName": string_schema,
                 "password": passwd_schema,
             },
         },