I am trying to setup an access point on a raspberry pi 3 v1.2 using this repository create_ap with this Wifi adapter
Bus 001 Device 005: ID 0bda:8178 Realtek Semiconductor Corp. RTL8192CU 802.11n WLAN Adapter
I tried creating an AP with this adapter in a Kali vm on my pc and it works flawlessly but on the raspberry pi it returns a weird error
iptables v1.8.4 (nf_tables): Couldn't load match `tcp':No such file or directory
so I think this is a software software problem
when trying the following commands on the raspberry
iptables -t nat -L
iptables -S
iptables -L
I get the following error for all three commands
iptables v1.8.4 (nf_tables): Could not fetch rule set generation id: Invalid argument
I tried reinstalling hostapd and dnsmasq also the iptables but i was not successful at all
the kernel on the kali vm is
Linux 5.5.0-kali2-amd64
and the kernel on the raspberry is
Linux 4.19.93-Re4son-v8+
both the vm and raspberry are running Kali Linux downloaded from the official site
both WiFi adapters on the raspberry support AP mode and i checked that using this command
iw list
I am not asking for a couple of commands to write or a script to run and fix my problem i asking for explanation for this problem and guidelines where to look and if i have missed something