2 # Copyright (C) 2011-2012 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR)/rules.mk
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:=http://www.cipherdyne.org/fwknop/download
16 PKG_MD5SUM:=96de4c5a4ae75a8618ef80269c6a70ad
20 include $(INCLUDE_DIR)/package.mk
22 define Package/fwknop/Default
23 TITLE:=FireWall KNock OPerator
24 URL:=http://www.cipherdyne.org/fwknop/
25 MAINTAINER:=Jonathan Bennett <jbscience87@gmail.com>
28 define Package/fwknop/Default/description
29 Fwknop implements an authorization scheme known as Single Packet Authorization
30 (SPA) for Linux systems running iptables. This mechanism requires only a
31 single encrypted and non-replayed packet to communicate various pieces of
32 information including desired access through an iptables policy. The main
33 application of this program is to use iptables in a default-drop stance to
34 protect services such as SSH with an additional layer of security in order to
35 make the exploitation of vulnerabilities (both 0-day and unpatched code) much
39 define Package/fwknopd
40 $(call Package/fwknop/Default)
45 DEPENDS:=+iptables +libfko +libpcap
48 define Package/fwknopd/description
49 $(call Package/fwknop/Default/description)
50 This package contains the fwknop daemon.
53 define Package/fwknopd/conffiles
54 /etc/fwknop/access.conf
55 /etc/fwknop/fwknopd.conf
59 $(call Package/fwknop/Default)
67 define Package/fwknop/description
68 $(call Package/fwknop/Default/description)
69 This package contains the fwknop client.
73 $(call Package/fwknop/Default)
80 define Package/libfko/description
81 $(call Package/fwknop/Default/description)
82 This package contains the libfko shared library.
87 --with-iptables=/usr/sbin/iptables
89 define Build/InstallDev
90 $(INSTALL_DIR) $(1)/usr/include
91 $(CP) $(PKG_INSTALL_DIR)/usr/include/fko.h $(1)/usr/include/
92 $(INSTALL_DIR) $(1)/usr/lib
93 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfko.{a,la,so*} $(1)/usr/lib/
96 define Package/fwknopd/install
97 $(INSTALL_DIR) $(1)/etc/fwknop
98 $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/fwknop/{access,fwknopd}.conf \
100 $(INSTALL_DIR) $(1)/etc/init.d
101 $(INSTALL_BIN) $(PKG_BUILD_DIR)/extras/fwknop.init.openwrt \
102 $(1)/etc/init.d/fwknopd
103 $(INSTALL_DIR) $(1)/usr/sbin
104 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/fwknopd $(1)/usr/sbin/
107 define Package/fwknop/install
108 $(INSTALL_DIR) $(1)/usr/bin
109 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/fwknop $(1)/usr/bin/
112 define Package/libfko/install
113 $(INSTALL_DIR) $(1)/usr/lib
114 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libfko.so.* $(1)/usr/lib/
117 $(eval $(call BuildPackage,fwknopd))
118 $(eval $(call BuildPackage,fwknop))
119 $(eval $(call BuildPackage,libfko))