Re: Vim script highlighter, beta; 850 keywords; 2,400 states
S Egbert <[email protected]> Wed, 3 Dec 2025 10:11:48 -0600
| Newsgroups | gmane.comp.security.firewalls.netfilter.general |
|---|---|
| Message-ID | <[email protected]> |
Updated nftables rules syntax highlighter it to include every possible
supported syntax found in v1.1.4, (except for
DCCP/SCTP/Geneve/VXLAN/inner-outer-headers).
https://github.com/egberts/vim-script-nftables/README.md
Now works with over 50 color schemes (unit tested), dark or light.
An animated GIF showcasing this highlighting:
https://github.com/egberts/vim-syntax-nftables/blob/master/doc/nftables.gif
Installer:
https://github.com/egberts/vim-syntax-nftables.git
cd vim-syntax-nftables
make install
vi /etc/nftables.conf
vi /etc/nftables/my_firewall.nft
make uninstall
Tested on Debian 11/12/13, Fedora, Gentoo
Unit-test Test generators tried all possible settings, example for 'ip
saddr' statement:
https://github.com/egberts/vim-syntax-nftables/blob/master/test/ip_hdr_expr_relational_expr.nft
Next, make it work for my EVPN-VXLAN firewalls (inner-outer header) for
my multi-tenant Geneve/VXLAN overlays and finish up DCCP/SCTP.
Enjoy.
On 9/8/25 10:43 PM, S Egbert wrote:
> Well,
>
>
> Finally poured in my latest and greatest Vim script highlighter for
> nftables v1.1.4. They are in 'Github'.
>
>
> Pretty sure that I've forgotten a few things. Maybe it is that I just a
> needed a breather. (Vimscript is extremely large, runs fast on Pentium
> laptop.)
>
> Video embedded in README.md.
>
> https://github.com/egberts/vim-script-nftables/README.md
>
>
> Enjoy.
>
> Steve Egbert
>
>