diff --git a/0004-update-validate-rules-of-username-field.patch b/0004-update-validate-rules-of-username-field.patch new file mode 100644 index 0000000000000000000000000000000000000000..64ac89b2b86da9afd3a8ea39d79777502b8dc087 --- /dev/null +++ b/0004-update-validate-rules-of-username-field.patch @@ -0,0 +1,25 @@ +From d990c0bf4e7d0c4391bfbf0c52b80f70ea71d272 Mon Sep 17 00:00:00 2001 +From: rabbitali +Date: Tue, 9 May 2023 11:08:58 +0800 +Subject: [PATCH] update validate rules of username field + +--- + zeus/function/verify/host.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/zeus/function/verify/host.py b/zeus/function/verify/host.py +index f955975..63fc330 100644 +--- a/zeus/function/verify/host.py ++++ b/zeus/function/verify/host.py +@@ -29,7 +29,7 @@ class HostSchema(Schema): + required=True, validate=lambda s: len(s) > 0) + host_ip = fields.IP(required=True) + management = fields.Boolean(required=True) +- username = fields.String(required=True, validate=lambda s: len(s) > 0) ++ username = fields.String(required=True, validate=lambda s: 32 >= len(s) > 0) + password = fields.String(required=True, validate=lambda s: len(s) > 0) + agent_port = fields.Integer(required=True, validate=lambda s: 65535 >= s >= 0) + os_version = fields.String(required=True, validate=lambda s: len(s) > 0) +-- +Gitee + diff --git a/aops-zeus.spec b/aops-zeus.spec index c74468190c942eeb8da63d020b3c38045f7fc6e6..6c38db0317177e7bf9ac222a410e90f97b028fe2 100644 --- a/aops-zeus.spec +++ b/aops-zeus.spec @@ -1,6 +1,6 @@ Name: aops-zeus Version: v1.2.0 -Release: 3 +Release: 4 Summary: A host and user manager service which is the foundation of aops. License: MulanPSL2 URL: https://gitee.com/openeuler/%{name} @@ -8,6 +8,7 @@ Source0: %{name}-%{version}.tar.gz Patch0001: 0001-fix-token-is-not-invalidated-after-being-refreshed.patch Patch0002: 0002-update-args-validation-rules-and-update-add-host-by-batch.patch Patch0003: 0003-add-gevent-config-item-for-uwsgi.patch +Patch0004: 0004-update-validate-rules-of-username-field.patch BuildRequires: python3-setuptools @@ -45,6 +46,9 @@ A host and user manager service which is the foundation of aops. %changelog +* Tue May 09 2023 wenxin - v1.2.0-4 +- update validate rules of username field + * Mon May 08 2023 wenixn - v1.2.0-3 - add gevent config item for uwsgi