summaryrefslogtreecommitdiff
path: root/usr.sbin/ikectl
diff options
context:
space:
mode:
authorPeter Hessler <phessler@cvs.openbsd.org>2010-10-07 10:56:23 +0000
committerPeter Hessler <phessler@cvs.openbsd.org>2010-10-07 10:56:23 +0000
commitbe728442cd2dc027b4a02eeaca7d472dfd0d7a1f (patch)
tree5466d45118d0dcad02c9222e148d876178979c1c /usr.sbin/ikectl
parent7195157b2c37254b8fa338e3d3a2721f4303460c (diff)
set saner permissions on the directory we export, so we don't change
perms of /etc/iked when extracting OK jsg@
Diffstat (limited to 'usr.sbin/ikectl')
-rw-r--r--usr.sbin/ikectl/ikeca.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.sbin/ikectl/ikeca.c b/usr.sbin/ikectl/ikeca.c
index aff1a4a3718..9acf82b2309 100644
--- a/usr.sbin/ikectl/ikeca.c
+++ b/usr.sbin/ikectl/ikeca.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ikeca.c,v 1.10 2010/10/07 09:36:33 phessler Exp $ */
+/* $OpenBSD: ikeca.c,v 1.11 2010/10/07 10:56:22 phessler Exp $ */
/* $vantronix: ikeca.c,v 1.13 2010/06/03 15:52:52 reyk Exp $ */
/*
@@ -513,6 +513,8 @@ ca_export(struct ca *ca, char *keyname, char *myname)
if ((p = mkdtemp(tpl)) == NULL)
err(1, "could not create temp dir");
+ chmod(p, 0755);
+
for (i = 0; i < nitems(exdirs); i++) {
strlcpy(dst, p, sizeof(dst));
strlcat(dst, exdirs[i].dir, sizeof(dst));