Add ability to configure a static remote ip in pptp config file
This change has backward compatibility with old config files
Also remove the MAINTAINER as intructed
Signed-off-by: Thiago Pereira Ricciardi <thiago.ricciardi@gmail.com>
PKG_NAME:=pptpd
PKG_VERSION:=1.4.0
-PKG_RELEASE:=4
+PKG_RELEASE:=5
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=@SF/poptop
PKG_INSTALL:=1
PKG_BUILD_PARALLEL:=1
-PKG_MAINTAINER:=Luka Perkov <luka@openwrt.org>
-
include $(INCLUDE_DIR)/package.mk
define Package/pptpd
validate_login_section() {
uci_load_validate pptpd login "$1" "$2" \
'username:string' \
- 'password:string'
+ 'password:string' \
+ 'remoteip:string'
}
validate_pptpd_section() {
[ -n "$username" ] || return 0
[ -n "$password" ] || return 0
+ [ -n "$remoteip" ] || remoteip=*
- echo "$username pptp-server $password *" >> $CHAP_SECRETS
+ echo "$username pptp-server $password $remoteip" >> $CHAP_SECRETS
}
setup_config() {