aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Liske <thomas@fiasko-nw.net>2020-08-17 11:08:15 +0200
committerLeo <thinkabit.ukim@gmail.com>2020-08-17 13:43:14 +0000
commit87d8c4f3316b1d8df4b8bcfdb29ec2c39c37353d (patch)
tree5fcb06497114020d08144b9e3ea3434f0e625c43
parent09c3d84e6dcc7ec72020c93e40d635e49beb86ac (diff)
downloadaports-87d8c4f3316b1d8df4b8bcfdb29ec2c39c37353d.tar.gz
aports-87d8c4f3316b1d8df4b8bcfdb29ec2c39c37353d.tar.bz2
aports-87d8c4f3316b1d8df4b8bcfdb29ec2c39c37353d.tar.xz
main/iptables: use checkpath in initd to create non-public files
-rw-r--r--main/iptables/APKBUILD6
-rw-r--r--main/iptables/ebtables.initd3
-rw-r--r--main/iptables/iptables.initd3
3 files changed, 5 insertions, 7 deletions
diff --git a/main/iptables/APKBUILD b/main/iptables/APKBUILD
index 73fbf4eeeb..7116331708 100644
--- a/main/iptables/APKBUILD
+++ b/main/iptables/APKBUILD
@@ -2,7 +2,7 @@
pkgname=iptables
pkgver=1.8.5
-pkgrel=1
+pkgrel=2
pkgdesc="Linux kernel firewall, NAT and packet mangling tools"
url="https://www.netfilter.org/projects/iptables/index.html"
arch="all"
@@ -79,8 +79,8 @@ ip6tables_openrc() {
}
sha512sums="6a6baa541bb7aa331b176e0a91894e0766859814b59e77c71351ac34d6ebd337487981db48c70e476a48c67bcf891cfc663221a7582feb1496ad1df56eb28da8 iptables-1.8.5.tar.bz2
-059b3bd8dd7dec60060ec5eb1e639fe8203207629f3a7dd4fdbe5ebca3f7e9b80df5592ebb27542e31830fd15a53cffac5772567053c104dfccf9b78613a31a1 iptables.initd
+19cb376bd7a48889daa41ae34d31dfbeac1c277476496e3a1901dc91775c8f596681e0cbccd5c4618158de45da24fcc378a9beb426d79ce26bf46b54599126fe iptables.initd
cb7fecd5cab2c78bd3f215a41f39ec11c37eb360efbe83982378a0e647e0aa9dc0b7ec915a5b5081aa2f7747464787e69404aa15ba15a063c32cb8fb7dd13d1e iptables.confd
0897a7a22f8b700f7f1f5c355ad6cbf39740e44d6c962af99e479978d8a2d556ca7fe4e31f238829046b4a871ce0b5fd52e2544f1361d15dd1ea3e33992646c4 ip6tables.confd
-641e7dba75bf4997f2cd51f2f153454a73d0b4a485809cc1fd3e65f93ce1bd2a0d412dea9d1dc6dbe9e9778bfdc95298bcedaefc5f8d4659fd93b32aa8c8856d ebtables.initd
+8809d6fc69fbaa7d83ca4675d9e605f73e74ea8907495d39abdfbdca5c74bafb4fe0e413c88a4bd9470688a243581fa239527af06be15c9c94190664d9557fca ebtables.initd
1623109d7b564b817904e35b6c6964ce84fe123a8ae1b656944648a39cfef719431cfad313b48eb36ae53a0d1a6b388a5caec1a990448d02f77e5d12b1f7ee9d ebtables.confd"
diff --git a/main/iptables/ebtables.initd b/main/iptables/ebtables.initd
index b3aa438c8b..7d9243672a 100644
--- a/main/iptables/ebtables.initd
+++ b/main/iptables/ebtables.initd
@@ -77,8 +77,7 @@ reload() {
save() {
ebegin "Saving ebtables state"
- echo -n > "${ebtables_save}"
- chmod 0600 "${ebtables_save}"
+ checkpath -Fm 0600 "${ebtables_save}"
for a in ${ebtables_tables} ; do
${ebtables_bin}-save -t ${a} ${SAVE_RESTORE_OPTIONS} >> "${ebtables_save}"
done
diff --git a/main/iptables/iptables.initd b/main/iptables/iptables.initd
index 98b52d0cdd..d158e3d625 100644
--- a/main/iptables/iptables.initd
+++ b/main/iptables/iptables.initd
@@ -112,8 +112,7 @@ reload() {
save() {
ebegin "Saving ${iptables_name} state"
- touch "${iptables_save}"
- chmod 0600 "${iptables_save}"
+ checkpath -fm 0600 "${iptables_save}"
${iptables_bin}-save ${SAVE_RESTORE_OPTIONS} > "${iptables_save}"
eend $?
}