diff options
author | Darren Tucker <dtucker@dtucker.net> | 2022-04-23 20:17:26 +1000 |
---|---|---|
committer | Darren Tucker <dtucker@dtucker.net> | 2022-04-23 21:14:01 +1000 |
commit | 4cc05de568e1c3edd7834ff3bd9d8214eb34861b (patch) | |
tree | f8311663b14478b9b26265238a47f90c1538d228 /sandbox-capsicum.c | |
parent | c31404426d212e2964ff9e5e58e1d0fce3d83f27 (diff) | |
download | openssh-git-4cc05de568e1c3edd7834ff3bd9d8214eb34861b.tar.gz |
Cache timezone data in capsicum sandbox.
From emaste at freebsd.org, originally part of FreeBSD commit r339216
/ fc3c19a9 with autoconf bits added by me.
Diffstat (limited to 'sandbox-capsicum.c')
-rw-r--r-- | sandbox-capsicum.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sandbox-capsicum.c b/sandbox-capsicum.c index 883be185..11045251 100644 --- a/sandbox-capsicum.c +++ b/sandbox-capsicum.c @@ -29,6 +29,9 @@ #include <stdlib.h> #include <string.h> #include <unistd.h> +#ifdef HAVE_CAPSICUM_HELPERS_H +#include <capsicum_helpers.h> +#endif #include "log.h" #include "monitor.h" @@ -69,6 +72,10 @@ ssh_sandbox_child(struct ssh_sandbox *box) struct rlimit rl_zero; cap_rights_t rights; +#ifdef HAVE_CAPH_CACHE_TZDATA + caph_cache_tzdata(); +#endif + rl_zero.rlim_cur = rl_zero.rlim_max = 0; if (setrlimit(RLIMIT_FSIZE, &rl_zero) == -1) |