Displaying 8 results from an estimated 8 matches for "valid_hostname".
2016 Dec 24
0
[PATCH] lib: Use a common function to validate strings.
...eturn 0;
-
- while (len > 0) {
- char c = *str++;
- len--;
- if (!c_isalpha (c))
- return 0;
- }
- return 1;
-}
+#define VALID_DISK_LABEL(str) \
+ guestfs_int_string_is_valid ((str), 1, 20, true, false, NULL)
/**
* Check the server hostname is reasonable.
*/
-static int
-valid_hostname (const char *str)
-{
- size_t len = strlen (str);
-
- if (len == 0 || len > 255)
- return 0;
-
- while (len > 0) {
- char c = *str++;
- len--;
- if (!c_isalnum (c) &&
- c != '-' && c != '.' && c != ':' && c != '...
2016 Dec 24
2
[PATCH] lib: Use a common function to validate strings.
As discussed in the thread on validating $TERM, it would be good to
have a common function to do this. This is such a function.
The main advantage is it includes unit tests which the previous
functions did not.
Rich.
2011 Aug 03
0
[PATCH] update valid_hostname regex checks
...s NodeConfigScreen():
warn = 0
if not self.ntp_host2.value() is None and not self.ntp_host2.value() == "":
if not is_valid_ipv4(self.ntp_host2.value()):
- if not is_valid_ipv6(self.ntp_host1.value()):
- if not is_valid_hostname(self.ntp_host1.value()):
+ if not is_valid_ipv6(self.ntp_host2.value()):
+ if not is_valid_hostname(self.ntp_host2.value()):
warn = 1
if warn == 1:
self.screen.setColor("BUTTON", "black"...
2005 Dec 24
1
Bug#344620: ignore.server.d/postfix: 'address not listed for hostname' rule
...11} [._[:alnum:]-]+ postfix/smtpd\[[0-9]+\]: warning: ([0-9a-f.:]{3,39})+: address not listed for hostname [^[:space:]]+$
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ postfix/smtpd\[[0-9]+\]: too many errors after RCPT from [^[:space:]]+$
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ postfix/smtpd\[[0-9]+\]: warning: valid_hostname: invalid character [0-9]+\(decimal\): .*$
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ postfix/smtpd\[[0-9]+\]: warning: valid_hostname: misplaced delimiter: .$
-- System Information:
Debian Release: testing/unstable
APT prefers testing
APT policy: (500, 'testing'), (500, 'stable'), (6...
2012 Feb 08
2
fqdn hostname fails after reboot
Hi,
I have several machines running CentOS 6.2 and a strange problem with
the hostname of one machine... After every reboot it loses the fqdn
hostname.
Here is my confguration:
ifconfig | grep "inet addr"
inet addr:10.0.0.12 Bcast:10.0.0.255 Mask:255.255.255.0
inet addr:127.0.0.1 Mask:255.0.0.0
/etc/sysconfig/network
NETWORKING=yes
HOSTNAME=x800.mydomain.local
2005 Aug 01
1
patching postfix with VDA
..._listen.c
patching file src/util/inet_util.c
patching file src/util/listen.h
patching file src/util/match_list.c
patching file src/util/match_ops.c
patching file src/util/match_ops.h
patching file src/util/sdbm.c
patching file src/util/sdbm.h
patching file src/util/sys_defs.h
patching file src/util/valid_hostname.c
Patch #1 (postfix-2.1.1-config.patch):
Patch #2 (postfix-smtp_sasl_proto.c.patch):
Patch #3 (postfix-alternatives.patch):
Patch #4 (postfix-hostname-fqdn.patch):
missing header for unified diff at line 3 of patch
Patch #5 (postfix-2.1.1-pie.patch):
Patch #6 (postfix-2.1.1-obsolete.patch):
Patch #...
2004 Jun 21
2
Bug#255560: logcheck-database: More Postfix rules
...1} [._[:alnum:]-]+ postfix/smtpd\[[0-9]+\]: too many errors after RCPT from [^[:space:]]+$
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ postfix/smtpd\[[0-9]+\]: warning: Illegal address syntax from [^[:space:]]+ in MAIL command: <.*>$
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ postfix/smtpd\[[0-9]+\]: warning: valid_hostname: invalid character [0-9]+\(decimal\): .*$
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ postfix/smtp\[[0-9]+\]: warning: valid_hostname: empty hostname$
^\w{3} [ :0-9]{11} [._[:alnum:]-]+ postfix/smtp\[[0-9]+\]: warning: malformed domain name in resource data of MX record for .*$
^\w{3} [ :0-9]{11} [._[:alnum...
2017 Apr 04
1
[PATCH] Use Unicode single quotes ‘’ in place of short single quoted strings throughout.
...", &port) != 1 || !valid_port (port)) {
- error (g, _("invalid port number '%s'"), port_str);
+ error (g, _("invalid port number ‘%s’"), port_str);
free (hostname);
free (port_str);
return -1;
}
free (port_str);
if (!VALID_HOSTNAME (hostname)) {
- error (g, _("invalid hostname '%s'"), hostname);
+ error (g, _("invalid hostname ‘%s’"), hostname);
free (hostname);
return -1;
}
@@ -671,7 +671,7 @@ parse_one_server (guestfs_h *g, const char *server, struct drive_server *ret...