summaryrefslogtreecommitdiffstats
path: root/package
diff options
context:
space:
mode:
authorwbx <wbx@3c298f89-4303-0410-b956-a3cf2f4a3e73>2005-09-21 05:18:56 +0000
committerwbx <wbx@3c298f89-4303-0410-b956-a3cf2f4a3e73>2005-09-21 05:18:56 +0000
commitb7277aee3c6e583d65600b48c33fb3315b384c6b (patch)
treef13860d452361d797ecdf42355790c74f7b2ae52 /package
parent3f6151e5fa6726471101e9e6a0916a6780ad97a5 (diff)
wifidog package from Philippe April, thx
git-svn-id: svn://svn.openwrt.org/openwrt/trunk/openwrt@1966 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package')
-rw-r--r--package/Config.in1
-rw-r--r--package/Makefile1
-rw-r--r--package/wifidog/Config.in12
-rw-r--r--package/wifidog/Makefile74
-rw-r--r--package/wifidog/files/wifidog.conf177
-rw-r--r--package/wifidog/files/wifidog.init3
-rw-r--r--package/wifidog/ipkg/wifidog.conffiles1
-rw-r--r--package/wifidog/ipkg/wifidog.control10
8 files changed, 279 insertions, 0 deletions
diff --git a/package/Config.in b/package/Config.in
index 344bda854..a373c9939 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -118,6 +118,7 @@ source "package/wpa_supplicant/Config.in"
source "package/wput/Config.in"
source "package/xinetd/Config.in"
source "package/wificonf/Config.in"
+source "package/wifidog/Config.in"
source "package/wiviz/Config.in"
source "package/wondershaper/Config.in"
diff --git a/package/Makefile b/package/Makefile
index dcb695f49..7c9cd2de7 100644
--- a/package/Makefile
+++ b/package/Makefile
@@ -174,6 +174,7 @@ package-$(BR2_PACKAGE_USBUTILS) += usbutils
package-$(BR2_PACKAGE_VTUN) += vtun
package-$(BR2_PACKAGE_VSFTPD) += vsftpd
package-$(BR2_PACKAGE_WIFICONF) += wificonf
+package-$(BR2_PACKAGE_WIFIDOG) += wifidog
package-$(BR2_PACKAGE_WIVIZ) += wiviz
package-$(BR2_PACKAGE_WIRELESS_TOOLS) += wireless-tools
package-$(BR2_PACKAGE_WOL) += wol
diff --git a/package/wifidog/Config.in b/package/wifidog/Config.in
new file mode 100644
index 000000000..75c579180
--- /dev/null
+++ b/package/wifidog/Config.in
@@ -0,0 +1,12 @@
+config BR2_PACKAGE_WIFIDOG
+ tristate "wifidog - wireless captive portal solution"
+ select BR2_PACKAGE_IPTABLES
+ select BR2_PACKAGE_IPTABLES_EXTRA
+ select BR2_PACKAGE_KMOD_IPTABLES_V4
+ select BR2_PACKAGE_KMOD_IPTABLES_V4_EXTRA
+ default m if CONFIG_DEVEL
+ help
+ The Wifidog project is a complete and embeddable captive
+ portal solution for wireless community groups or individuals
+ who wish to open a free Hotspot while still preventing abuse
+ of their Internet connection.
diff --git a/package/wifidog/Makefile b/package/wifidog/Makefile
new file mode 100644
index 000000000..b0992db1c
--- /dev/null
+++ b/package/wifidog/Makefile
@@ -0,0 +1,74 @@
+# $Id$
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=wifidog
+PKG_VERSION:=1.1.2
+PKG_RELEASE:=1
+PKG_MD5SUM:=8444ac5f761504c972f0ee3608dc09ce
+
+PKG_SOURCE_URL:= @SF/$(PKG_NAME)
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_CAT:=zcat
+
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
+PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
+
+include $(TOPDIR)/package/rules.mk
+
+$(eval $(call PKG_template,WIFIDOG,wifidog,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
+
+$(PKG_BUILD_DIR)/.configured: $(PKG_BUILD_DIR)/.prepared
+ (cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
+ $(TARGET_CONFIGURE_OPTS) \
+ CFLAGS="$(TARGET_CFLAGS)" \
+ CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
+ LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
+ ac_cv_func_malloc_0_nonnull=yes \
+ ac_cv_func_memcmp_working=yes \
+ ac_cv_func_setvbuf_reversed=no \
+ ./configure \
+ --target=$(GNU_TARGET_NAME) \
+ --host=$(GNU_TARGET_NAME) \
+ --build=$(GNU_HOST_NAME) \
+ --program-prefix="" \
+ --program-suffix="" \
+ --prefix=/usr \
+ --exec-prefix=/usr \
+ --bindir=/usr/bin \
+ --datadir=/usr/share \
+ --includedir=/usr/include \
+ --infodir=/usr/share/info \
+ --libdir=/usr/lib \
+ --libexecdir=/usr/lib \
+ --localstatedir=/var \
+ --mandir=/usr/share/man \
+ --sbindir=/usr/sbin \
+ --sysconfdir=/etc \
+ $(DISABLE_LARGEFILE) \
+ $(DISABLE_NLS) \
+ );
+ touch $(PKG_BUILD_DIR)/.configured
+
+$(PKG_BUILD_DIR)/.built: $(PKG_BUILD_DIR)/.configured
+ $(MAKE) -C $(PKG_BUILD_DIR) \
+ $(TARGET_CONFIGURE_OPTS)
+ mkdir -p $(PKG_INSTALL_DIR)
+ $(MAKE) -C $(PKG_BUILD_DIR) \
+ DESTDIR="$(PKG_INSTALL_DIR)" \
+ install
+ touch $(PKG_BUILD_DIR)/.built
+
+$(IPKG_WIFIDOG):
+ install -m0755 -d $(IDIR_WIFIDOG)/etc/init.d
+ install -m0755 ./files/$(PKG_NAME).init $(IDIR_WIFIDOG)/etc/init.d/S65wifidog
+ install -m0644 ./files/wifidog.conf $(IDIR_WIFIDOG)/etc/
+ install -m0755 -d $(IDIR_WIFIDOG)/usr/bin
+ install -m0755 -d $(IDIR_WIFIDOG)/usr/lib
+ install -m0755 $(PKG_BUILD_DIR)/scripts/init.d/wifidog $(IDIR_WIFIDOG)/usr/bin/wifidog-init
+ cp -fpR $(PKG_INSTALL_DIR)/usr/bin/wifidog $(IDIR_WIFIDOG)/usr/bin/
+ cp -fpR $(PKG_INSTALL_DIR)/usr/bin/wdctl $(IDIR_WIFIDOG)/usr/bin/
+ cp -fpR $(PKG_INSTALL_DIR)/usr/lib/libhttpd.so* $(IDIR_WIFIDOG)/usr/lib/
+ $(RSTRIP) $(IDIR_WIFIDOG)
+ $(IPKG_BUILD) $(IDIR_WIFIDOG) $(PACKAGE_DIR)
+
diff --git a/package/wifidog/files/wifidog.conf b/package/wifidog/files/wifidog.conf
new file mode 100644
index 000000000..10b173a9a
--- /dev/null
+++ b/package/wifidog/files/wifidog.conf
@@ -0,0 +1,177 @@
+# $Header$
+# WiFiDog Configuration file
+
+# Parameter: GatewayID
+# Default: default
+# Optional but essential for monitoring purposes
+#
+# Set this to the template ID on the auth server
+# this is used to give a customized login page to the clients
+# If none is supplied, the default login page will be used.
+
+GatewayID default
+
+# Parameter: ExternalInterface
+# Default: NONE
+# Optional
+#
+# Set this to the external interface. Typically vlan1 for OpenWrt, and eth0 or ppp0 otherwise
+
+# ExternalInterface eth0
+
+# Parameter: GatewayInterface
+# Default: NONE
+# Mandatory
+#
+# Set this to the internal interface. Typically br0 for OpenWrt, and eth1 otherwise
+
+GatewayInterface br0
+
+# Parameter: GatewayAddress
+# Default: Find it from GatewayInterface
+# Optional
+#
+# Set this to the internal IP address of the gateway
+
+# GatewayAddress 192.168.1.1
+
+# Parameter: AuthServMaxTries
+# Default: 1
+# Optional
+#
+# Sets the number of auth servers the gateway will attempt to contact when a request fails.
+# this number should be equal to the number of AuthServer lines in this
+# configuration but it should probably not exceed 3.
+
+# AuthServMaxTries 3
+
+# Parameter: AuthServer
+# Default: NONE
+# Mandatory
+#
+# Set this to the hostname or IP of your auth server, the path where
+# WiFiDog-auth resides and optionally as a second argument, the port it
+# listens on.
+#AuthServer {
+# Hostname (Mandatory; Default: NONE)
+# SSLAvailable (Optional; Default: no; Possible values: yes, no)
+# SSLPort 443 (Optional; Default: 443)
+# HTTPPort 80 (Optional; Default: 80)
+# Path wifidog/ (Optional; Default: /wifidog/ Note: The path must be both prefixed and suffixed by /. Use a single / for server root.)
+#}
+
+#AuthServer {
+# Hostname auth.ilesansfil.org
+# SSLAvailable yes
+# Path /
+#}
+
+#AuthServer {
+# Hostname auth2.ilesansfil.org
+# SSLAvailable yes
+# Path /
+#}
+
+#AuthServer {
+# Hostname auth3.ilesansfil.org
+# SSLAvailable yes
+# Path /
+#}
+
+# Parameter: Daemon
+# Default: 1
+# Optional
+#
+# Set this to true if you want to run as a daemon
+# Daemon 1
+
+# Parameter: GatewayPort
+# Default: 2060
+# Optional
+#
+# Listen on this port
+# GatewayPort 2060
+
+# Parameter: HTTPDName
+# Default: WiFiDog
+# Optional
+#
+# Define what name the HTTPD server will respond
+# HTTPDName WiFiDog
+
+# Parameter: HTTPDMaxConn
+# Default: 10
+# Optional
+#
+# How many sockets to listen to
+# HTTPDMaxConn 10
+
+# Parameter: CheckInterval
+# Default: 60
+# Optional
+#
+# How many seconds should we wait between timeout checks
+CheckInterval 60
+
+# Parameter: ClientTimeout
+# Default: 5
+# Optional
+#
+# Set this to the desired of number of CheckInterval of inactivity before a client is logged out
+# The timeout will be INTERVAL * TIMEOUT
+ClientTimeout 5
+
+# Parameter: FirewallRuleSet
+# Default: none
+# Mandatory
+#
+# Groups a number of FirewallRule statements together.
+
+# Parameter: FirewallRule
+# Default: none
+#
+# Define one firewall rule in a rule set.
+
+# Rule Set: global
+#
+# Used for rules to be applied to all other rulesets except locked.
+# This is the default config for the Teliphone service.
+FirewallRuleSet global {
+ FirewallRule allow udp to 69.90.89.192/27
+ FirewallRule allow udp to 69.90.85.0/27
+ FirewallRule allow tcp port 80 to 69.90.89.205
+}
+
+# Rule Set: validating-users
+#
+# Used for new users validating their account
+FirewallRuleSet validating-users {
+ FirewallRule block tcp port 25
+ FirewallRule allow to 0.0.0.0/0
+}
+
+# Rule Set: known-users
+#
+# Used for normal validated users.
+FirewallRuleSet known-users {
+ FirewallRule allow to 0.0.0.0/0
+}
+
+# Rule Set: unknown-users
+#
+# Used for unvalidated users, this is the ruleset that gets redirected.
+#
+# XXX The redirect code adds the Default DROP clause.
+FirewallRuleSet unknown-users {
+ FirewallRule allow udp port 53
+ FirewallRule allow tcp port 53
+ FirewallRule allow udp port 67
+ FirewallRule allow tcp port 67
+}
+
+# Rule Set: locked-users
+#
+# Used for users that have been locked out.
+FirewallRuleSet locked-users {
+ FirewallRule block to 0.0.0.0/0
+}
diff --git a/package/wifidog/files/wifidog.init b/package/wifidog/files/wifidog.init
new file mode 100644
index 000000000..03e2ea221
--- /dev/null
+++ b/package/wifidog/files/wifidog.init
@@ -0,0 +1,3 @@
+#!/bin/sh
+/usr/bin/wifidog-init start
+
diff --git a/package/wifidog/ipkg/wifidog.conffiles b/package/wifidog/ipkg/wifidog.conffiles
new file mode 100644
index 000000000..aaa3dd140
--- /dev/null
+++ b/package/wifidog/ipkg/wifidog.conffiles
@@ -0,0 +1 @@
+/etc/wifidog.conf
diff --git a/package/wifidog/ipkg/wifidog.control b/package/wifidog/ipkg/wifidog.control
new file mode 100644
index 000000000..3812e114d
--- /dev/null
+++ b/package/wifidog/ipkg/wifidog.control
@@ -0,0 +1,10 @@
+Package: wifidog
+Priority: optional
+Section: net
+Maintainer: Philippe April <philippe@ilesansfil.org>
+Source: buildroot internal
+Depends: iptables, iptables-extra, kmod-iptables-extra
+Description: WiFiDog is a complete and embeddable captive portal
+ solution for wireless community groups or individuals who
+ wish to open a free Hotspot while still preventing abuse
+ of their Internet connection.