treewide: install configs with INSTALL_CONF (0600)

Use INSTALL_CONF instead of INSTALL_DATA to install configuration
 files under /etc with correct permissions.

This improves security by ensuring config files are not world-readable.
INSTALL_DATA sets mode 0644, while INSTALL_CONF sets mode 0600.

Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com>
This commit is contained in:
Josef Schlehofer
2025-06-16 22:40:05 +02:00
parent 58070aa6c1
commit 03a13710ea
7 changed files with 15 additions and 15 deletions

View File

@@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=naywatch
PKG_VERSION:=1
PKG_RELEASE:=7
PKG_RELEASE:=8
PKG_MAINTAINER:=Nick Hainke <vincent@systemli.org>
PKG_LICENSE:=GPL-2.0-only
@@ -44,7 +44,7 @@ define Package/naywatch/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) ./files/naywatch.sh $(1)/usr/bin/naywatch
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DATA) ./files/naywatch.config $(1)/etc/config/naywatch
$(INSTALL_CONF) ./files/naywatch.config $(1)/etc/config/naywatch
endef
$(eval $(call BuildPackage,naywatch))