/[smeserver]/rpms/e-smith-hosts/sme8/e-smith-hosts-2.2.0.comment_hostname_validator.patch
ViewVC logotype

Diff of /rpms/e-smith-hosts/sme8/e-smith-hosts-2.2.0.comment_hostname_validator.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

Revision 1.3 by stephdl, Thu Jan 22 07:40:49 2015 UTC Revision 1.4 by stephdl, Mon Jan 26 18:17:46 2015 UTC
# Line 15  diff -Nur e-smith-hosts-2.4.0.old8723/ro Line 15  diff -Nur e-smith-hosts-2.4.0.old8723/ro
15  diff -Nur e-smith-hosts-2.4.0.old8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries e-smith-hosts-2.4.0.bz8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries  diff -Nur e-smith-hosts-2.4.0.old8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries e-smith-hosts-2.4.0.bz8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries
16  --- e-smith-hosts-2.4.0.old8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries     2015-01-18 11:25:40.356221775 +0100  --- e-smith-hosts-2.4.0.old8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries     2015-01-18 11:25:40.356221775 +0100
17  +++ e-smith-hosts-2.4.0.bz8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries      2015-01-18 12:57:12.694843190 +0100  +++ e-smith-hosts-2.4.0.bz8723/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/hostentries      2015-01-18 12:57:12.694843190 +0100
 @@ -128,7 +128,7 @@  
      <entry>  
          <base>HOSTNAME_DESCRIPTION</base>  
          <trans>  
 -            The hostname must contain only letters, numbers, and hyphens,  
 +            The hostname and the comment must contain only letters, numbers, and hyphens,  
              and must start with a letter or number.  
          </trans>  
      </entry>  
18  @@ -271,4 +271,18 @@  @@ -271,4 +271,18 @@
19           <base>MUST_BE_VALID_HOSTNAME_OR_IP</base>           <base>MUST_BE_VALID_HOSTNAME_OR_IP</base>
20           <trans>Must be a valid hostname or IP number</trans>           <trans>Must be a valid hostname or IP number</trans>
# Line 32  diff -Nur e-smith-hosts-2.4.0.old8723/ro Line 23  diff -Nur e-smith-hosts-2.4.0.old8723/ro
23  +   <base>HOSTNAME_COMMENT_ERROR</base>  +   <base>HOSTNAME_COMMENT_ERROR</base>
24  +    <trans>  +    <trans>
25  +    Error: unexpected characters in the comment of "{$hostname}.{$domain}".  +    Error: unexpected characters in the comment of "{$hostname}.{$domain}".
26  +    The comment must contain only letters, numbers and hyphens, and must start with a letter or number.  +    The comment must contain only letters, numbers, undescores, dots and hyphens, and must start with a letter or number.
27  +    </trans>  +    </trans>
28  +  </entry>  +  </entry>
29  +    <entry>  +    <entry>
# Line 59  diff -Nur e-smith-hosts-2.4.0.old8723/ro Line 50  diff -Nur e-smith-hosts-2.4.0.old8723/ro
50  +        return $self->error('HOSTNAME_VALIDATOR_ERROR');  +        return $self->error('HOSTNAME_VALIDATOR_ERROR');
51  +    }  +    }
52  +  +
53  +    unless ( $comment =~ /^[a-z0-9][a-z0-9-]*$/ )  +    unless ( $comment =~ /^([a-z0-9][\_\.\-a-z0-9\s]*)$/ )
54  +    {  +    {
55  +        return $self->error('HOSTNAME_COMMENT_ERROR');  +        return $self->error('HOSTNAME_COMMENT_ERROR');
56       }       }


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed