From 4763032430834ff1d7dfe4293826cf845a71b990 Mon Sep 17 00:00:00 2001 From: Tim Kuijsten Date: Thu, 21 Nov 2019 02:15:41 +0100 Subject: pledge(2) all programs All programs except mshow have a very tight set of promises. mshow has a broad set of promises and might be a good future candidate to further restrict using unveil(2). This patch is based on commit 0300a112 by Alex Holst (dated 2017-12-07), which was proposed in GH PR #79. * pledged mpick, mflow and mdate so that now all programs are pledged * removed some unneeded promises and added some missing promises * move err.h include and OpenBSD ifdef into a new xpledge.h * cleaned up code aligning and whitespace Closes: #179 [via git-merge-pr] --- mgenmid.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'mgenmid.c') diff --git a/mgenmid.c b/mgenmid.c index c7d713c..eb161cf 100644 --- a/mgenmid.c +++ b/mgenmid.c @@ -13,6 +13,7 @@ #include #include "blaze822.h" +#include "xpledge.h" void printb36(uint64_t x) @@ -36,6 +37,8 @@ int main() char *f = blaze822_home_file("profile"); struct message *config = blaze822(f); + xpledge("stdio rpath", ""); + if (config) // try FQDN: first host = blaze822_hdr(config, "fqdn"); -- cgit 1.4.1