2

I don't know unfortunately when it stopped working, because I was using it as a fire and forget solution. Not so long ago I checked it with gufw and was stunned to realize my machine is naked.

root@asus:/etc/ufw# dpkg -l | grep ufw
ii  gufw   19.10.0-2
ii  ufw    0.36-1


root@asus:/etc/ufw# dpkg -l | grep tables
ii  iptables               1.8.4-11
ii  iptables-dev:amd64     1.8.3-2
ii  libnftables1:amd64     0.9.3-2
ii  libnftnl11:amd64       1.1.5-1
ii  libxtables-dev:amd64   1.8.4-1
ii  libxtables12:amd64     1.8.4-1
ii  nftables               0.9.3-2

I'm running with a 5.3.0-3-amd64 kernel.

The actual error:

root@asus:/# ufw enable
ERROR: problem running ufw-init
Bad argument `DROP'
Error occurred at line: 4
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 4
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
iptables-restore: line 2 failed
Bad argument `-'
Error occurred at line: 3
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 3
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 3
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 3
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
iptables-restore v1.8.4 (nf_tables): Chain 'ufw-user-input' does not exist
Error occurred at line: 2
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
Bad argument `DROP'
Error occurred at line: 4
Try `ip6tables-restore -h' or 'ip6tables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 4
Try `ip6tables-restore -h' or 'ip6tables-restore --help' for more information.
ip6tables-restore: line 2 failed
Bad argument `-'
Error occurred at line: 3
Try `ip6tables-restore -h' or 'ip6tables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 3
Try `ip6tables-restore -h' or 'ip6tables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 3
Try `ip6tables-restore -h' or 'ip6tables-restore --help' for more information.
Bad argument `-'
Error occurred at line: 3
Try `ip6tables-restore -h' or 'ip6tables-restore --help' for more information.
ip6tables-restore v1.8.4 (nf_tables): Chain 'ufw6-user-input' does not exist
Error occurred at line: 2
Try `ip6tables-restore -h' or 'ip6tables-restore --help' for more information.

Problem running '/etc/ufw/user.rules'
Problem running '/etc/ufw/user6.rules'

I haven't found any telling hits on this (a lot of ufw problems but not this type). I wonder if it's something with the kernel's iptables support, the fact that nftables package somehow got itself into the installed packages or something else? If I delete the before*.rules or after*.rules from /etc/ufw I get an error because of that, the scripts look for those files.

I wonder if anyone has the same error message for ufw enable. Right now my ufw is inactive.

root@asus:/etc/ufw# lsmod | grep tables
ip6_tables             36864  0
ip_tables              32768  0
x_tables               49152  17 xt_conntrack,nft_compat,xt_LOG,xt_multiport,xt_tcpudp,xt_hashlimit,xt_addrtype,xt_recent,ip6t_rt,xt_comment,ip6_tables,ipt_REJECT,ip_tables,xt_limit,xt_hl,xt_MASQUERADE,ip6t_REJECT
nf_tables             163840  46 nft_compat,nft_counter,nft_chain_nat,nft_limit
nfnetlink              16384  4 nft_compat,nf_conntrack_netlink,nf_tables
Csaba Toth
  • 1,498

1 Answers1

1

I had the same error in Debian.

I switched back to iptables-legacy according to the information on this site.