Simone Tiraboschi has uploaded a new change for review.

Change subject: packaging: setup: fixing hostname validation
......................................................................

packaging: setup: fixing hostname validation

engine-setup validates hostnames to avoid strange behaviours;
it's done via a regular expression.
Fixing it to avoid the match of '_' which is
not a valid character in a hostname according to RFC 952
An invalid hostname can cause strange behaviour interacting
with other components.

Change-Id: Id5c56bc5642bfb18629c1a0ad780e8a0e58a3531
Bug-url: https://bugzilla.redhat.com/1113974
Signed-off-by: Simone Tiraboschi <stira...@redhat.com>
(cherry picked from commit 98079e8c37e00349ce5b1f86d2501a15615a3339)
---
M packaging/setup/plugins/ovirt-engine-setup/base/network/hostname.py
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/59/29759/1

diff --git 
a/packaging/setup/plugins/ovirt-engine-setup/base/network/hostname.py 
b/packaging/setup/plugins/ovirt-engine-setup/base/network/hostname.py
index 052a5ad..ac432fd 100644
--- a/packaging/setup/plugins/ovirt-engine-setup/base/network/hostname.py
+++ b/packaging/setup/plugins/ovirt-engine-setup/base/network/hostname.py
@@ -41,7 +41,7 @@
         flags=re.VERBOSE,
         pattern=r"""
             ^
-            [\w\.\-\_]+
+            [A-Za-z0-9\.\-]+
             \w+
             $
         """


-- 
To view, visit http://gerrit.ovirt.org/29759
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id5c56bc5642bfb18629c1a0ad780e8a0e58a3531
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-3.5
Gerrit-Owner: Simone Tiraboschi <stira...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to