How To Install fwknop on Fedora 34
Introduction
In this tutorial we learn how to install fwknop
on Fedora 34.
What is fwknop
fwknop implements an authorization scheme known as Single Packet Authorization (SPA) that requires only a single encrypted packet to communicate various pieces of information including desired access through an iptables policy and/or specific commands to execute on the target system. The main application of this program is to protect services such as SSH with an additional layer of security in order to make the exploitation of vulnerabilities (both 0-day and unpatched code) much more difficult. The authorization server passively monitors authorization packets via libpcap and hence there is no “server” to which to connect in the traditional sense. Any service protected by fwknop is inaccessible (by using iptables to intercept packets within the kernel) before authenticating; anyone scanning for the service will not be able to detect that it is even listening. This authorization scheme offers many advantages over port knocking, include being non-replayable, much more data can be communicated, and the scheme cannot be broken by simply connecting to extraneous ports on the server in an effort to break knock sequences. The authorization packets can easily be spoofed as well, and this makes it possible to make it appear as though, say, www.yahoo.com is trying to authenticate to a target system but in reality the actual connection will come from a seemingly unrelated IP. Although the default data collection method is to use libpcap to sniff packets off the wire, fwknop can also read packets out of a file that is written by the iptables ulogd pcap writer or by a separate sniffer process. fwknop 2.6.10 7.fc34 x86_64 197 k fwknop-2.6.10-7.fc34.src.rpm fedora A Single Packet Authorization (SPA) implementation http GPLv2 fwknop implements an authorization scheme known as Single Packet Authorization (SPA) that requires only a single encrypted packet to communicate various pieces of information including desired access through an iptables policy and/or specific commands to execute on the target system. The main application of this program is to protect services such as SSH with an additional layer of security in order to make the exploitation of vulnerabilities (both 0-day and unpatched code) much more difficult. The authorization server passively monitors authorization packets via libpcap and hence there is no “server” to which to connect in the traditional sense. Any service protected by fwknop is inaccessible (by using iptables to intercept packets within the kernel) before authenticating; anyone scanning for the service will not be able to detect that it is even listening. This authorization scheme offers many advantages over port knocking, include being non-replayable, much more data can be communicated, and the scheme cannot be broken by simply connecting to extraneous ports on the server in an effort to break knock sequences. The authorization packets can easily be spoofed as well, and this makes it possible to make it appear as though, say, www.yahoo.com is trying to authenticate to a target system but in reality the actual connection will come from a seemingly unrelated IP. Although the default data collection method is to use libpcap to sniff packets off the wire, fwknop can also read packets out of a file that is written by the iptables ulogd pcap writer or by a separate sniffer process.
We can use yum
or dnf
to install fwknop
on Fedora 34. In this tutorial we discuss both methods but you only need to choose one of method to install fwknop.
Install fwknop on Fedora 34 Using dnf
Update yum database with dnf
using the following command.
sudo dnf makecache --refresh
The output should look something like this:
Fedora 34 - x86_64 20 kB/s | 6.6 kB 00:00
Fedora 34 openh264 (From Cisco) - x86_64 1.4 kB/s | 989 B 00:00
Fedora Modular 34 - x86_64 68 kB/s | 6.5 kB 00:00
Fedora 34 - x86_64 - Updates 3.5 kB/s | 6.2 kB 00:01
Fedora Modular 34 - x86_64 - Updates 17 kB/s | 5.9 kB 00:00
Metadata cache created.
After updating yum database, We can install fwknop
using dnf
by running the following command:
sudo dnf -y install fwknop
Install fwknop on Fedora 34 Using yum
Update yum database with yum
using the following command.
sudo yum makecache --refresh
The output should look something like this:
Fedora 34 - x86_64 20 kB/s | 6.6 kB 00:00
Fedora 34 openh264 (From Cisco) - x86_64 1.4 kB/s | 989 B 00:00
Fedora Modular 34 - x86_64 68 kB/s | 6.5 kB 00:00
Fedora 34 - x86_64 - Updates 3.5 kB/s | 6.2 kB 00:01
Fedora Modular 34 - x86_64 - Updates 17 kB/s | 5.9 kB 00:00
Metadata cache created.
After updating yum database, We can install fwknop
using yum
by running the following command:
sudo yum -y install fwknop
How To Uninstall fwknop on Fedora 34
To uninstall only the fwknop
package we can use the following command:
sudo dnf remove fwknop
fwknop Package Contents on Fedora 34
/etc/fwknop
/etc/fwknop/access.conf
/etc/fwknop/fwknopd.conf
/usr/bin/fwknop
/usr/lib/.build-id
/usr/lib/.build-id/14
/usr/lib/.build-id/14/f7885ea66476b7e39d94686c8dffb4e453b145
/usr/lib/.build-id/35
/usr/lib/.build-id/35/918de83dadf6b344b394fbb3066ef8062ab94b
/usr/lib/.build-id/ec
/usr/lib/.build-id/ec/ac6a9a32499c53eaa59825bc76216811010715
/usr/lib/libfko.so.3
/usr/lib/libfko.so.3.0.0
/usr/lib/systemd/system/fwknopd.service
/usr/sbin/fwknopd
/usr/share/doc/fwknop
/usr/share/doc/fwknop/CREDITS
/usr/share/doc/fwknop/ChangeLog
/usr/share/doc/fwknop/README
/usr/share/licenses/fwknop
/usr/share/licenses/fwknop/COPYING
/usr/share/man/man8/fwknop.8.gz
/usr/share/man/man8/fwknopd.8.gz
/etc/fwknop
/etc/fwknop/access.conf
/etc/fwknop/fwknopd.conf
/usr/bin/fwknop
/usr/lib/.build-id
/usr/lib/.build-id/1c
/usr/lib/.build-id/1c/fe6a39a43d74dc256169dd27a051336f198908
/usr/lib/.build-id/70
/usr/lib/.build-id/70/5ffd4c918f5c31c99e6c5458ba1886e33f4b50
/usr/lib/.build-id/8c
/usr/lib/.build-id/8c/3bde1bd3aeb6cf1d7db7ec86769c4b3ed7ca96
/usr/lib/systemd/system/fwknopd.service
/usr/lib64/libfko.so.3
/usr/lib64/libfko.so.3.0.0
/usr/sbin/fwknopd
/usr/share/doc/fwknop
/usr/share/doc/fwknop/CREDITS
/usr/share/doc/fwknop/ChangeLog
/usr/share/doc/fwknop/README
/usr/share/licenses/fwknop
/usr/share/licenses/fwknop/COPYING
/usr/share/man/man8/fwknop.8.gz
/usr/share/man/man8/fwknopd.8.gz
References
- [fwknop website](http://www.cipherdyne.org/fwknop/ http://www.cipherdyne.org/fwknop/)
Summary
In this tutorial we learn how to install fwknop
on Fedora 34 using yum and dnf.