aboutsummaryrefslogtreecommitdiffstats
path: root/package
diff options
context:
space:
mode:
authorPeter Denison <openwrt@marshadder.org>2008-09-30 00:56:55 +0000
committerPeter Denison <openwrt@marshadder.org>2008-09-30 00:56:55 +0000
commite176f409c03d04ace99cdc74fcff41c363a1b578 (patch)
treee4c345977d76d42dcb70bef1d5dd73d262864ad6 /package
parent017d53ec2131af5626d36aa451c092b9684aaeb2 (diff)
downloadmaster-187ad058-e176f409c03d04ace99cdc74fcff41c363a1b578.tar.gz
master-187ad058-e176f409c03d04ace99cdc74fcff41c363a1b578.tar.bz2
master-187ad058-e176f409c03d04ace99cdc74fcff41c363a1b578.zip
Allow dropbear to use shadow passwords, and correct base-files generation of
/etc/shadow git-svn-id: svn://svn.openwrt.org/openwrt/trunk@12809 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package')
-rw-r--r--package/base-files/Makefile7
-rw-r--r--package/dropbear/Makefile4
2 files changed, 8 insertions, 3 deletions
diff --git a/package/base-files/Makefile b/package/base-files/Makefile
index 9f745aa173..4f8569ec27 100644
--- a/package/base-files/Makefile
+++ b/package/base-files/Makefile
@@ -146,7 +146,12 @@ define Package/base-files$(TARGET)/install
$(CP) $(PLATFORM_SUBDIR)/base-files-$(PROFILE)/* $(1)/; \
fi \
)
- $(if $(CONFIG_BUSYBOX_CONFIG_FEATURE_SHADOWPASSWDS),cp $(1)/etc/passwd $(1)/etc/shadow)
+# Form valid /etc/shadow entries, by copying the user:pw pairs
+# from /etc/passwd, and adding on pw change data
+ $(if $(CONFIG_BUSYBOX_CONFIG_FEATURE_SHADOWPASSWDS), \
+ cut -d ':' -f 1-2 $(1)/etc/passwd > $(1)/etc/shadow; \
+ $(SED) 's/$$$$/:13848:0:99999:7:::/' $(1)/etc/shadow \
+ )
$(SED) 's,$$$$R,$(REVISION),g' $(1)/etc/banner
mkdir -p $(1)/dev
mkdir -p $(1)/etc/crontabs
diff --git a/package/dropbear/Makefile b/package/dropbear/Makefile
index 96eb5911d7..a98c24aa2a 100644
--- a/package/dropbear/Makefile
+++ b/package/dropbear/Makefile
@@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=dropbear
PKG_VERSION:=0.51
-PKG_RELEASE:=1
+PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:= \
@@ -47,7 +47,7 @@ CONFIGURE_ARGS += \
--disable-pam \
--enable-openpty \
--enable-syslog \
- --disable-shadow \
+ $(if $(CONFIG_SHADOW_PASSWORDS),,--disable-shadow) \
--disable-lastlog \
--disable-utmp \
--disable-utmpx \