xref: /vim-8.2.3635/runtime/syntax/ipfilter.vim (revision 89bcfda6)
1" ipfilter syntax file
2" Language: ipfilter configuration file
3" Maintainer: Hendrik Scholz <[email protected]>
4" Last Change: 2005 Jan 27
5"
6" http://www.wormulon.net/files/misc/ipfilter.vim
7"
8" This will also work for OpenBSD pf but there might be some tags that are
9" not correctly identified.
10" Please send comments to [email protected]
11
12" quit when a syntax file was already loaded
13if exists("b:current_syntax")
14  finish
15endif
16
17" Comment
18syn match	IPFComment	/#.*$/	contains=ipfTodo
19syn keyword	IPFTodo		TODO XXX FIXME contained
20
21syn keyword IPFActionBlock	block
22syn keyword IPFActionPass	pass
23syn keyword	IPFProto	tcp udp icmp
24syn keyword	IPFSpecial	quick log first
25" how could we use keyword for words with '-' ?
26syn match	IPFSpecial	/return-rst/
27syn match	IPFSpecial	/dup-to/
28"syn match	IPFSpecial	/icmp-type unreach/
29syn keyword IPFAny		all any
30syn match	IPFIPv4		/\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}/
31syn match	IPFNetmask	/\/\d\+/
32
33" service name constants
34syn keyword IPFService	auth bgp domain finger ftp http https ident
35syn keyword IPFService	imap irc isakmp kerberos mail nameserver nfs
36syn keyword IPFService	nntp ntp pop3 portmap pptp rpcbind rsync smtp
37syn keyword IPFService	snmp snmptrap socks ssh sunrpc syslog telnet
38syn keyword IPFService	tftp www
39
40" Comment
41hi def link IPFComment	Comment
42hi def link IPFTodo		Todo
43
44hi def link IPFService	Constant
45
46hi def link IPFAction	Type
47hi def link ipfActionBlock	String
48hi def link ipfActionPass	Type
49hi def link IPFSpecial	Statement
50hi def link IPFIPv4		Label
51hi def link IPFNetmask	String
52hi def link IPFAny		Statement
53hi def link IPFProto	Identifier
54
55