annotate runtime/syntax/named.vim @ 6999:dc1b678f0e4e v7.4.817

patch 7.4.817 Problem: Invalid memory access in file_pat_to_reg_pat(). Solution: Use vim_isspace() instead of checking for a space only. (Dominique Pelle)
author Bram Moolenaar <bram@vim.org>
date Tue, 11 Aug 2015 16:20:05 +0200
parents e63691e7c504
children 43efa4f5a8ea
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
2 " Language: BIND configuration file
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
3 " Maintainer: Nick Hibma <nick@van-laarhoven.org>
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
4 " Last change: 2007-01-30
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
5 " Filenames: named.conf, rndc.conf
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
6 " Location: http://www.van-laarhoven.org/vim/syntax/named.vim
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 "
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
8 " Previously maintained by glory hump <rnd@web-drive.ru> and updated by Marcin
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
9 " Dalecki.
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
10 "
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
11 " This file could do with a lot of improvements, so comments are welcome.
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
12 " Please submit the named.conf (segment) with any comments.
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
13 "
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 " For version 5.x: Clear all syntax items
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 " For version 6.x: Quit when a syntax file was already loaded
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 if version < 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 syntax clear
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 elseif exists("b:current_syntax")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn case match
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 if version >= 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 setlocal iskeyword=.,-,48-58,A-Z,a-z,_
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 set iskeyword=.,-,48-58,A-Z,a-z,_
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
30 if version >= 600
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
31 syn sync match namedSync grouphere NONE "^(zone|controls|acl|key)"
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
32 endif
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
33
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 let s:save_cpo = &cpo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35 set cpo-=C
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 " BIND configuration file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39 syn match namedComment "//.*"
44
af1bcb9a13c0 updated for version 7.0027
vimboss
parents: 7
diff changeset
40 syn match namedComment "#.*"
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 syn region namedComment start="/\*" end="\*/"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42 syn region namedString start=/"/ end=/"/ contained
44
af1bcb9a13c0 updated for version 7.0027
vimboss
parents: 7
diff changeset
43 " --- omitted trailing semicolon
af1bcb9a13c0 updated for version 7.0027
vimboss
parents: 7
diff changeset
44 syn match namedError /[^;{#]$/
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 " --- top-level keywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 syn keyword namedInclude include nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 syn keyword namedKeyword acl key nextgroup=namedIntIdent skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 syn keyword namedKeyword server nextgroup=namedIdentifier skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 syn keyword namedKeyword controls nextgroup=namedSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 syn keyword namedKeyword trusted-keys nextgroup=namedIntSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 syn keyword namedKeyword logging nextgroup=namedLogSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 syn keyword namedKeyword options nextgroup=namedOptSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55 syn keyword namedKeyword zone nextgroup=namedZoneString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57 " --- Identifier: name of following { ... } Section
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 syn match namedIdentifier contained /\k\+/ nextgroup=namedSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59 " --- IntIdent: name of following IntSection
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 syn match namedIntIdent contained /"\=\k\+"\=/ nextgroup=namedIntSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 " --- Section: { ... } clause
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 syn region namedSection contained start=+{+ end=+};+ contains=namedSection,namedIntKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65 " --- IntSection: section that does not contain other sections
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
66 syn region namedIntSection contained start=+{+ end=+}+ contains=namedIntKeyword,namedError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
67
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
68 " --- IntKeyword: keywords contained within `{ ... }' sections only
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
69 " + these keywords are contained within `key' and `acl' sections
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
70 syn keyword namedIntKeyword contained key algorithm
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
71 syn keyword namedIntKeyword contained secret nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
72
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73 " + these keywords are contained within `server' section only
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
74 syn keyword namedIntKeyword contained bogus support-ixfr nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
75 syn keyword namedIntKeyword contained transfers nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76 syn keyword namedIntKeyword contained transfer-format
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
77 syn keyword namedIntKeyword contained keys nextgroup=namedIntSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
78
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79 " + these keywords are contained within `controls' section only
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80 syn keyword namedIntKeyword contained inet nextgroup=namedIPaddr,namedIPerror skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 syn keyword namedIntKeyword contained unix nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
82 syn keyword namedIntKeyword contained port perm owner group nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
83 syn keyword namedIntKeyword contained allow nextgroup=namedIntSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
84
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
85 " + these keywords are contained within `update-policy' section only
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
86 syn keyword namedIntKeyword contained grant nextgroup=namedString skipwhite
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
87 syn keyword namedIntKeyword contained name self subdomain wildcard nextgroup=namedString skipwhite
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
88 syn keyword namedIntKeyword TXT A PTR NS SOA A6 CNAME MX ANY skipwhite
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
89
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
90 " --- options
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
91 syn region namedOptSection contained start=+{+ end=+};+ contains=namedOption,namedCNOption,namedComment,namedParenError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
92
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
93 syn keyword namedOption contained version directory
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
94 \ nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
95 syn keyword namedOption contained named-xfer dump-file pid-file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
96 \ nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
97 syn keyword namedOption contained mem-statistics-file statistics-file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
98 \ nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
99 syn keyword namedOption contained auth-nxdomain deallocate-on-exit
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
100 \ nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
101 syn keyword namedOption contained dialup fake-iquery fetch-glue
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
102 \ nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
103 syn keyword namedOption contained has-old-clients host-statistics
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
104 \ nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
105 syn keyword namedOption contained maintain-ixfr-base multiple-cnames
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
106 \ nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
107 syn keyword namedOption contained notify recursion rfc2308-type1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
108 \ nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
109 syn keyword namedOption contained use-id-pool treat-cr-as-space
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
110 \ nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
111 syn keyword namedOption contained also-notify forwarders
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
112 \ nextgroup=namedIPlist skipwhite
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
113 syn keyword namedOption contained forward check-names
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
114 syn keyword namedOption contained allow-query allow-transfer allow-recursion
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
115 \ nextgroup=namedAML skipwhite
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
116 syn keyword namedOption contained blackhole listen-on
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
117 \ nextgroup=namedIntSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
118 syn keyword namedOption contained lame-ttl max-transfer-time-in
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
119 \ nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
120 syn keyword namedOption contained max-ncache-ttl min-roots
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
121 \ nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
122 syn keyword namedOption contained serial-queries transfers-in
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
123 \ nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
124 syn keyword namedOption contained transfers-out transfers-per-ns
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
125 syn keyword namedOption contained transfer-format
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
126 syn keyword namedOption contained transfer-source
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
127 \ nextgroup=namedIPaddr,namedIPerror skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
128 syn keyword namedOption contained max-ixfr-log-size
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
129 \ nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
130 syn keyword namedOption contained coresize datasize files stacksize
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
131 syn keyword namedOption contained cleaning-interval interface-interval statistics-interval heartbeat-interval
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
132 \ nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
133 syn keyword namedOption contained topology sortlist rrset-order
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
134 \ nextgroup=namedIntSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
135
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
136 syn match namedOption contained /\<query-source\s\+.*;/he=s+12 contains=namedQSKeywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
137 syn keyword namedQSKeywords contained address port
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
138 syn match namedCNOption contained /\<check-names\s\+.*;/he=s+11 contains=namedCNKeywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
139 syn keyword namedCNKeywords contained fail warn ignore master slave response
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
140
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
141 " --- logging facilities
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
142 syn region namedLogSection contained start=+{+ end=+};+ contains=namedLogOption
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
143 syn keyword namedLogOption contained channel nextgroup=namedIntIdent skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
144 syn keyword namedLogOption contained category nextgroup=namedIntIdent skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
145 syn keyword namedIntKeyword contained syslog null versions size severity
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
146 syn keyword namedIntKeyword contained file nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
147 syn keyword namedIntKeyword contained print-category print-severity print-time nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
148
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
149 " --- zone section
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
150 syn region namedZoneString contained oneline start=+"+ end=+"+ skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
151 \ contains=namedDomain,namedIllegalDom
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
152 \ nextgroup=namedZoneClass,namedZoneSection
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
153 syn keyword namedZoneClass contained in hs hesiod chaos
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
154 \ IN HS HESIOD CHAOS
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
155 \ nextgroup=namedZoneSection skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
156
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
157 syn region namedZoneSection contained start=+{+ end=+};+ contains=namedZoneOpt,namedCNOption,namedComment,namedMasters,namedParenError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
158 syn keyword namedZoneOpt contained file ixfr-base
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
159 \ nextgroup=namedString skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
160 syn keyword namedZoneOpt contained notify dialup
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
161 \ nextgroup=namedBool,namedNotBool skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
162 syn keyword namedZoneOpt contained pubkey forward
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
163 syn keyword namedZoneOpt contained max-transfer-time-in
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
164 \ nextgroup=namedNumber,namedNotNumber skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
165 syn keyword namedZoneOpt contained type nextgroup=namedZoneType skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
166 syn keyword namedZoneType contained master slave stub forward hint
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
167
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
168 syn keyword namedZoneOpt contained masters forwarders
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
169 \ nextgroup=namedIPlist skipwhite
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
170 syn region namedIPlist contained start=+{+ end=+};+ contains=namedIPaddr,namedIPerror,namedParenError,namedComment
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
171 syn keyword namedZoneOpt contained allow-update allow-query allow-transfer
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
172 \ nextgroup=namedAML skipwhite
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
173 syn keyword namedZoneOpt contained update-policy
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
174 \ nextgroup=namedIntSection skipwhite
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
175
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
176 " --- boolean parameter
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
177 syn match namedNotBool contained "[^ ;]\+"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
178 syn keyword namedBool contained yes no true false 1 0
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
179
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
180 " --- number parameter
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
181 syn match namedNotNumber contained "[^ 0-9;]\+"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
182 syn match namedNumber contained "\d\+"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
183
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
184 " --- address match list
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
185 syn region namedAML contained start=+{+ end=+};+ contains=namedParenError,namedComment,namedString
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
186
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
187 " --- IPs & Domains
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
188 syn match namedIPaddr contained /\<[0-9]\{1,3}\(\.[0-9]\{1,3}\)\{3};/he=e-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
189 syn match namedDomain contained /\<[0-9A-Za-z][-0-9A-Za-z.]\+\>/ nextgroup=namedSpareDot
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
190 syn match namedDomain contained /"\."/ms=s+1,me=e-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
191 syn match namedSpareDot contained /\./
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
192
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
193 " --- syntax errors
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
194 syn match namedIllegalDom contained /"\S*[^-A-Za-z0-9.[:space:]]\S*"/ms=s+1,me=e-1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
195 syn match namedIPerror contained /\<\S*[^0-9.[:space:];]\S*/
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
196 syn match namedEParenError contained +{+
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
197 syn match namedParenError +}\([^;]\|$\)+
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
198
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
199 " Define the default highlighting.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
200 " For version 5.7 and earlier: only when not done already
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
201 " For version 5.8 and later: only when an item doesn't have highlighting yet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
202 if version >= 508 || !exists("did_named_syn_inits")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
203 if version < 508
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
204 let did_named_syn_inits = 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
205 command -nargs=+ HiLink hi link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
206 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
207 command -nargs=+ HiLink hi def link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
208 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
209
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
210 HiLink namedComment Comment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
211 HiLink namedInclude Include
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
212 HiLink namedKeyword Keyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
213 HiLink namedIntKeyword Keyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
214 HiLink namedIdentifier Identifier
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
215 HiLink namedIntIdent Identifier
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
216
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
217 HiLink namedString String
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
218 HiLink namedBool Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
219 HiLink namedNotBool Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
220 HiLink namedNumber Number
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
221 HiLink namedNotNumber Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
222
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
223 HiLink namedOption namedKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
224 HiLink namedLogOption namedKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
225 HiLink namedCNOption namedKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
226 HiLink namedQSKeywords Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
227 HiLink namedCNKeywords Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
228 HiLink namedLogCategory Type
1121
e63691e7c504 updated for version 7.1a
vimboss
parents: 60
diff changeset
229 HiLink namedIPaddr Number
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
230 HiLink namedDomain Identifier
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
231 HiLink namedZoneOpt namedKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
232 HiLink namedZoneType Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
233 HiLink namedParenError Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
234 HiLink namedEParenError Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
235 HiLink namedIllegalDom Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
236 HiLink namedIPerror Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
237 HiLink namedSpareDot Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
238 HiLink namedError Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
239
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
240 delcommand HiLink
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
241 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
242
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
243 let &cpo = s:save_cpo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
244 unlet s:save_cpo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
245
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
246 let b:current_syntax = "named"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
247
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
248 " vim: ts=17