Add pepperspot, IPv4/IPv6 captive portal
git-svn-id: svn://svn.openwrt.org/openwrt/packages@13626 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
9efbe01f3d
commit
e86dc1cec2
58
net/pepperspot/Makefile
Normal file
58
net/pepperspot/Makefile
Normal file
@ -0,0 +1,58 @@
|
||||
#
|
||||
# Copyright (C) 2008 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
# $Id: $
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=pepperspot
|
||||
PKG_VERSION:=0.1
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||
PKG_SOURCE_URL:=@SF/pepperspot
|
||||
PKG_MD5SUM:=52e5861f6cae05a972b8a159be270bf7
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/pepperspot
|
||||
SUBMENU:=Captive Portals
|
||||
SECTION:=net
|
||||
CATEGORY:=Network
|
||||
DEPENDS:=+kmod-tun
|
||||
TITLE:=Wireless LAN HotSpot controller
|
||||
URL:=http://www.pepperspot.org/
|
||||
endef
|
||||
|
||||
define Package/pepperspot/description
|
||||
PepperSpot is a captive portal or wireless LAN access point controller
|
||||
which support the IPv6 protocol. It supports web based login and it
|
||||
supports Wireless Protected Access (WPA). Authentication is handled by
|
||||
your favorite radius server (over IPv4/IPv6).
|
||||
endef
|
||||
|
||||
define Package/pepperspot/conffiles
|
||||
/etc/pepper.conf
|
||||
endef
|
||||
|
||||
# uses GNU configure
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
DESTDIR="$(PKG_INSTALL_DIR)" \
|
||||
all install
|
||||
endef
|
||||
|
||||
define Package/pepperspot/install
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) ./files/$(PKG_NAME).init $(1)/etc/init.d/pepper
|
||||
$(INSTALL_DIR) $(1)/etc
|
||||
$(INSTALL_DATA) $(PKG_BUILD_DIR)/doc/pepper.conf $(1)/etc/
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/pepper $(1)/usr/sbin/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,pepperspot))
|
19
net/pepperspot/files/pepperspot.init
Normal file
19
net/pepperspot/files/pepperspot.init
Normal file
@ -0,0 +1,19 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
# Copyright (C) 2008 OpenWrt.org
|
||||
START=50
|
||||
|
||||
RUN_D=/var/run
|
||||
PID_F=$RUN_D/pepper.pid
|
||||
|
||||
start() {
|
||||
include /lib/network
|
||||
scan_interfaces
|
||||
/sbin/insmod tun >/dev/null 2>&1
|
||||
[ -d $RUN_D ] || mkdir -p $RUN_D
|
||||
config_get ipaddr lan ipaddr
|
||||
/usr/sbin/pepper --dns1="$ipaddr"
|
||||
}
|
||||
|
||||
stop() {
|
||||
[ -f $PID_F ] && kill $(cat $PID_F) >/dev/null 2>&1
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user