Univention Bugzilla – Attachment 3626 Details for
Bug 19557
Nameserver der Reverse-Zone mit Punkt am Ende
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch für 2.4.4
diff2.4.4.txt (text/plain), 1.80 KB, created by
Florian Best
on 2011-10-13 10:21:46 CEST
(
hide
)
Description:
patch für 2.4.4
Filename:
MIME Type:
Creator:
Florian Best
Created:
2011-10-13 10:21:46 CEST
Size:
1.80 KB
patch
obsolete
>diff -ur admin.o/handlers/dns/forward_zone.py admin/handlers/dns/forward_zone.py >--- admin.o/handlers/dns/forward_zone.py 2011-10-13 10:12:44.000000000 +0200 >+++ admin/handlers/dns/forward_zone.py 2011-10-13 10:13:31.000000000 +0200 >@@ -54,7 +54,7 @@ > 'zone': univention.admin.property( > short_description=_('Zone name'), > long_description='', >- syntax=univention.admin.syntax.string, >+ syntax=univention.admin.syntax.dnsZone, > multivalue=0, > options=[], > required=1, >diff -ur admin.o/syntax.py admin/syntax.py >--- admin.o/syntax.py 2011-10-13 10:12:44.000000000 +0200 >+++ admin/syntax.py 2011-10-13 10:15:47.000000000 +0200 >@@ -937,6 +937,21 @@ > return text > raise univention.admin.uexceptions.valueError,_("The name of a reverse zone consists of the reversed subnet address followed by .in-addr.arpa. Example: \"0.168.192.in-addr.arpa\"") > >+class dnsZone(simple): >+ name='dnsZone' >+ _re = re.compile(r'^[a-zA-Z](:?(:?[a-zA-Z0-9-]{0,63})*\.?)*[a-zA-Z0-9]$') >+ >+ def parse(self, text): >+ if text is None: >+ raise univention.admin.uexceptions.valueError(_("Missing value!")) >+ if len(text) >= 255: >+ raise univention.admin.uexceptions.valueError(_("Value may not be longer than 255 chars!")) >+ if self._re.match(text) is not None: >+ return text >+ elif max(map(len, text.split('.'))) >= 63: >+ raise univention.admin.uexceptions.valueError(_("Value may not longer than 63 chars between dots!")) >+ raise univention.admin.uexceptions.valueError(_("Value may not contain other than numbers, letters and dots and may not end with a dot!")) >+ > class dnsName(simple): > name='dnsName' > _re = re.compile('^[a-zA-Z0-9][a-zA-Z0-9._-]*[a-zA-Z0-9.]$')
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 19557
:
3626
|
3627
|
3628
|
3629