Installing netfilterqueue in Kali

I had some trouble recently trying to install the python library netfilterqueue onto my Kali box as the usual pip or pip3 commands didn’t seem to work.

both python 2 and python 3 brought back a similiar error:

1

Command “/usr/bin/python3 -u -c “import setuptools, tokenize;__file__=’/tmp/pip-install-8l8q2wql/netfilterqueue/setup.py’;f=getattr(tokenize, ‘open’, open)(__file__);code=f.read().replace(‘\r\n’, ‘\n’);f.close();exec(compile(code, __file__, ‘exec’))” install –record /tmp/pip-record-sk6qu_jn/install-record.txt –single-version-externally-managed –compile” failed with error code 1 in /tmp/pip-install-8l8q2wql/netfilterqueue/

One method to get around it is to try and install it on a different flavour of Linux, but after a bit of trial and error I found that you can get it onto Kali using:

sudo apt-get install python-netfilterqueue

2

This gets it onto your machine for python 2:

3.png