Fix bug 1686 - widening validation parameters 43/11243/2
authorsousaedu <eduardo.sousa@canonical.com>
Thu, 7 Oct 2021 14:27:21 +0000 (15:27 +0100)
committersousaedu <eduardo.sousa@canonical.com>
Fri, 8 Oct 2021 17:10:49 +0000 (18:10 +0100)
Change-Id: I754ef1a092c93aa308520373a8335fc68b471b51
Signed-off-by: sousaedu <eduardo.sousa@canonical.com>
osm_nbi/validation.py

index 9bc2624..e4b10ce 100644 (file)
@@ -491,7 +491,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"}
     },
@@ -510,7 +510,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",
@@ -527,7 +527,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,
@@ -665,7 +665,7 @@ osmrepo_properties = {
     "description": description_schema,
     "type": osmrepo_types,
     "url": description_schema
-    # "user": shortname_schema,
+    # "user": string_schema,
     # "password": passwd_schema
 }
 osmrepo_new_schema = {
@@ -801,7 +801,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,
@@ -816,7 +816,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,
@@ -1089,7 +1089,7 @@ authentication_schema = {
         "paramsBasic": {
             "type": "object",
             "properties": {
-                "userName": shortname_schema,
+                "userName": string_schema,
                 "password": passwd_schema,
             },
         },